====== VALUEBYPOS method (PropertyGrid) ====== ==== Description ==== Returns the value of the specified property item using its position in the "visible" list. ==== Syntax ==== itemValue = Exec_Method( ctrlEntID, "VALUEBYPOS", itemPos, newValue ) ==== Parameters ==== ^Name^Required^Description^ |itemPos|Yes|Position of the property item in the visible list| |newValue|No|New value for the property| ==== Returns ==== Value of the specified property item. ==== Remarks ==== The value depends on the type of the property item. If the property item has a type of PGIT_COLOR$ then the returned data will be an RGB color value, if the property item has a type of PGIT_EDIT$ then the value will be a string, and so on. ==== Example ==== $Insert PS_Property_Grid_Equates $Insert Logical CtrlEntID = @Window : ".PRG_MAIN" // Set the full list of items... // // Data // Title - Yadda // SubTitle - Whatever // UI // Visible - TRUE$ // Color - 0xFF (red) Pgl = "Data" : @Vm : "Title" : @Vm : PS_PGI_EDIT$ : @Vm : "Yadda" Pgl<-1> = "Data" : @Vm : "SubTitle" : @Vm : PS_PGI_EDIT$ : @Vm : "Whatever" Pgl<-1> = "UI" : @Vm : "Visible" : @Vm : PS_PGI_CHECK$ : @Vm : TRUE$ pgl<-1> = "UI" : @Vm : "Color" : @Vm : PS_PGI_COLORDLG$ : @Vm : 0xFF Call Set_Property_Only( CtrlEntID, "LISTX", Pgl ) // Hide all "Data" items... Call Exec_Method( CtrlEntID, "COLLAPSE", "Data" ) // Get the value of the "Color" item, now at position 2) ItemVal = Exec_Method( CtrlEntID, "VALUEBYPOS", 2 ) ==== See Also ==== [[../O10_Presentation_Server_Object_Model/VALUE_property_(PropertyGrid).htm|VALUE property]] [[../O10_Presentation_Server_Object_Model/VALUEBYNAME_method_(PropertyGrid).htm|VALUEBYNAME method]]