Jump to content

Saving list content


Recommended Posts

I want to save a list which is not clickable to file. User is able to load elements to list so that we don't know how much it would be, despite that I need to save all into file and load with next program launch.

$scriptsList = GUICtrlCreateList("", 24, 64, 121, 45,$LBS_NOSEL)

How can I do that? (tried GUICtrlRead and read some threads but nothing)

Link to comment
Share on other sites

Solved, thanks to PsaltyDS:

#include <GuiListBox.au3>

; Rest of script body is the same...

Func _ReadItems()
    Local $hLB = ControlGetHandle("MDSI", "", $ctrlLB)
    Local $iCnt = _GUICtrlListBox_GetCount($hLB)
    Local $sMsg = ""
    For $n = 0 To $iCnt - 1
        $sMsg &= $n & ":  " & _GUICtrlListBox_GetText($hLB, $n) & @CRLF
    MsgBox(64, "Result", $sMsg)
EndFunc   ;==>_ReadItems


Link to comment
Share on other sites

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

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...