PVGadgets_GetListIconColumnWidth (GadgetID.l,Column.l)
Previous  Top  Next

Returns the width of the selected column in a ListIconGadget.
 
Use:
Result=PVGadgets_GetListIconColumnWidth(#Gadget,Column)


Example:

#Main=0
#List=1

If OpenWindow(#Main,0,0,400,300,#PB_Window_SystemMenu|#PB_Window_ScreenCentered,"")
 
ListIconGadget(#List,0,0,400,300,"Column 1",150,#PB_ListIcon_GridLines|#PB_ListIcon_FullRowSelect)  
AddGadgetColumn(#List,1,"Column 2",80)  
AddGadgetColumn(#List,2,"Column 3",50)  
 

totalcolumns=PVGadgets_CountListIconColumns(#List)  
MessageRequester("Result","Total Columns: "+Str(totalcolumns))  

oldcolumnwidth=PVGadgets_GetListIconColumnWidth(#List,2)  
PVGadgets_SetListIconColumnWidth(#List,2,100)  
newcolumnwidth=PVGadgets_GetListIconColumnWidth(#List,2)  
MessageRequester("Result","Old Width: "+Str(oldcolumnwidth)+Chr(10)+"New Width: "+Str(newcolumnwidth))  

Repeat:Until WaitWindowEvent()=#PB_Event_CloseWindow  
EndIf