.NET

Reply
*Mike Tuersley
Message 21 of 49 (90 Views)

Re: Getting started with Dot Net

05-24-2005 10:55 PM in reply to: Somsekhar
No offense taken, Tony =)

My main point was exactly what you said, "No, it doesn't 'appear to be
object oriented', unless one does not understand what object oriented
really is and means." I was speaking of cad users who want to learn
programming and they don't have any idea what oop is at all. They also
don't want to pay to learn, they just want their 3day crash course to go
make whatever it is they want to make.

My background is actually Fortran and I understand oop. Unfortunately, I've
spent the last 4 years building a national dev team to support a national
sales team and have had very little time to keep up with the inner workings
of the languages I use and no time for formal training. Its all otj and
mostly late night and I'm lucky to just get the jobs out the door. Point
being I understand and am not arguing your points.

I am guilty of being an ex-lisper - kinda like an ex-smoker =) If you're
going to try muddling through vlisp, just jump the fence and learn vb.
There's more future in it even if you never grasp the true essence of oop
than there is in lisp. Its only a matter of time before acad evolves into
an inventor or revit and autolisp/vlisp goes away - heck, you don't even
need a command prompt now which kinda reminds me of getting that free
Windows version of R13 that I really didn't need....or did I? =) But that's
another speculative thread there.

-- Mike
___________________________
Mike Tuersley
___________________________
the trick is to realize that there is no spoon...
*Tony Tanzillo
Message 22 of 49 (90 Views)

Re: Getting started with Dot Net

05-25-2005 12:18 AM in reply to: Somsekhar
"Mike Tuersley" wrote

>> My main point was exactly what you said, "No, it doesn't 'appear to be
object oriented', unless one does not understand what object oriented
really is and means." I was speaking of cad users who want to learn
programming and they don't have any idea what oop is at all. They also
don't want to pay to learn, they just want their 3day crash course to go
make whatever it is they want to make. <<

Mike - As I see it, that's a large part of the problem.
One can't effectively use an object-oriented API like
the .NET framework, and the managed wrapper API for
ObjectARX, without having a reasonable understanding
of fundamental OOP concepts. If the framework one
is using is object-oriented, then one must have some
conceptual understanding of OOP in order to use the
framework.

That's how we arrive at solutions like the one I posted
for the palette activation event problem. Because we
understand object inheritance and how overridden virtual
methods can be used to alter the behavior of existing
objects, we know how to deal with that sort of problem.

Bug since that kind of solution is not even possible in
VB 'Classic', chances are good that even an expert VB6
programmer is not going to see that solution, and so
they tend to gravitate towards hacking and dangerous
kludges like subclassing.

I've been working with real OOP for at least 10 years,
and it's come to the point where I can't even use VB
Classic any more. Writing even a short sample program
that shows how to use a component developed in ARX,
is like Chinese water torture.

I consider myself lucky that I chose the Delphi path
long ago, and that's mainly because so much of the
.NET framework was actually modeled after and/or
inspired by Delphi and its VCL framework (the same
person that invented Delphi, also happens to be largely
responsible for significant parts of the .NET framework,
as well as the C# and J++ languages). Because of
that, transitioning from Delphi to .NET was like a walk
in the park.

Delphi itself is now a first-class .NET language, and I
can compile much of my existing Delphi code to .NET
managed code, or native Win32 code, with little to no
change.


AcadXTabs: MDI Document Tabs for AutoCAD 2004/2005/2006
http://www.acadxtabs.com
*Mike Tuersley
Message 23 of 49 (90 Views)

Re: Getting started with Dot Net

05-25-2005 06:36 AM in reply to: Somsekhar
Interesting....I always wanted to look into Delphi just never had the
chance, yet. And, for the record, my OOP skills are slightly under the
surface of the tip of the iceberg ;-)That's why I learn something from
almost all of your posts - even if its just another way to look at
something that I already know.

-- Mike
___________________________
Mike Tuersley
___________________________
the trick is to realize that there is no spoon...
Distinguished Contributor
jbryant4
Posts: 656
Registered: ‎12-12-2003
Message 24 of 49 (90 Views)

Re: Getting started with Dot Net

05-25-2005 09:53 AM in reply to: Somsekhar
"A major advantage of any program language over the Autolisp environment is avoidance of DCL files which are useless or anything but interaction with Autolisp".......Interaction with AutoLISP? What alse would you need them for?...Your statement in more false than it is true, and is nothing more then personal preference......Creating and Coding DCL's are tedious, but in most cases do the job fine...You can make VBA forms much easier (and prettier) but typically the code "after the form is created" will be 2-3 times longer. Of course, this is only my opinion...Ever noticed how the VLISP Discussion Group has about 4 times the activity that the VBA group has?...Wonder if that is because VBA is so much easier?
*Kenneth Hutson
Message 25 of 49 (90 Views)

Re: Getting started with Dot Net

05-25-2005 07:40 PM in reply to: Somsekhar
Som,

KrishnaK is right. Get to know the structure of the AutoCAD database. This
is foremost. Learn the capabilities and limitations of the languages
available. When confronted with a programming task, use your past experience
to select your language(s) based on the task at hand and the capabilities of
the language. In time your experience will grow. Try not to mix too many
languages together for a project.

I started with AutoLisp because that's all there was back then. VLisp gives
you an IDE and to me is the same thing as AutoLisp. AutoLisp offers a very,
very powerful way to manipulate the drawing database. You will find AutoLisp
can do things that other languages can't. If you are programming in AutoLisp
and need dialog boxes, use DCL. DCL was designed for AutoLisp. Don't
disregard it (as old fashioned as it appears).

VBA is cool. Form design just got alot easier. If you need to exchange
information between some other applications go with this. Try and explode a
hatch with it though.

I haven't had much experience with .NET Framework. I find it much like VBA.
More like VB. It's an exhastive collection of namespaces, classes,
properties and methods. Your biggest difficulty will be locating the correct
function to use.

Cheers,
Kenneth Hutson
San Antonio, TX
Member
Somsekhar
Posts: 3
Registered: ‎05-24-2005
Message 26 of 49 (90 Views)

Re: Getting started with Dot Net

05-26-2005 04:27 AM in reply to: Somsekhar
Thanks Krishna,
Your reply perhaps gives the right direction. I was really bewildered with the discussions/suggestions/arguments going in this group.
Shall start to understand the AutoCAD database first. And then get familiar with Object ARX. I have the .Net samples with me.
I think once I get to understand ARX, i can start with programming in .net for AutoCAD. What say ??
Thanks again.
Contributor
KrishnaK
Posts: 17
Registered: ‎05-24-2005
Message 27 of 49 (90 Views)

Re: Getting started with Dot Net

05-26-2005 11:03 AM in reply to: Somsekhar
Hi Somsekhar,
Like I said, you don't need to know ObjectARX to start learning .NET API although you would benefit from learning it. If you have the time, and if you know C++, then definitely look at the arxlabs folder and work out all the labs. It will be an uphill task at first, but you will surely appreciate it when you move on to the .NET API. You will realize later how easy it is to use the .NET API - yet getting the power of ObjectARX. Note: If you are planning on writing custom objects, it is possible only with C++. If you want to expose it to .NET, you will have to write a wrapper around it - for an example, check out "managed" project in polysamp (\samples\entity\polysamp).
*Frank Oquendo
Message 28 of 49 (90 Views)

Re: Getting started with Dot Net

05-26-2005 12:08 PM in reply to: Somsekhar
Somsekhar wrote:

> Shall start to understand the AutoCAD database first. And then get
> familiar with Object ARX.

That's not exactly the best way to proceed. You will come to understand
AutoCAD's mechanism's through the language you choose to use.

As for ObjectARX, it's C++ so there's not a whole lot of correlation
between it and sandbox languages like C# or VB.NET. ARX will only serve
to lengthen the learning curve so unless you intend to make it your
primary language, I'd skip it and move straight into C# or VB.NET.
*Laurie Comerford
Message 29 of 49 (90 Views)

Re: Getting started with Dot Net

05-26-2005 12:52 PM in reply to: Somsekhar
Hi Kenneth,

I cannot understand how you could advise anyone to waste time learning to
use DCL.

For someone who has been forced to use it because there was no alternative -
that's life.

But for someone who is looking to decide what language to program in, to
suggest that they should spend the hours/days necessary to setup their
first - second and third DCL forms is ludicrous. Maybe with a simple form
they could then get it down to an hour or two per form.

Lisp is powerful in its interaction with the AutoCAD drafting engine and
it's user interface (I'm still waiting for a VBA method to draw temporary
vectors and have to use a work around for that), but in over 20 years of
programming AutoCAD, inclusive of starting in VBA when it became available I
have never needed to use lisp for anything other an MNL file to call my VBA
commands.

The .NET environment removes the need for the MNL file functionality - it
may provide for temporary vectors, I don't know.

We are often told there are things you can do with lisp which you can't do
with anything else - but mostly they are things which for 99% of programs
don't need doing.

--


Laurie Comerford
CADApps
www.cadapps.com.au

"Kenneth Hutson" wrote in message
news:4856853@discussion.autodesk.com...
Som,

KrishnaK is right. Get to know the structure of the AutoCAD database. This
is foremost. Learn the capabilities and limitations of the languages
available. When confronted with a programming task, use your past experience
to select your language(s) based on the task at hand and the capabilities of
the language. In time your experience will grow. Try not to mix too many
languages together for a project.

I started with AutoLisp because that's all there was back then. VLisp gives
you an IDE and to me is the same thing as AutoLisp. AutoLisp offers a very,
very powerful way to manipulate the drawing database. You will find AutoLisp
can do things that other languages can't. If you are programming in AutoLisp
and need dialog boxes, use DCL. DCL was designed for AutoLisp. Don't
disregard it (as old fashioned as it appears).

VBA is cool. Form design just got alot easier. If you need to exchange
information between some other applications go with this. Try and explode a
hatch with it though.

I haven't had much experience with .NET Framework. I find it much like VBA.
More like VB. It's an exhastive collection of namespaces, classes,
properties and methods. Your biggest difficulty will be locating the correct
function to use.

Cheers,
Kenneth Hutson
San Antonio, TX
*Frank Oquendo
Message 30 of 49 (90 Views)

Re: Getting started with Dot Net

05-26-2005 12:55 PM in reply to: Somsekhar
Kenneth Hutson wrote:

> I haven't had much experience with .NET Framework. I find it much
> like VBA. More like VB.

.NET is nothing like VB.

> It's an exhastive collection of namespaces,
> classes, properties and methods. Your biggest difficulty will be
> locating the correct function to use.

That's a nice problem to have as opposed to having to find or write code
for common tasks.
Post to the Community

Have questions about Autodesk products? Ask the community.

New Post
Announcements
Do you have 60 seconds to spare? The Autodesk Community Team is revamping our site ranking system and we want your feedback! Please click here to launch the 5 question survey. As always your input is greatly appreciated.