Jump to content

"start" command in batch file does not work !


Recommended Posts

to be more clear,

my problem is when i want to run java Application remotely ( on windows server 2003 ) ,


Set cloner = CreateObject("WScript.Shell")
cloner.run"cmd"
WScript.Sleep 500


cloner.SendKeys"telnet 00.00.00.00" // = zeros is IP
cloner.SendKeys("{Enter}")
WScript.Sleep 500

cloner.SendKeys"start JavaApplication"
cloner.SendKeys("{Enter}")
WScript.Sleep 500


cloner.SendKeys"exit"
cloner.SendKeys("{Enter}")
WScript.Sleep 300

cloner.SendKeys"exit"
cloner.SendKeys("{Enter}")
WScript.Sleep 300



Link to comment
Share on other sites

  • 1 month later...
when i put it in patch file does not work ?!!

I'm confused. Also you don't necessarily need to use the start command to execute an application. Something as simple as this will work in batch.

explorer.exe

or

app.exe

Assuming you're in the proper directory, or you input the full filepath

%Directory%\app.exe

Link to comment
Share on other sites

I think by this time the readers will be enthralled by the amount of knowledge that you have, but will probably have lost sight of it's meaningful content in both context and relationship to the original post. lol. :)

In which part of Canada do you live by the way ?

Link to comment
Share on other sites

I think by this time the readers will be enthralled by the amount of knowledge that you have, but will probably have lost sight of it's meaningful content in both context and relationship to the original post. lol. :)

In which part of Canada do you live by the way ?

I live in Alberta for specific :) The oil capital of Canada as a province lol

He mentioned he wanted to run a java app though, I don't see reason as to why he can't try something like this:

java_appname.exe

That would start it, but to actually do anything with it you'd have to make sure that this app can recognize and utilize command line arguments to do anything with the app once it's ran. Otherwise it just fires up, and nothing else happens. Batch isn't the language to be sending Windows Messages either to anywhere like you'd be able to do with a language like C++. You could get the window itself by a handle, and virtually invoke any button object on the form if batch could do that. As well as change around the values of all of the labels and text on the form itself including the titlebar :lol:

Here's an example of what I mean with Windows Messaging :)

Some application I developed a while back...

iQVvVQ5NzDaYl.png

And after opening a screenshot of that in Windows Live Photo Viewer, I edited the title of the Windows Live Photo Viewer application title bar as well :lol:

isBtTI3uDRmhy.png

Without that though, you can't do anything, and batch isn't advanced enough to send Windows Messages as far as i'm concerned.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Privacy Policy