ATTENTIONThis FlexSim Community Forum is read-only. Please post any new questions, ideas, or discussions to our new community (we call it Answers) at https://answers.flexsim.com/. Our new Question & Answer site brings a modern, mobile-friendly interface and more focus on getting answers quickly. There are a few differences between how our new Q&A community works vs. a classic, threaded-conversation-style forum like the one below, so be sure to read our Answers Best Practices. |
flexsim.com |
#1
|
||||
|
||||
addlabel in FS 4.5
Hi added a model where I want to put a object reference to the item (Source exit) and use this label for the tasksequence in the 'Queue2'. So the tonum command is working, but the addlabel command seems to be changed since FS 4.32. Are Labels now restricted to carry only integer values?
__________________
kind regards Nico. |
The Following User Says Thank You to Nico Zahn For This Useful Post: | ||
Phil BoBo (10-31-2008) |
#2
|
||||
|
||||
Nico,
Probably you just made it too quickly. You should: addlabel( item, "Name" ); //So a label add setlabelnum( item, "Name", tonum( item ) ); //Then set it Good luck, Martijn /**Edit*/ Hmpf...I was too quickly, but Lars-Olof already helped you out.... Last edited by Martijn van Oostenbrugge; 10-31-2008 at 08:42 AM. |
#3
|
||||
|
||||
user-friendly ??
Hi there,
so I tried the same code in FS 4.3. and it is working. It´s not that I can´t make it work in 4.5 but I have to change my old modells. If you provide a software you can´t change commands and their results without informing people who work with the software. This is only one command I found by chance when I tried to make two big modells work in FS 4.5. So please dear Flexsim developers, please make shure that the commands in 4.5 work as they did in 4.32 if they were not buggy, otherwise you cause a lot of trouble for people like me updating old models.
__________________
kind regards Nico. |
#4
|
|||
|
|||
Hi Nico,
Remember that we are using a beta version and it can still be some bugs in the software. Flexsim want us to start test the software to find the bugs that maybe exist. I tried few things and I do not think addlabel is the problem. What I tried was addlabel(item,"Test",1.1); // WorkedThe only thing that did not work was when I used node and tonum to assign a number to a variable, like you are doing in your code. My guess is there is some problem in the new parser for Flexscript. Lars-Olof |
The Following User Says Thank You to Lars-Olof Leven For This Useful Post: | ||
Phil BoBo (11-24-2008) |
#5
|
||||
|
||||
Thanks Nico,
We'll fix this for the final version. It turns out it was an issue with the new flexscript runtime. Given the new way that flexscript is built, we had to implement a new way of interpreting parameter types. But in the addlabel command, we only considered the two options of adding a label as a number (a straight number) or adding it as a string. We didn't consider the fact that someone might add a label as a number but have the number be a pointer to an object. Anyway, we'll fix this for the final release. Please keep testing and finding these issues. They're very helpful. |
The Following User Says Thank You to Anthony Johnson For This Useful Post: | ||
Nico Zahn (10-31-2008) |