How to identify the arguments required for the function GetColumnControl
From the help I can find
column
What values should I give for band index and Column key.
This how the recorder script comes
TableObject.SetCellData "0","CurrencyGuid","43219"
If I use TableObject.GetColumnControl("0;CurrencyGuid") , I am getting th error "Object required: 'GetColumnControl(...)'"
and if I use TableObject.GetColumnControl("1;CurrencyGuid") , I am getting the error,
Key not foundParameter name: key
How can I know the correct values for the Column Key,
Your first assumption of what the values for band and column were correct. You are getting the "Object required: ..." error because you are using the following notation:
SET colEditorControl = ...
Your GetColumnControl method call will return a value of -1 if the column in question does not have an EditorControl of some type specified. The value of -1, not being an object but a value type, is the reason for the error. Other than that it appears that you are calling the method correctly.
If you are looping through the columns some having editorControls and others not I would do a test somewhat like this:
SET grid = SwfWindow("Form1").SwfTable("ultraGrid1")colEditorControlValue = grid.GetColumnControl("nBandIndex;sColumnKey")IF colEditorControlValue <> -1 THEN SET colEditorControl = grid.GetColumnControl("nBandIndex;sColumnKey") ...END IFI hope this answers your question,
Hi Mike,
This is not working.
When I pass bandIndex as 0 it doent return anything. not even -1
If I use band index as 1 the I get th error
"Index was out of range. Must be non-negative and less than the size of the collection.Parameter name: index"
Pls let me know how to proceed.