THGRMA
Electrical
- Mar 10, 2008
- 3
Hi all,
I am hoping that someone will be able to point me in the right direction with a problem I have with varibles.
What I want to do is to suppress two features if the size of a hole is over a specific size.
I have written a .bas file which contains the following:
'===========================================================================
Sub VarSelect(ByVal ip As Double, ByRef op1 As Double, ByRef op2 As Double)
If (ip >= 6) Then
op1 = 1
op2 = 1
Else
op1 = 0
op2 = 0
End If
End Sub
'===========================================================================
When I try to add the the code to into the variables table I get an error.
I tried using three variables that are just TEST, A and B so that none of the geometry was being driven and I still get the same error.
The error says:
"Variable "test" is driven and cannot be used within related geometry to evaluate driving variable "test""
It appears to be saying that the variable TEST is being driven and cannot be used but I am not trying to drive TEST I am trying to use its value to set variables A & B!!
If someone can point me in the direction of why this is happening, I would very much appreciate it.
Thanks
Kind regards
I am hoping that someone will be able to point me in the right direction with a problem I have with varibles.
What I want to do is to suppress two features if the size of a hole is over a specific size.
I have written a .bas file which contains the following:
'===========================================================================
Sub VarSelect(ByVal ip As Double, ByRef op1 As Double, ByRef op2 As Double)
If (ip >= 6) Then
op1 = 1
op2 = 1
Else
op1 = 0
op2 = 0
End If
End Sub
'===========================================================================
When I try to add the the code to into the variables table I get an error.
I tried using three variables that are just TEST, A and B so that none of the geometry was being driven and I still get the same error.
The error says:
"Variable "test" is driven and cannot be used within related geometry to evaluate driving variable "test""
It appears to be saying that the variable TEST is being driven and cannot be used but I am not trying to drive TEST I am trying to use its value to set variables A & B!!
If someone can point me in the direction of why this is happening, I would very much appreciate it.
Thanks
Kind regards