Page 1 of 1

SetGadgetItemAttribute <- What Am I doing wrong

Posted: Mon Jan 13, 2025 10:45 pm
by GenRabbit
ListIconGadget(#ListIconGadget1, 20,340,400,240,"Month name",270,#PB_ListIcon_FullRowSelect)
AddGadgetColumn(#ListIconGadget1,2,"Days",100)
SetGadgetItemAttribute(#ListIconGadget1, 1, #PB_ListIcon_ColumnAlignment, #PB_ListIcon_Center)

In my code i have these three lines of code. As I understand it,1 here should center the text in the column Days. But no matter the value here, Month name is the one centered? What Am I doing wrong?

Re: SetGadgetItemAttribute <- What Am I doing wrong

Posted: Tue Jan 14, 2025 12:30 am
by STARGĂ…TE
The second parameter is the item (the row) not the column.
You have to use the last optional parameter column.

Code: Select all

SetGadgetItemAttribute(#ListIconGadget1, #PB_Ignore, #PB_ListIcon_ColumnAlignment, #PB_ListIcon_Center, 1)

Re: SetGadgetItemAttribute <- What Am I doing wrong

Posted: Tue Jan 14, 2025 1:07 am
by GenRabbit
Thanks, that did it.