Ilogic inventor programming that user is unable to continue

Ilogic inventor programming that user is unable to continue

Anonymous
Not applicable
364 Views
2 Replies
Message 1 of 3

Ilogic inventor programming that user is unable to continue

Anonymous
Not applicable

Hello there,

 

 

For a project i am working with ilogic in inventor. I already have done a  lot of programming by now. 
Now i was wondering if its possible to prevent the user to click "done"in the forum if the parameters are not within the allowed spectrum. I don't have a preference how this should be done as long as the user isn't able to continue until the change the wrong value.

 

As an examble:

 

If Number > 1500 
Then ........

 

I am looking forward hearing from you.

 

 

Kind regards,

Bianca

 

 

0 Likes
365 Views
2 Replies
Replies (2)
Message 2 of 3

Mirtchii
Advocate
Advocate

Hi,

I think you can add a simple code as below code in to your iLogic code

If A1>1500 Then
	MessageBox.Show("A1 is over 1500", "Error")
End If

If the number is over 1500, a message box will appear and warn the user.

Simple and easy for them to understand what's going on instead of making them unable to press Done button.

Hope this can help you.

 

Mirt 

0 Likes
Message 3 of 3

mcgyvr
Consultant
Consultant

@Anonymous  Just use a while loop to keep prompting/checking the value..

Something like this..

While (10 > myLength) Or (myLength > 20)
	myLength = InputBox("Length of Part", "Part Length Input")

	If (10 > myLength) Or  (myLength > 20) 'check if outside of range
			MessageBox.Show("Length is outside of range" & vbLf & "10 < length < 20", "Range Error") 'give an error message
	End If

End While



-------------------------------------------------------------------------------------------
Inventor 2023 - Dell Precision 5570

Did you find this reply helpful ? If so please use the Accept Solution button below.
Maybe buy me a beer through Venmo @mcgyvr1269
0 Likes