pille24 Posted February 7, 2006 Share Posted February 7, 2006 $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? Link to comment Share on other sites More sharing options...
Developers Jos Posted February 7, 2006 Developers Share Posted February 7, 2006 $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... 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 More sharing options...
pille24 Posted February 7, 2006 Author Share Posted February 7, 2006 Works fine for me... crap. Then the mistake must be anywhere else...Happy searching^^ Link to comment Share on other sites More sharing options...
Xenobiologist Posted February 7, 2006 Share Posted February 7, 2006 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 Link to comment Share on other sites More sharing options...
Faustvii Posted February 7, 2006 Share Posted February 7, 2006 (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 February 7, 2006 by Liope Link to comment Share on other sites More sharing options...
pille24 Posted February 7, 2006 Author Share Posted February 7, 2006 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 iniwritesame here, that was y i wondered. THe Box showed me the right path, but it didnt write it to the ini... Link to comment Share on other sites More sharing options...
Faustvii Posted February 7, 2006 Share Posted February 7, 2006 same here, that was y i wondered. THe Box showed me the right path, but it didnt write it to the ini...are you making some kind of alarm? Link to comment Share on other sites More sharing options...
Developers Jos Posted February 7, 2006 Developers Share Posted February 7, 2006 (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 February 7, 2006 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. Link to comment Share on other sites More sharing options...
Faustvii Posted February 7, 2006 Share Posted February 7, 2006 (edited) ive just testede it and it works and ty for the info about fileopendialog i didnt knew that it changed the working dir.. Edited February 7, 2006 by Liope Link to comment Share on other sites More sharing options...
pille24 Posted February 7, 2006 Author Share Posted February 7, 2006 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.. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now