Showing results for 
Search instead for 
Do you mean 
Reply
Solved! Go to solution

syntax error Method inspect @. name

Hello,

 

I have syntax error for method inspect @. name

 

In the model from source i want to send object a, b,c to different line using Method.

 

But the method shows an syntax error.

 

Please anyone can suggest the solution for the problem.

4 REPLIES

Re: syntax error Method inspect @. name

you need to switch off the new syntax in the tab "Extras". In the new simtalk syntax inspect is replaced by switch - case.

Steffen Bangsow
freelance simulation specialist  
web: www.bangsow.eu
mail: steffen@bangsow.net


Re: syntax error Method inspect @. name

switch @.name
case "a"
@.umlagern(l2)
case "b"
@.umlagern(l3)

else
case"c"
@.umlagern(l1)
end

 

I have written this new code with  switch but still no result

Solution
Solution
Accepted by topic author cplex
‎11-24-2016 08:03 AM

Re: syntax error Method inspect @. name

after else you must not define a new case

attached you find the two variants


Steffen Bangsow
freelance simulation specialist  
web: www.bangsow.eu
mail: steffen@bangsow.net


Re: syntax error Method inspect @. name

Thank you..for quick solution