.NET

Reply
Active Member
ajoshi1967
Posts: 9
Registered: ‎09-30-2010
Message 1 of 5 (501 Views)

AutoCad Script Files

501 Views, 4 Replies
10-01-2013 01:34 AM

I need Help on Following :

 

1. Is it possible to read excel files through script files.

 

2. Can I declare variables in script files.

 

 

Mentor
mzakiralam
Posts: 231
Registered: ‎11-09-2012
Message 2 of 5 (491 Views)

Re: AutoCad Script Files

10-01-2013 02:45 AM in reply to: ajoshi1967
Please mention clearly what do you want. Only then someone can help you.
Valued Mentor
gasty1001
Posts: 466
Registered: ‎04-11-2010
Message 3 of 5 (470 Views)

Re: AutoCad Script Files

10-01-2013 11:12 AM in reply to: ajoshi1967

Hi,

 

If by script you mean AutoCAd .scr files, the short answer is NO, scripts are just a list of AutoCAd commands that execute almost unconditionally (there is no if ..then else, goto, or things alike)  and with some limitations, but scipts can call AutoLISP code or a VBA macro to execute, and both can access excel files.

 

Gaston Nunez

Active Member
ajoshi1967
Posts: 9
Registered: ‎09-30-2010
Message 4 of 5 (454 Views)

Re: AutoCad Script Files

10-01-2013 07:00 PM in reply to: gasty1001
Thanks a lot Mr. Nunez.
This exactly what I wanted. I have a full fledge program in Autocad VBA. Different offices of our company uses different version of Autocad. So we want have a programming tool which will be independent of version of Autocad. Do you think script files can be better choice.

Can you send me sample code script file which can access vba code
Valued Mentor
gasty1001
Posts: 466
Registered: ‎04-11-2010
Message 5 of 5 (449 Views)

Re: AutoCad Script Files

10-01-2013 08:34 PM in reply to: ajoshi1967

Hi,

 

It's just a line in a text file, put this line : -vbarun SomeAutoCADVBAMacro in a txt file with scr extension and voila.

 

Gaston Nunez

Announcements
Are you familiar with the Autodesk Expert Elites? The Expert Elite program is made up of customers that help other customers by sharing knowledge and exemplifying an engaging style of collaboration. To learn more, please visit our Expert Elite website.
Need installation help?

Start with some of our most frequented solutions or visit the Installation and Licensing Forum to get help installing your software.