Autodesk Technology Managers Forum
Share your knowledge, ask questions, and engage with fellow CAD/BIM Managers.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

calling lic server with lisp

3 REPLIES 3
Reply
Message 1 of 4
devon.middleditch
287 Views, 3 Replies

calling lic server with lisp

Hi,

How would you go about calling up your license server with lisp.

We want to add some lookup code to our acaddoc.lsp to check that the license server is the correct one and then if not, exit autocad.

Any help would be appreciated.

Devon
3 REPLIES 3
Message 2 of 4
Anonymous
in reply to: devon.middleditch

devon said the following On 10/16/2006 12:56 AM:
> Hi,
>
> How would you go about calling up your license server with lisp.
>
> We want to add some lookup code to our acaddoc.lsp to check that the license server is the correct one and then if not, exit autocad.
>
> Any help would be appreciated.
>

Here is what I do.

I created a .VBS file that sets the appropriate windows environment
variable. This .VBS file is stored in a read-only location. (See below
for example)

Then I call this .VBS file using "acad.lsp" (which only fires once per
session) to make sure that the appropriate server names are listed. (See
below for example)

98% of the time this frequent checking/setting of the server names is
unnecessary, but when we send a new machine out I don't have to worry
about .LIC files or anything. If a server is added/deleted - all I have
to do us update the VBS file and the next AutoCAD launch by a client
updates Windows.


===============VBS FILE EXAMPLE===================
on error resume next
Set WshShell = Wscript.CreateObject("Wscript.Shell")
Set WshSysEnv = WshShell.Environment("SYSTEM")
WshSysEnv.item("ADSKFLEX_LICENSE_FILE") = "@SERVER1;@SERVER2;@SERVER3"
===============VBS FILE EXAMPLE===================

===============CALL VBS FILE FROM LISP EXAMPLE===================
(startapp "wscript" "\\\\SERVER\\share\\AutoDesk\\SetEnv.vbs")
===============CALL VBS FILE FROM LISP EXAMPLE===================

--
R.K. McSwain
http://rkmcswain.blogspot.com
Message 3 of 4
Anonymous
in reply to: devon.middleditch

the problem with this method is that it cannot be run by a non administrator
just put this vbs code into the windows login script for license server
changes.


--
Dave

"R.K. McSwain" wrote in message
news:5363492@discussion.autodesk.com...
devon said the following On 10/16/2006 12:56 AM:
> Hi,
>
> How would you go about calling up your license server with lisp.
>
> We want to add some lookup code to our acaddoc.lsp to check that the
> license server is the correct one and then if not, exit autocad.
>
> Any help would be appreciated.
>

Here is what I do.

I created a .VBS file that sets the appropriate windows environment
variable. This .VBS file is stored in a read-only location. (See below
for example)

Then I call this .VBS file using "acad.lsp" (which only fires once per
session) to make sure that the appropriate server names are listed. (See
below for example)

98% of the time this frequent checking/setting of the server names is
unnecessary, but when we send a new machine out I don't have to worry
about .LIC files or anything. If a server is added/deleted - all I have
to do us update the VBS file and the next AutoCAD launch by a client
updates Windows.


===============VBS FILE EXAMPLE===================
on error resume next
Set WshShell = Wscript.CreateObject("Wscript.Shell")
Set WshSysEnv = WshShell.Environment("SYSTEM")
WshSysEnv.item("ADSKFLEX_LICENSE_FILE") = "@SERVER1;@SERVER2;@SERVER3"
===============VBS FILE EXAMPLE===================

===============CALL VBS FILE FROM LISP EXAMPLE===================
(startapp "wscript" "\\\\SERVER\\share\\AutoDesk\\SetEnv.vbs")
===============CALL VBS FILE FROM LISP EXAMPLE===================

--
R.K. McSwain
http://rkmcswain.blogspot.com
Message 4 of 4

Thanks for the reply.

I was looking for a maybe less attractive option.

All we are trying to do is stop our code from being stolen from contractors who copy files and stick it on their own server. So i figured if I was able to have the acaddoc.lsp do a lookup on the lic server, then unless they had the matching one, the acaddoc.lsp would then bomb out and our customisation won't load.

Any idea?

thanks
Devon

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Administrator Productivity


Autodesk Design & Make Report