ObjectARX
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

C# and Plotting

3 REPLIES 3
Reply
Message 1 of 4
Anonymous
1040 Views, 3 Replies

C# and Plotting

Hello,

 

I develop winforms in C#.

I need to develop a very simple UI and code that will be shown/invoked when the person working at my client company plots his/her drawing. I am not sure what version of Autocad will be used, it might be 2014, or the previous version.

 

I need to "prompt" the user for the Job Id, and three other items.

With one of the fields I prompt for, I will want to populate it from a database.

 

Could I get a very simple introduction on how to do this?

 

Thank you,

 

RR

3 REPLIES 3
Message 2 of 4
fenton.webb
in reply to: Anonymous

Is the question on how to create the UI or for plotting? or both? Or are you asking how to read an external database value or are you asking how to read a DWG database value?

 

If you haven't seen it I recommend watching our DevTv's also checking out the other resources at http://www.autodesk.com/developautocad




Fenton Webb
AutoCAD Engineering
Autodesk

Message 3 of 4
Anonymous
in reply to: fenton.webb

Hi Fenton,



Thanks a lot for responding to my question on the forum.



It's a bit difficult for me to explain ***technically*** what exactly I need
to do.

I am brand new to AutoCad, and I don't completely understand what I need to
do, programmatically.

The fellow I met with yesterday is preparing a statement of work, which will
better layout, in detail, what I need to do technically.



What I can do is explain what needs to be accomplished.

My client is a surveying company that has thousands of drawings.

When they plot a drawing, they need to charge the printing costs back to the
job.

The jobs are recorded in a Microsoft SQL Server 2008 database.



They are using Plotminder (www.cadfx.com/pmind) currently, but need a more
customized solution.

If you take a look at this screenshot
of Plotminder, you will see that there is a small additional dialog that
appears at the bottom of the Autocad plot dialog.

This is the functionality I need to replace, but with the following changes:

1. All four entry fields (Job, Media, Plot Type, and Comment) will be
combo boxes that will be populated from the MSSQL database

2. Business rules (and a table within the database) will determine
whether the print job is billable

3. Not sure I need to do this, but I wonder if, based on business
rules, I can disable the OK button for plotting

4. When the user clicks on the OK button to plot, a variety of data
(the four fields plus a bunch of other data relating to cost) will be
inserted into a table in the database

5. Other data will include size of the drawing, print area
(width/height), plotter selected, and metatags/attributes that are part of
the drawing.

6. The surveying company will be moving up to a newer version of
Autocad, probably 2014.



I'm wondering if there is a small example of how I can integrate this
functionality into Autocad.

A basic "hello world" intro that would allow me to create a dialog box with
one combo box populated with three values, say "Andrew, Bob, and Chris".



I develop in C# in VS 2010. All the backend database work I can do with my
eyes closed.

The central issue in my mind is how do I "integrate" this into Autocad. My
first question may be a bit silly, but here it is: What kind of VS project
will I create in order to get started? "Windows Forms Application", "WPF
Application", "Console Application", "Class Library", or "WPF Browser
Application"?



Any suggestions, and pointers are most appreciated.



Richard

cid:image001.jpg@01CE7E41.C3647DC0
Message 4 of 4
Balaji_Ram
in reply to: Anonymous

Hi,

 

If you are new to AutoCAD programming, please download the .Net training material from the developer center.

There are eight tutorials with code and detailed explanations to get you started with AutoCAD programming.

 

For displaying UI in AutoCAD, lab-4 from .Net training material will help :

http://usa.autodesk.com/adsk/servlet/index?siteID=123112&id=1911627

 

If you have specific questions while implementing the functionality, you can post your specific query in this forum.

 

 



Balaji
Developer Technical Services
Autodesk Developer Network

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

Post to forums  

Forma Design Contest


Autodesk Design & Make Report