TheSwamp

Code Red => .NET => Topic started by: BazzaCAD on July 24, 2006, 11:46:33 PM

Title: Command line Netload
Post by: BazzaCAD on July 24, 2006, 11:46:33 PM
Is there a command line version of netload?
So you can add it to an acad.lsp so it loads for everyone on the network or do you have to use the startup suite and a prefile?
Title: Re: Command line Netload
Post by: Alexander Rivilis on July 25, 2006, 02:19:51 AM
Is there a command line version of netload?
So you can add it to an acad.lsp so it loads for everyone on the network or do you have to use the startup suite and a prefile?
Code: [Select]
(command "_.netload" path_to_dll) ;; path_to_dll is a full path to assembly
Title: Re: Command line Netload
Post by: Kerry on July 25, 2006, 04:04:28 AM
I thought I'd seen something on this ...

Quote
"Tony Tanzillo" <tony.tanzillo@U_KNOW_WHERE.com>
wrote in message news:<news:5119482@discussion.autodesk.com>...
A managed assembly (DLL) cannot be executed across
machine boundaries, unless you set special security
permissions (one way is Control Panel-> Administrative
Tools -> .NET Framework Configuration/Wizards).

I haven't tried, but it should be fairly easy to confirm this.

Title: Re: Command line Netload
Post by: BazzaCAD on July 25, 2006, 02:52:43 PM
Is there a command line version of netload?
So you can add it to an acad.lsp so it loads for everyone on the network or do you have to use the startup suite and a prefile?
Code: [Select]
(command "_.netload" path_to_dll) ;; path_to_dll is a full path to assembly

That was too easy, thx.
Title: Re: Command line Netload
Post by: Bobby C. Jones on July 25, 2006, 03:45:32 PM
That was too easy, thx.

Hey Bazza :-)
Just curious, are you loading the assembly from a network location?
Title: Re: Command line Netload
Post by: BazzaCAD on July 25, 2006, 07:31:29 PM
That was too easy, thx.

Hey Bazza :-)
Just curious, are you loading the assembly from a network location?

I was hoping to.
Is that a prob. ?
Title: Re: Command line Netload
Post by: Bobby C. Jones on July 25, 2006, 08:31:56 PM
I was hoping to.
Is that a prob. ?
The CLR doesn't like it.  But I haven't explored it enough to know anything about how to get it to work.  That's why I asked.  I wanted to see what hoops you had to jump through to get it working.
Title: Re: Command line Netload
Post by: www1970 on July 25, 2006, 10:53:17 PM
path_to_dll  ought this style
(defun S::STARTUP()
(command "netload" "E:\\VBnetArxLib\\Projects\\CommonLib\\CommonLib\\bin\\Debug\\commonlib")
(princ "已加载netload")
)

"\\" not "\"
Title: Re: Command line Netload
Post by: BazzaCAD on July 27, 2006, 02:07:25 AM
I was hoping to.
Is that a prob. ?
The CLR doesn't like it.  But I haven't explored it enough to know anything about how to get it to work.  That's why I asked.  I wanted to see what hoops you had to jump through to get it working.

So if I copy it there harddrive first, then should it be ok?
Title: Re: Command line Netload
Post by: Kerry on July 27, 2006, 03:21:13 AM
Barry, did you read my post ?

What have YOU tried, and what were the results ?
Title: Re: Command line Netload
Post by: BazzaCAD on July 27, 2006, 02:49:10 PM
Barry, did you read my post ?

What have YOU tried, and what were the results ?

Sorry Kerry, It's hard to reply to every post. Yes I did read your post.
I haven't tried to load anything off the network yet, I'm just trying to plan ahead. But I do know I don't wont to have to go to each person PC in the office and go through Control Panel-> Administrative
Tools -> .NET Framework Configuration/Wizards.

Seams to me like the .NET .DLL's are more of a pain to deal with the the C++ .ARX's
It has a (ARXLOAD) function, instead of (command "netload") & can be loaded off of the network...
Why is that?
Title: Re: Command line Netload
Post by: Kerry on July 27, 2006, 04:38:57 PM
It isn't just for Autocad. To my understanding the restriction is a security feature with managed assemblies.

..........Seams to me like the .NET .DLL's are more of a pain to deal with the the C++ .ARX's

You don't have to used net DLL's.
Title: Re: Command line Netload
Post by: MickD on July 27, 2006, 06:01:00 PM
Why can't you just install the dll/s into a program folder on the users machine, I know updating is a bit of a pain but that's the way it is. Perhaps you can write a batch file to distrubute an updated dll after work hours?
Can this be done Kerry? I could use this myself :)
Title: Re: Command line Netload
Post by: Kerry on July 27, 2006, 06:33:11 PM
A batch file to run at system Startup on the slave which XCopys files from the server would be the way I'd do it. There may be better ways, but I go with what I know works.

I assume the OP means an intranet network. 
Title: Re: Command line Netload
Post by: MickD on July 27, 2006, 06:39:48 PM
That sounds like a plan!
Off to study the 'forgotten art of the batch file'. Be back soon :)
Title: Re: Command line Netload
Post by: BazzaCAD on July 27, 2006, 06:49:14 PM
A batch file to run at system Startup on the slave which XCopys files from the server would be the way I'd do it. There may be better ways, but I go with what I know works.

I assume the OP means an intranet network. 

That's what I ment when I asked?
"So if I copy it to there harddrive first, then should it be ok?"

RoboCopy is a good option also. It will sync the file. I.E. only copy it to the harddrive if the network version is newer the the local version.
I'm not sure id Xcopy has that option.