Jump to content

start database issue


Recommended Posts

I need to start a database server

I try:

RunWait(@ComSpec & " /c " & "dbeng9 -n pos1 -qi d:\SpiritPOS\Data\SpiritPOS.db -gk all")

but only the dbeng9 runs. How do I get the parameters to run?

Link to comment
Share on other sites

#include <GUIConstants.au3>
#include <WindowsConstants.au3>
#include <Process.au3>
#include <StaticConstants.au3>
Global Const $PBS_SMOOTH              = 0x00000001; The progress bar displays progress status in a smooth scrolling bar
Global Const $PBS_MARQUEE            = 0x00000008; The progress bar moves like a marquee
Global $i=0
Do
            GUICreate("Start Database", 410, 380,-1,-1,$WS_EX_DLGMODALFRAME, $WS_EX_TOPMOST)
            GUICtrlCreateLabel("STARTING SPIRITPOS DATABASE...PLEASE WAIT", 60, 30, 350, 300)
            GUISetState(@SW_DISABLE)
            $Progress6 = GUICtrlCreateProgress(24, 86, 360, 25, BitOR($PBS_SMOOTH,$PBS_MARQUEE))
            GUISetState()
            AdlibEnable("Advance", 50)
Until ProcessExists ( "dbeng9.exe" )
FileChangeDir("d:\program files\sybase\sql anywhere 9\win32")
RunWait("dbeng9.exe -n pos1 -qi d:\SpiritPOS\Data\SpiritPOS.db -gk all")

Func Advance()
For $i = 0 To 100 Step 1
GUICtrlSetData($Progress6, $i)
Next
EndFunc

You seen an error, because Global Const was inside Do..Until, - Global Const must be declared only once.

_____________________________________________________________________________

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...