Archive: Get SubItem from an EmbeddedLists


Get SubItem from an EmbeddedLists
  Hello,

I have an EmbeddedLists with 4 columns and checkboxes.
I can get the value of the first column.
How can I get the values of the rest of the columns?

Regards,
Johan


I'm not sure what the problem is... it works like InstallOptions does; you read from the INI file in the page leave function.

Stu


I got the following code in the pageleave function:

StrCpy $R1 ""                                                                 
Pop $R0
StrCmp $R0 /END +3
StrCpy $R1 $R1|$R0
Goto -3

StrCpy $R1 $R1 "" 1
StrCmp $R1 "" +2

StrCpy $0 0


This gives me the value of the first column.
I need the values of the complete line, that is all columns

The ListBox looks like this


   Application    1.0.2     12-12-2009   username
x Application 1.0.1 12-10-2009 username
Application 1.0.0 02-06-2009 username


I need the application, then version, the install date and the install user.

just adapt... (from the ListView_MultiColumnCheckBoxes.nsi example)

ReadINIStr $R0`$PLUGINSDIR\ListView_MultiColumnCheckBoxes.ini` `Item $R0` `Text` 

..to read the additional columns..
ReadINIStr$1 `$PLUGINSDIR\ListView_MultiColumnCheckBoxes.ini` `Item $R0` `SubItem1`
ReadINIStr $2 `$PLUGINSDIR\ListView_MultiColumnCheckBoxes.ini` `Item $R0` `SubItem2`
...
ReadINIStr $N `$PLUGINSDIR\ListView_MultiColumnCheckBoxes.ini` `Item $R0` `SubItemN`

Thanx, it works.

First I struggled for an hour and it didn't work.
Then I found that I was reading from the ListBox with the option 'ReturnItemText' set to 1
After changing that to 0 all was functioning well.

I was just reading the item as text instead as an ID.


Regards,
Johan