Jump to content

return value from an exe


Recommended Posts

Hi there

I wanted to know if anyone knows how to return a value from an exe. Like a DllCall.

Is this even possible... and if yes is it in AutoIt ?

I think it could be done by writing data to some predefined memory address and then read them so to get a $DllCallVar[0] kind of thing where the exe writing the data is the dll. And the one reading is the DllCall function. But this is very risky.

any other ideas on how to make it less risky OR by using any other method ?

thanks for your help :)

Some Projects:[list][*]ZIP UDF using no external files[*]iPod Music Transfer [*]iTunes UDF - fully integrate iTunes with au3[*]iTunes info (taskbar player hover)[*]Instant Run - run scripts without saving them before :)[*]Get Tube - YouTube Downloader[*]Lyric Finder 2 - Find Lyrics to any of your song[*]DeskBox - A Desktop Extension Tool[/list]indifference will ruin the world, but in the end... WHO CARES :P---------------http://torels.altervista.org

Link to comment
Share on other sites

thanks to everyone :)

writing to a file or the registry was not in my options... I wanted it to be in the memory.

btw... what's Exit 1234 ???

Some Projects:[list][*]ZIP UDF using no external files[*]iPod Music Transfer [*]iTunes UDF - fully integrate iTunes with au3[*]iTunes info (taskbar player hover)[*]Instant Run - run scripts without saving them before :)[*]Get Tube - YouTube Downloader[*]Lyric Finder 2 - Find Lyrics to any of your song[*]DeskBox - A Desktop Extension Tool[/list]indifference will ruin the world, but in the end... WHO CARES :P---------------http://torels.altervista.org

Link to comment
Share on other sites

When exit a program, an exit code is sent to the os. if 0 it is a natural exit, else it defines the exit code.

Within autoit, if you have defined the exit function it can be got by @ExitMethod, and describes simply why the script is exiting.

For dos it is something like %ERRORLEVEL%.

Read up on exit, I think what monoceres meant is that you can then read this exit code, but I'm not sure how.

MDiesel

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...