I am debugging some freeware code as an addin to Calc and I am having 2 problems. Here is the subroutine I am having a problem with. When I invoke it I get an error when I try to reset the value of OptionIDontCare. I get the following error:
BASIC runtime error. Object variable not set.
Sub OptionIDontCare_Click()
Field = "<" & sOptionIDontCare & ">"
If oDialog1.GetControl("OptionIDontCare").State = True Then
oDialog1.GetControl("TextFieldOrder").Text = _
oDialog1.GetControl("TextFieldOrder").Text + Field & " "
QIFFields(iCol) = Field
iCol = iCol + 1
OptionIDontCare.Value = False
End If
End Sub
I have 2 problems. The first is how do I change the value of OptionIDontCare.State? Are State and Value the same thing?
The second is I cannot find the OptionIDontCare control. How can I list the names of the controls in a dialog?
Thank you,
Vince Radice
(Formatting rectified by @Lupp )