Click here to Skip to main content
15,919,341 members
Home / Discussions / C#
   

C#

 
AnswerRe: Registration required Pin
Not Active7-Nov-09 5:36
mentorNot Active7-Nov-09 5:36 
GeneralRe: Registration required Pin
_Madmatt7-Nov-09 5:46
_Madmatt7-Nov-09 5:46 
GeneralRe: Registration required Pin
Not Active7-Nov-09 6:09
mentorNot Active7-Nov-09 6:09 
GeneralRe: Registration required [modified] Pin
_Madmatt7-Nov-09 6:20
_Madmatt7-Nov-09 6:20 
GeneralRe: Registration required Pin
Not Active7-Nov-09 6:39
mentorNot Active7-Nov-09 6:39 
GeneralRe: Registration required Pin
_Madmatt7-Nov-09 6:43
_Madmatt7-Nov-09 6:43 
GeneralRe: Registration required Pin
Not Active7-Nov-09 6:46
mentorNot Active7-Nov-09 6:46 
GeneralRe: Registration required Pin
Judah Gabriel Himango7-Nov-09 7:36
sponsorJudah Gabriel Himango7-Nov-09 7:36 
GeneralRe: Registration required Pin
Not Active7-Nov-09 8:29
mentorNot Active7-Nov-09 8:29 
GeneralRe: Registration required Pin
_Madmatt7-Nov-09 8:44
_Madmatt7-Nov-09 8:44 
GeneralRe: Registration required Pin
#realJSOP8-Nov-09 1:48
professional#realJSOP8-Nov-09 1:48 
GeneralRe: Registration required Pin
Christian Graus7-Nov-09 9:11
protectorChristian Graus7-Nov-09 9:11 
GeneralRe: Registration required [modified] Pin
_Madmatt7-Nov-09 21:35
_Madmatt7-Nov-09 21:35 
GeneralRe: Registration required Pin
#realJSOP8-Nov-09 1:54
professional#realJSOP8-Nov-09 1:54 
QuestionSpeech Recognition for vista and xp too using c# 2008 Pin
krinaljariwala7-Nov-09 4:43
krinaljariwala7-Nov-09 4:43 
AnswerRe: Speech Recognition for vista and xp too using c# 2008 Pin
0x3c07-Nov-09 5:34
0x3c07-Nov-09 5:34 
QuestionEventHandler in DirectoryTreeView App Pin
thungphan7-Nov-09 3:54
thungphan7-Nov-09 3:54 
AnswerRe: EventHandler in DirectoryTreeView App Pin
Luc Pattyn7-Nov-09 4:19
sitebuilderLuc Pattyn7-Nov-09 4:19 
GeneralRe: EventHandler in DirectoryTreeView App Pin
thungphan7-Nov-09 5:05
thungphan7-Nov-09 5:05 
QuestionTCP Connections and Threads Pin
SimpleData7-Nov-09 3:16
SimpleData7-Nov-09 3:16 
AnswerRe: TCP Connections and Threads Pin
Jimmanuel7-Nov-09 3:45
Jimmanuel7-Nov-09 3:45 
AnswerRe: TCP Connections and Threads Pin
N a v a n e e t h7-Nov-09 7:45
N a v a n e e t h7-Nov-09 7:45 
Questionhow to create database backup programmatically in mysql using c#.net Pin
gopal_bnvs7-Nov-09 1:54
gopal_bnvs7-Nov-09 1:54 
Hi

I have the code to make the backup of the MySql database like this..

try
{
DateTime backupTime = DateTime.Now;
int year = backupTime.Year;
int month = backupTime.Month;
int day = backupTime.Day;
int hour = backupTime.Hour;
int minute = backupTime.Minute;
int second = backupTime.Second;
int ms = backupTime.Millisecond;

String tmestr = backupTime.ToString();
tmestr = "C:\\" + year + "-" + month + "-" + day + "-" + hour + "-" + minute + ".sql";
StreamWriter file = new StreamWriter(tmestr);
ProcessStartInfo proc = new ProcessStartInfo();
string cmd = string.Format(@"-u{0} -p{1} -h{2} {3} > {4};", "root", "password", "localhost", "dbfile", "backup.sql");
proc.FileName = "mysqldump";
proc.RedirectStandardInput = false;
proc.RedirectStandardOutput = true;
proc.Arguments = cmd;//"-u root -p smartdb > testdb.sql";
proc.UseShellExecute = false;
Process p = Process.Start(proc);
string res;
res = p.StandardOutput.ReadToEnd();
file.WriteLine(res);
p.WaitForExit();
file.Close();

}

catch (IOException ex)
{
MessageBox.Show("Disk full or other IO error , unable to backup!");
}
}


while executing the program it is showing an error like
"The system cannot find the file specified" with caption "Win32Exception was unhandled "...

can anyone help in this.....
AnswerRe: how to create database backup programmatically in mysql using c#.net Pin
mihirpt1231-Jul-10 11:41
mihirpt1231-Jul-10 11:41 
GeneralRe: how to create database backup programmatically in mysql using c#.net Pin
Bhaumik Lathia17-Jun-11 23:39
Bhaumik Lathia17-Jun-11 23:39 

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.