Jump to content

Help!


Recommended Posts

I have been scripting with AutoIT V2 of a few months i have just decided to move to Version3 and i am having a little trouble

Here is a small sample of my AutoIT 2 code.

IniWrite, %Computername%, C:\\Computername%.txt, General, ComputerName

Basically i was creating a ini file based on the current computer name and also using system variables for information.

Problem is i dont know how to translate it to AutoIT 3 here is what i am assuming it should be but its not working. Any Help would be appreicated as I have a feeling it is something small i am overlooking.

IniWrite("C:\@ComputerName.Txt", "GeneralInformation", "ComputerName", "@ComputerName")

Edited by Majai
Link to comment
Share on other sites

  • Developers

Try it this way:

IniWrite("c:\" & @ComputerName & ".txt", "GeneralInformation", "ComputerName", @ComputerName)

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

I have been scripting with AutoIT V2 of a few months i have just decided to move to Version3 and i am having a little trouble

Here is a small sample of my AutoIT 2 code.

IniWrite, %Computername%, C:\\Computername%.txt, General, ComputerName

Basically i was creating a ini file based on the current computer name and also using system variables for information.

Problem is i dont know how to translate it to AutoIT 3 here is what i am assuming it should be but its not working. Any Help would be appreicated as I have a feeling it is something small i am overlooking.

IniWrite("C:\@ComputerName.Txt", "GeneralInformation", "ComputerName", "@ComputerName")

Did you try the V2 to V3 converter?

that could help to learn

Link to comment
Share on other sites

Dident even look in the extras folder i just really jumped in head first. The converter worked very well for most things a few i will have to code by hand but thats ok. Thanks again for your help now i need to finish my inventory script.

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