Hi all I'm back with another .NET question....
I am setting up a form that will run prior to all our programs and I have it loading all of the variables from PC DMIS in, and that is working fine. However I also need this form to set variables upon closing..... This is where the trouble starts, ideally I'd like to set the variables with a string value (this can be worked around if not possible) but every time i get an error telling me I can't convert String to variable (the same goes for integers and boolean). I've tried every which way I can think of and its driving me insane.
Does anyone have any experience with setting PC DMIS variables through .NET that can shed some light?
This method pops up the error:
This method doesn't error out however it changes nothing:
I am setting up a form that will run prior to all our programs and I have it loading all of the variables from PC DMIS in, and that is working fine. However I also need this form to set variables upon closing..... This is where the trouble starts, ideally I'd like to set the variables with a string value (this can be worked around if not possible) but every time i get an error telling me I can't convert String to variable (the same goes for integers and boolean). I've tried every which way I can think of and its driving me insane.
Does anyone have any experience with setting PC DMIS variables through .NET that can shed some light?
This method pops up the error:
Code:
Dim testop As PCDLRN.Variable testop = OpBox1.SelectedValue If Not testop Is Nothing Then pcpart.SetVariableValue("OPNO", testop) End If
Code:
Dim testop As PCDLRN.Variable testop = OpBox1.SelectedItem.ToString If Not testop Is Nothing Then pcpart.SetVariableValue("OPNO", testop) End If