Jump to content

Recommended Posts

Posted

$newalarm=FileOpenDialog("Choose sound","","Sound Files (*.wav)")

    IniWrite("config.ini","Settings","sound",$newalarm)

Hi, thats my code..

unfortunately, it doesnt write to the ini at all...

Does anyone know y?

  • Developers
Posted

$newalarm=FileOpenDialog("Choose sound","","Sound Files (*.wav)")

    IniWrite("config.ini","Settings","sound",$newalarm)

Hi, thats my code..

unfortunately, it doesnt write to the ini at all...

Does anyone know y?

Works fine for me... :lmao:

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

Posted

crap. Then the mistake must be anywhere else...

Happy searching^^

Hmmh, I also get the problem that the script doesn´t want to add the path to the ini file.

I´ve got the problem when the path of the config.ini is deeper then the file I´ve chosen.

So long,

Mega

Scripts & functions Organize Includes Let Scite organize the include files

Yahtzee The game "Yahtzee" (Kniffel, DiceLion)

LoginWrapper Secure scripts by adding a query (authentication)

_RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...)

Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc.

MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times

Posted (edited)

i doesnt work for me either i dont really know how to help you out here.. a messegebox can show the dir but i cant get it to iniwrite

Edited by Liope
Posted

i doesnt work for me either i dont really know how to help you out here.. a messegebox can show the dir but i cant get it to iniwrite

same here, that was y i wondered. THe Box showed me the right path, but it didnt write it to the ini...
  • Developers
Posted (edited)

Your problem probably is that the Config.ini file is created in the directory you select the WAV file from, because FileOpenDialog() changes the workingdirectory to the select directory.

change yoy script to something like this and try it:

$newalarm=FileOpenDialog("Choose sound","","Sound Files (*.wav)")
 IniWrite(@ScriptDir & "\config.ini","Settings","sound",$newalarm)
Edited by JdeB

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

Posted (edited)

ive just testede it and it works :lmao: and ty for the info about fileopendialog i didnt knew that it changed the working dir..

Edited by Liope
Posted

Your problem probably is that the Config.ini file is created in the directory you select the WAV file from, because FileOpenDialog() changes the workingdirectory to the select directory.

change yoy script to something like this and try it:

$newalarm=FileOpenDialog("Choose sound","","Sound Files (*.wav)")
 IniWrite(@ScriptDir & "\config.ini","Settings","sound",$newalarm)
thx, I just found it out after 10 mins trial and error.. :lmao:

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