List Box

For questions about using Classic.

Post » Sun Jan 15, 2012 6:52 pm

I am experimenting with saves using a list box, but I cannot seem to find how you set an event for 'line (double)clicked' in which it knows which line is clicked. Is this possible, if so can somebody help?
Nothing goes unanswered!
B
22
S
5
G
1
Posts: 430
Reputation: 3,383

Post » Sun Jan 15, 2012 7:30 pm

you can get the number of the selected line with the expression "Get selected line number" or ListBox.SelectedLine

+ ListBox: Double clicked
-> Text: Set text to ListBox.SelectedLine

This would set the textbox to the current line number selected by the double click.
Image
B
23
S
8
G
10
Posts: 1,820
Reputation: 8,242

Post » Mon Jan 16, 2012 9:20 pm

Also how do you specify a new line whilst setting text, I was using '&Newline,' but that doesn't work?
Nothing goes unanswered!
B
22
S
5
G
1
Posts: 430
Reputation: 3,383

Post » Tue Jan 17, 2012 6:50 am

With the "Add Line" action.

Please make sure, that you have read the wiki (e.g. List Box Object)

Also, if you right-click on an object in the object list tab, while layout editor is active, you can select "Object information" from the context menu, which lists all ACE that object has.
Image
B
23
S
8
G
10
Posts: 1,820
Reputation: 8,242

Post » Tue Jan 17, 2012 5:43 pm

I don't quite understand... I have this set as the text when somebody double clicks their save:

"Game: [number]" &Newline, "Save-Date: [Save-Date]" &Newline, "Time Played: [Time Played]" but when this is triggered it only shows the top line. Add Line didn't seem to work.
Nothing goes unanswered!
B
22
S
5
G
1
Posts: 430
Reputation: 3,383

Post » Fri Dec 14, 2012 9:26 am

How to display data from database in listbox?
B
11
S
3
G
2
Posts: 40
Reputation: 2,362


Return to Help & Support using Construct Classic

Who is online

Users browsing this forum: No registered users and 2 guests