ContextAdd
ContextAdd
Hello,
If i use vensim.contextAdd(1); Vensim not recognize me this command. I am working with vendlstc.dll.
Thank you
[Edited on 2-18-2009 by nika85]
If i use vensim.contextAdd(1); Vensim not recognize me this command. I am working with vendlstc.dll.
Thank you
[Edited on 2-18-2009 by nika85]
-
- Senior Member
- Posts: 1107
- Joined: Wed Mar 12, 2003 2:46 pm
-
- Senior Member
- Posts: 1107
- Joined: Wed Mar 12, 2003 2:46 pm
-
- Senior Member
- Posts: 1107
- Joined: Wed Mar 12, 2003 2:46 pm
If you want to provide responsive web performance you will need to use threads. If you are using Apache it will take care of creating the threads for you, so you only need to keep some information on the connection through cookies or another mechanism. You should also set a timer somewhere to drop contexts after a period of inactivity. You can probably find hints for doing these types of things on Apache or other web server forums.
Then, we are using Apache Tomcat so we need not enter anything in the code about threads?
And another question:
We are using the command:
Vensim vensim = new Vensim("library");
/**The library load correctly**/
- with CComand:
int cid = vensim.ContextAdd(0);
int r = vensim.CCommand(cid,"SPECIAL>LOADMODEL|c:\\.....\\WORLDAPP.vpm");
-with command
int r = vensim.command("SPECIAL>LOADMODEL|c:\\.....\\WORLDAPP.vpm");
withthe two commands returns 0, and we have the model in the specified path.
thanks for your help
[Edited on 2-20-2009 by nika85]
[Edited on 2-20-2009 by nika85]
And another question:
We are using the command:
Vensim vensim = new Vensim("library");
/**The library load correctly**/
- with CComand:
int cid = vensim.ContextAdd(0);
int r = vensim.CCommand(cid,"SPECIAL>LOADMODEL|c:\\.....\\WORLDAPP.vpm");
-with command
int r = vensim.command("SPECIAL>LOADMODEL|c:\\.....\\WORLDAPP.vpm");
withthe two commands returns 0, and we have the model in the specified path.
thanks for your help
[Edited on 2-20-2009 by nika85]
[Edited on 2-20-2009 by nika85]
-
- Senior Member
- Posts: 1107
- Joined: Wed Mar 12, 2003 2:46 pm
-
- Senior Member
- Posts: 1107
- Joined: Wed Mar 12, 2003 2:46 pm