Infinite loop!

Hi,

I have an issue, i can’t unterstand! I’ve a loop “do while” !

Which should get out of the result if it’s value out of the loop is equal nominal, but not it keeps looping…

Capture

@mz3bel

Try this condition:

Not output_matches(0).Tostring.ToLower.Contains(“nominal”)

2 Likes

@lakshman

Thank you, could you please tell me why my condition didn’t work?

1 Like

‘IsNot’ operator checks if two objects refer to different objects, but it doesn’t check values.

‘Not =’ operator checks if the value between the objects are different.

Since you’re checking if the value of the string is different (and NOT whether it’s the same object), you want to use Not = instead of IsNot.

1 Like

Buddy @mz3bel
you were almost right
First let me tell you why you faced the error and what can be the alternative one
you mentioned the condition like
output_matches(0).ToString isNot "nominal"

it shoul be like this
output_matches(0).ToString isNot equal "nominal"

Try this condition buddy this would work as per your condition with very minor changes
Cheers @mz3bel

1 Like

@Palaniyappan

Thank you, i just tried it! it doesn’t work… seams it’s recongize “equal” :smiley:

1 Like

@Dave

Thank you for your explications :smiley:

its equals buddy not equal
small typo mistake
Try that buddy
Cheers @mz3bel

1 Like

@Palaniyappan

Same error my friend.

Fine then the syntax that i meant must be wrong i guess…
no worries
Cheers @mz3bel

1 Like

@Palaniyappan - check out my explanation above. The IsNot operator should not be used in this circumstance because it is checking if the objects themselves are the same. We instead should use the = operator (combined with Not as we want it to not be equal) because we want to compare the VALUE of two distinct objects to see if they are the same

2 Likes

Thats great i know about the equal operator and that would work for sure
but i was wondering to use isnot here and check whether it will work or not
anyhow go to know now
Cheers buddy @Dave

Hi guys,

I run my process today to check it, i see i get the same issue as yesturday!

PS: i’m using " output_matches(0).Tostring.ToLower.Contains(“nominal”) " as mentioned as solution, because it worked yesturday! no changes have been made!

Also, used log, to see the result of that command, it gives me true, which means it does contain “nominal” ??

Thank you!

1 Like

it should be
NOT output_matches(0).Tostring.ToLower.Contains(“nominal”)

and what was the error you were facing buddy
Cheers @mz3bel

1 Like

@Palaniyappan

Ahh!!! i tough i forgot something! Yes yes, i can’t even focus xD

Thanks friend

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.