Author |
Topic  |
|
rainlane
China
22 Posts |
Posted - 03/13/2017 : 06:38:44 AM
|
Operating System:Windows XP I used the Word to edit the Origin Graph. But, how to to it with Java. Or, somebody have useful resources about it. Thanks!
forum |
|
yuki_wu
896 Posts |
Posted - 03/14/2017 : 01:48:06 AM
|
Hi,
I am sorry that I cannot catch what you mean. Would you mind posting more?
1.How did you edit the Origin graph in MS word? Did you copy the graph page in Origin and then paste it into MS word, and then you double click the graph in MS Word to open the graph in Origin to re-edit it?
2.Do you want to access Java in Origin C?
We have a brief page to show users how to access Origin features programmatically, communicate with Origin from other applications and etc. I think you could take a look at this page at first and then you may know the outline of programming in Origin: http://www.originlab.com/doc/User-Guide/Programming-in-Origin
Regards, Yuki OriginLab
|
 |
|
rainlane
China
22 Posts |
Posted - 03/14/2017 : 02:38:00 AM
|
I copy the graph page in Origin and then paste it into MS word, and then double click the graph in MS Word to open the graph in MS word to re-edit it. I want to communicate with Origin from other applications made by Java or Visual C++.
 Like the picture shows,I made a client application using Java. I would like to call Origin in the client application,but how to call it?
quote: Originally posted by yuki_wu
Hi,
I am sorry that I cannot catch what you mean. Would you mind posting more?
1.How did you edit the Origin graph in MS word? Did you copy the graph page in Origin and then paste it into MS word, and then you double click the graph in MS Word to open the graph in Origin to re-edit it?
2.Do you want to access Java in Origin C?
We have a brief page to show users how to access Origin features programmatically, communicate with Origin from other applications and etc. I think you could take a look at this page at first and then you may know the outline of programming in Origin: http://www.originlab.com/doc/User-Guide/Programming-in-Origin
Regards, Yuki OriginLab
forum |
 |
|
yuki_wu
896 Posts |
Posted - 03/14/2017 : 03:38:38 AM
|
Hi,
Any application that supports COM programming can function as the client application that connects with Origin.
However, there is an important thing that you should know: Origin C code can only be executed in Origin. That is to say, it can NOT be called directly by other languages, e.g. C++, C#, Java, Python.
To execute Origin C code, you have to launch Origin as COM server for your client code, and use
Origin.LT_execute("run -oc {OCfunction();}");
to execute the Origin C function OCfunction() through Labtalk script.
Thus, you may find that it's not easy to get the return value of Origin C function. The workaround is to store the return value in a Labtalk variable, and then use
Origin.LT_get_var("ltVar", &val);
to retrieve the value.
This tutorial may help you to learn how to access COM via Java: http://www.developer.com/java/ent/article.php/770221/Access-COM-Via-Java----A-Tutorial.htm
Also, we have some COM examples that you may want to refer to: http://www.originlab.com/doc/COM/Examples
Hope it helps.
Regards, Yuki OriginLab
|
Edited by - yuki_wu on 03/14/2017 03:46:10 AM |
 |
|
ralin
2 Posts |
Posted - 02/14/2018 : 04:43:46 AM
|
So that's how it looks. Thanks, It will be very useful.
:) |
Edited by - ralin on 02/14/2018 04:44:00 AM |
 |
|
ralin
2 Posts |
|
|
Topic  |
|
|
|