Click here to Skip to main content
15,887,267 members
Home / Discussions / C#
   

C#

 
AnswerRe: How to Change Image for the last level(Child) in Treeview in C#? Pin
BillWoodruff19-Sep-14 21:41
professionalBillWoodruff19-Sep-14 21:41 
GeneralRe: How to Change Image for the last level(Child) in Treeview in C#? Pin
aahamdan20-Sep-14 9:36
aahamdan20-Sep-14 9:36 
GeneralRe: How to Change Image for the last level(Child) in Treeview in C#? Pin
BillWoodruff20-Sep-14 19:56
professionalBillWoodruff20-Sep-14 19:56 
GeneralRe: How to Change Image for the last level(Child) in Treeview in C#? Pin
aahamdan22-Sep-14 7:56
aahamdan22-Sep-14 7:56 
GeneralRe: How to Change Image for the last level(Child) in Treeview in C#? Pin
BillWoodruff22-Sep-14 22:29
professionalBillWoodruff22-Sep-14 22:29 
GeneralRe: How to Change Image for the last level(Child) in Treeview in C#? Pin
Eddy Vluggen22-Sep-14 8:27
professionalEddy Vluggen22-Sep-14 8:27 
GeneralRe: How to Change Image for the last level(Child) in Treeview in C#? Pin
BillWoodruff22-Sep-14 8:34
professionalBillWoodruff22-Sep-14 8:34 
Questioncontinue if loop if failed Pin
Jassim Rahma19-Sep-14 11:27
Jassim Rahma19-Sep-14 11:27 
Hi,

I am using the following to loop through date range and import into a database from text files. I want to know how can I tell the code IF FILE DOES NOT EXITS THEN CONTINUE TO NEXT FILE?

C#
for (DateTime date = last_date; date.Date <= DateTime.Today; date = date.AddDays(1))
{
  string file_name = "H" + date.ToString("yyyy-MM-dd") + ".TXT";

  MySqlBulkLoader bl = new MySqlBulkLoader(sql_connection);
  bl.TableName = "processing_table";
  bl.FieldTerminator = ",";
  bl.LineTerminator = "\n";
  bl.FileName = @"C:\Temp\Attendence\" + file_name;
  bl.NumberOfLinesToSkip = 0;

  int count = bl.Load();

  string sql = "SELECT source, created_date, created_time, company, action, employee_number, employee_name, outlet, field_1, field_2, field_3, field_4 FROM processing_table";
  MySqlCommand cmd = new MySqlCommand(sql, sql_connection);
  MySqlDataReader rdr = cmd.ExecuteReader();

  while (rdr.Read())
  {
      SplashScreenManager.Default.SetWaitFormDescription(rdr[1] + " - " + rdr[2]);
  }
                
  rdr.Close();
}



Technology News @ www.JassimRahma.com

AnswerRe: continue if loop if failed Pin
V.19-Sep-14 11:36
professionalV.19-Sep-14 11:36 
AnswerRe: continue if loop if failed Pin
Eddy Vluggen19-Sep-14 11:56
professionalEddy Vluggen19-Sep-14 11:56 
AnswerMessage Closed Pin
19-Sep-14 23:36
Raushank0319-Sep-14 23:36 
GeneralRe: continue if loop if failed Pin
Eddy Vluggen20-Sep-14 0:18
professionalEddy Vluggen20-Sep-14 0:18 
AnswerRe: continue if loop if failed Pin
Dominic Burford22-Sep-14 0:03
professionalDominic Burford22-Sep-14 0:03 
Questionc# unable to coonect with xls file using LinqToExcel Please help Pin
Member 1105342019-Sep-14 5:11
Member 1105342019-Sep-14 5:11 
AnswerRe: c# unable to coonect with xls file using LinqToExcel Please help Pin
PIEBALDconsult19-Sep-14 5:20
mvePIEBALDconsult19-Sep-14 5:20 
QuestionRe: c# unable to coonect with xls file using LinqToExcel Please help Pin
ZurdoDev19-Sep-14 10:55
professionalZurdoDev19-Sep-14 10:55 
Questionc# LinqToExcel is not connecting to XLS in 64bit system but it is connecting xlsx file, tried DatabaseEngine.ace but didn't worked out. Pin
Member 1105342019-Sep-14 5:08
Member 1105342019-Sep-14 5:08 
AnswerRe: c# LinqToExcel is not connecting to XLS in 64bit system but it is connecting xlsx file, tried DatabaseEngine.ace but didn't worked out. Pin
PIEBALDconsult19-Sep-14 5:22
mvePIEBALDconsult19-Sep-14 5:22 
AnswerRe: c# LinqToExcel is not connecting to XLS in 64bit system but it is connecting xlsx file, tried DatabaseEngine.ace but didn't worked out. Pin
Eddy Vluggen19-Sep-14 7:16
professionalEddy Vluggen19-Sep-14 7:16 
QuestionResize Control Pin
AmbiguousName18-Sep-14 21:09
AmbiguousName18-Sep-14 21:09 
AnswerRe: Resize Control Pin
OriginalGriff18-Sep-14 21:41
mveOriginalGriff18-Sep-14 21:41 
GeneralRe: Resize Control Pin
AmbiguousName18-Sep-14 21:48
AmbiguousName18-Sep-14 21:48 
AnswerRe: Resize Control Pin
BillWoodruff18-Sep-14 21:41
professionalBillWoodruff18-Sep-14 21:41 
GeneralRe: Resize Control Pin
AmbiguousName18-Sep-14 21:52
AmbiguousName18-Sep-14 21:52 
GeneralRe: Resize Control Pin
Rob Philpott18-Sep-14 22:12
Rob Philpott18-Sep-14 22:12 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.