12 posts in this topic
Add .txt to GUICtrlCreateListVi
I'm working on this project:
$Import = GUICtrlCreateButton("Import", 15, 175, 90, 40, $WS_GROUP) $List = GUICtrlCreateListView("Name|Address|E-mail", 15, 220, 400, 363, $LVS_SORTDESCENDING) $Item1 = GUICtrlCreateListViewItem("test|test|test", $List) GUISetState(@SW_SHOW, $GUI) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE, $Exit Exit Case $Import $Table_Import = FileOpenDialog("Import list '*.txt'", @DesktopDir & "\", "Text (*.txt)") If @error Then ContinueLoop GUICtrlSetData($Item1, $Table_Import) In the text file the fields are delimited with "|" and the values are not in the same row but one below the other.
However in the txt file the sum of the values may change.
Can you help me?
I built a gui where a GUICtrlCreateListView with two columns is present.
Through an "Import" button I would be able to import the contents of an .xls or .txt.
Can you help me?
ewItem newest item on top. how to?
I've created a script and i'd like when the user adds a new item on the ListView, that new item to be placed on top.
GUICtrlCreateListViewItem places newly created ListViewItems right below the older ones. Is there a way to display the newest iten on top of the list view?
Thanks a lot in advance!
To skip code if it is a library
Is there any way to skip the execution of a particular block of code like any condition or expression, if the au3 file is included as library.?
Like, in my code I wrote all the functionality as functions and called them in 4 lines.
Now I have another requirement where I need to use the same code but different.So I am importing this code so that I can use these functions.
But the code block which is outside the functions (main code) is being executed when I import the au3 file.Is there any condition to check whether the file is running directly or included in another au3 file as library, so that I can keep the same here.
Please suggest if any ideas.