|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
please tell me how to backup mysql from vb
'# vb code
Private Sub Command1_Click() Const BATCHFILE = "command.com /C C:\mysql2.bat" Call Shell(BATCHFILE, vbNormalFocus) End Sub ' # batch file is => mysql2.bat c:\ cd mysql cd bin C:\mysql\bin\mysqldump.exe salaryplus>C:\dump.sql pause when i run the batch file alone it creates the backup but when i execute it from vb it gives a C:\MYSQL\BIN> C:\MYSQL\BIN>C:\mysql\bin\mysqldum Bad command or file name C:\MYSQL\BIN> C:\MYSQL\BIN>pause Press any key to continue . . . Last edited by bary : December 29th, 2003 at 04:12 AM. |
|
#2
|
||||
|
||||
|
a question, I've never done anything like this, but do you have to completely reference your bat file once you've navigated to it? Also, did you copy and paste this code? I only ask because there is a typo.
Code:
C:\MYSQL\BIN>C:\mysql\bin\mysqldum
__________________
Fisherman "Any intelligent fool can make things bigger, more complex, and more violent. It takes a touch of genius -- and a lot of courage -- to move in the opposite direction." - A.Einstein |
|
#3
|
|||
|
|||
|
U can shell the bat file directly..As this:
Const BATCHFILE = "C:\mysql2.bat" Call Shell(BATCHFILE, vbNormalFocus) |
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > Visual Basic Programming > can any one help me back up mysql from vb |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|