Jump to content

Recommended Posts

Posted

$variable1 = 10
$variable2 = 30

$var = Inireadsectionnames("test.txt")
  for $i=1 to $var[0]
  $label1 = iniread("test.txt", $var[$i],"label1","")
  if not iniread("test.txt",$var[$i],"label2","")
    $result = ($label1 * $variable1)
    iniwrite("test.txt",$var[$i],"change",$result)
    else
        $result = ($label1 * $variable1 * $variable2)
          iniwrite("test.txt",$var[$i],"change",$result)
     Endif
   Next

an here is INI file ... for egzample :

[name 0]sadsadsa=43

wrewrew=4343

erewrew=343

dwfwfe=343

fsfsd=433

ewrewfefw=33

asdsad=34

label2=3

label1=20

change=300

[name 1]

sfddsfds=43543

dffwef=543

fewfewfew=3453

ewfwefew=32423

ewfwfw=1231321

cewewew=45454

ewfwfwe=454

label1=20

change=300

this script work perfect ... but ini file is too big it have 3 mb. How to work with ini files so efficiently like with iniread commands ???? someone solved this problem easy and fastest way ? pls help :P

  • Moderators
Posted

Didn't you decide to just do this with a file rather than an INI? AFAIK you can't do anything about the limit of 64kbs.

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.

  • Moderators
Posted

Maybe you should at using MySQL if your file is going to be that large with all that information?

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.

Posted

Writing home-brewed Ini functions should be trivial since Ini files are so simple. If you must stick with an Ini format, just write whatever functions you need in AutoIt using the native File* functions.

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
×
×
  • Create New...