Jump to content

Problem with @scriptfullpath


Recommended Posts

I've a problem with @scriptfullpath or variants of it (@scriptdir & '\' & @scriptname) on XP, on 7 it works fine.

I simply want a script to execute a 2nd session of itself by doing for example:

--

msgbox(0,"","Hello World")

run(@sciptfullpath)

exit

--

error is 0.

i have already tried with _rundos(@scriptfullpath) and so on, too, but no luck on XP :)

Any suggestions for solutions or workarounds would be greatly appreciated :)

Thanks, Flok3r

Link to comment
Share on other sites

I think you first have to compile the program, because Run() can't run a .au3 as far as I know, try to do it with the compiled script or use ShellExecute() instead. :)

PowerSlide2UnlockiPhone look-a-like program you can use to lock your pc, you can't access your desktop again until the password is entered and the slider slided to the right. (really proud of it)-- After a time AutoIt and Windows, I switched to Mac. Don't expect me to answer anymore.
Link to comment
Share on other sites

I don't know, but if you really want to know, I think you have to go to the developers - they made these functions..

PowerSlide2UnlockiPhone look-a-like program you can use to lock your pc, you can't access your desktop again until the password is entered and the slider slided to the right. (really proud of it)-- After a time AutoIt and Windows, I switched to Mac. Don't expect me to answer anymore.
Link to comment
Share on other sites

  • Moderators

Do you have spaces in your "Full Path"?

Try:

Run('"' & @ScriptFullPath & '"')

Edit:

The above has to be compiled of course, or you could do:

Run('"' & @AutoItExe & '" /AutoIt3ExecuteScript "' & @ScriptFullPath & '"')

If it's not compiled, however I would not suggest just running that one line by itself, as it will spawn several instances of the script running.

Edited by SmOke_N

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

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