|
Post by angelo2449 on Jun 11, 2018 5:35:55 GMT -5
Hi Guys,
I have already tried to ask this question, now I try again, because I think an answer can exist!
I would like to pass variables between two different languages, Liberty Basic and Autolisp.
I know very well that it is not easy, but someone ..... Thank you.
|
|
|
Post by Chris Iverson on Jun 11, 2018 12:31:12 GMT -5
You generally need to find some way to communicate the value to the other program. It's usually done by using a temporary file. One program writes the file, the other one reads the value from it.
|
|
|
Post by angelo2449 on Jun 11, 2018 14:37:57 GMT -5
I have already tried this solution but it is difficult to synchronize the reading of temporary files. There are several PCs and different HDD, I get too many error messages, as well as being a complicated method even if I recognize that it is the only methods, for now, known. Surely it is possible to operate differently but how? Thank you.
|
|
|
Post by Chris Iverson on Jun 11, 2018 14:53:46 GMT -5
You can also use a windows feature called Named Pipes, which are essentially channels of communication directly between programs. They use the Win32 File API, but they don't exist as files, and they have useful abilities, such as knowing if the other end is actually listening/sending, and buffering data transferred between the two sides. I'll look to see if I still have a demo of using named pipes in LB. Part of the code on the wiki: basic.wikispaces.com/named+pipesBut the client-side part of the code is missing, and that code won't work at all if you can't open or use named pipes in AutoLisp, which I'm not familiar with at all.
|
|
|
Post by angelo2449 on Jun 12, 2018 4:55:06 GMT -5
Thanks Chris, I await your news.
|
|
|
Post by Brandon Parker on Jun 13, 2018 22:42:31 GMT -5
You should be able to use environment variables as well. I might have a simple example of this sitting around somewhere. I will try to find it tomorrow morning.
{:0)
Brandon Parker
|
|