Arclite86 Posted September 11, 2015 Share Posted September 11, 2015 i have a autoit program that opens a txt fileGlobal $iIndex = 0, $sListData1 = "C:\Users\user pc\Desktop\mapa\lijsten\list1.txt" Global $sListFile1 = "C:\Users\user pc\Desktop\mapa\lijsten\list1.txt" If FileExists($sListFile1) Then $sListData1 = FileRead($sListFile1) EndIf GUICtrlSetData($List1, $sListData1) _GUICtrlListBox_SetCurSel($List1, $iIndex)the only problem is when I open the txt file there is no "|" charachter between the words so it only shows a very long one word. Link to comment Share on other sites More sharing options...
computergroove Posted September 11, 2015 Share Posted September 11, 2015 Can you provide an example of what is in list1.txt? Get Scite to add a popup when you use a 3rd party UDF -> http://www.autoitscript.com/autoit3/scite/docs/SciTE4AutoIt3/user-calltip-manager.html Link to comment Share on other sites More sharing options...
Arclite86 Posted September 11, 2015 Author Share Posted September 11, 2015 Can you provide an example of what is in list1.txt?A bunch of names for my administration like:HelmerTilmans MozesSchrijver MelwinWilschut PercyvanZwien RoelfFolkersma MarcelodeKeizer EvanderPiet JanvanKlavere AadHorsthuis EwoutRosenboom RudiLebens Dimitrioszwaag Matejvanderziel etc..and this is what i would like to have itHelmerTilmans| MozesSchrijver| MelwinWilschut| PercyvanZwien| RoelfFolkersma| MarcelodeKeizer| EvanderPiet| JanvanKlavere| AadHorsthuis| EwoutRosenbom| RudiLebens| Dimitrioszwaag| Matejvanderziel| etc..or before every name Link to comment Share on other sites More sharing options...
iamtheky Posted September 11, 2015 Share Posted September 11, 2015 $sFile = fileread("test.txt") $sRepl = StringReplace($sFile , @CRLF , "|" & @CRLF) filewrite("output.txt" , $sRepl) ,-. .--. ________ .-. .-. ,---. ,-. .-. .-. .-. |(| / /\ \ |\ /| |__ __||| | | || .-' | |/ / \ \_/ )/ (_) / /__\ \ |(\ / | )| | | `-' | | `-. | | / __ \ (_) | | | __ | (_)\/ | (_) | | .-. | | .-' | | \ |__| ) ( | | | | |)| | \ / | | | | | |)| | `--. | |) \ | | `-' |_| (_) | |\/| | `-' /( (_)/( __.' |((_)-' /(_| '-' '-' (__) (__) (_) (__) Link to comment Share on other sites More sharing options...
ViciousXUSMC Posted September 11, 2015 Share Posted September 11, 2015 (edited) Global $iIndex = 0, $sListData1 = "C:\Users\user pc\Desktop\mapa\lijsten\list1.txt" Global $sListFile1 = "C:\Users\user pc\Desktop\mapa\lijsten\list1.txt" If FileExists($sListFile1) Then $sListData1 = StringReplace(FileRead($sListFile1), @CRLF, "|") EndIf GUICtrlSetData($List1, $sListData1) _GUICtrlListBox_SetCurSel($List1, $iIndex) Edited September 11, 2015 by ViciousXUSMC 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