Call C++ ObjectArx from .NET arx to overcome the .NET arx limitation.

Call C++ ObjectArx from .NET arx to overcome the .NET arx limitation.

Anonymous
Not applicable
695 Views
9 Replies
Message 1 of 10

Call C++ ObjectArx from .NET arx to overcome the .NET arx limitation.

Anonymous
Not applicable
Is it possible to call C++ ObjectArx from .NET arx to overcome limitations of .NET arx? Many thanks in advance. Zhongwei Xia
0 Likes
696 Views
9 Replies
Replies (9)
Message 2 of 10

Anonymous
Not applicable
What you can do is write a managed ObjectARX application in C++, and expose the functionality that you need in a managed class. This is similar to writing a COM wrapper, except that you would essentially be writing a .NET wrapper. Then, you can just reference this arx from your VB.NET or C# project and create an instance of your managed class. Hope this helps, Jon "Zhongwei Xia" wrote in message news:4249acec_2@newsprd01... > Is it possible to call C++ ObjectArx from .NET arx to overcome limitations > of .NET arx? > > Many thanks in advance. > Zhongwei Xia > >
0 Likes
Message 3 of 10

Anonymous
Not applicable
Jon, Thank you for your reply. Your email does help. It's a way to use C++ ObjectARX power to solve C# .net problems. We really need to have good documentation and samples for .NET AutoCAD application. Appreciate your help. Zhongwei "Jon Rizzo" wrote in message news:424afb54$1_1@newsprd01... > What you can do is write a managed ObjectARX application in C++, and > expose > the functionality that you need in a managed class. This is similar to > writing a COM wrapper, except that you would essentially be writing a .NET > wrapper. Then, you can just reference this arx from your VB.NET or C# > project and create an instance of your managed class. > > Hope this helps, > > Jon > > > "Zhongwei Xia" wrote in message > news:4249acec_2@newsprd01... >> Is it possible to call C++ ObjectArx from .NET arx to overcome >> limitations >> of .NET arx? >> >> Many thanks in advance. >> Zhongwei Xia >> >> > >
0 Likes
Message 4 of 10

Anonymous
Not applicable
The 2006 ObjectARX API contains a ton of managed code examples (look in Samples/dotNet). In addition, the new ObjectARX wizard gives you the option to create a project that has all of the compiler settings tweaked for a Managed C++ arx. Jon "Zhongwei Xia" wrote in message news:424c2568_2@newsprd01... > Jon, > > Thank you for your reply. > Your email does help. It's a way to use C++ ObjectARX power to solve C# .net > problems. We really need to have good documentation and samples for .NET > AutoCAD application. > > Appreciate your help. > Zhongwei > > > "Jon Rizzo" wrote in message > news:424afb54$1_1@newsprd01... > > What you can do is write a managed ObjectARX application in C++, and > > expose > > the functionality that you need in a managed class. This is similar to > > writing a COM wrapper, except that you would essentially be writing a .NET > > wrapper. Then, you can just reference this arx from your VB.NET or C# > > project and create an instance of your managed class. > > > > Hope this helps, > > > > Jon > > > > > > "Zhongwei Xia" wrote in message > > news:4249acec_2@newsprd01... > >> Is it possible to call C++ ObjectArx from .NET arx to overcome > >> limitations > >> of .NET arx? > >> > >> Many thanks in advance. > >> Zhongwei Xia > >> > >> > > > > > >
0 Likes
Message 5 of 10

Anonymous
Not applicable
Thank you for your email. I tried all .net samples from the 2006 ObjectARX SDK and all .NET samples I could find from ADN web site. But I still could not figure out my problem. I want to insert images into AutoCAD drawing file. I found an C++ sample from ADN, and I tried to user C#.net to do it. It doesn't work. Zhongwei "Jon Rizzo" wrote in message news:424c413c_3@newsprd01... > The 2006 ObjectARX API contains a ton of managed code examples (look in > Samples/dotNet). In addition, the new ObjectARX wizard gives you the > option > to create a project that has all of the compiler settings tweaked for a > Managed C++ arx. > > Jon > > > > "Zhongwei Xia" wrote in message > news:424c2568_2@newsprd01... >> Jon, >> >> Thank you for your reply. >> Your email does help. It's a way to use C++ ObjectARX power to solve C# > .net >> problems. We really need to have good documentation and samples for .NET >> AutoCAD application. >> >> Appreciate your help. >> Zhongwei >> >> >> "Jon Rizzo" wrote in message >> news:424afb54$1_1@newsprd01... >> > What you can do is write a managed ObjectARX application in C++, and >> > expose >> > the functionality that you need in a managed class. This is similar to >> > writing a COM wrapper, except that you would essentially be writing a > .NET >> > wrapper. Then, you can just reference this arx from your VB.NET or C# >> > project and create an instance of your managed class. >> > >> > Hope this helps, >> > >> > Jon >> > >> > >> > "Zhongwei Xia" wrote in message >> > news:4249acec_2@newsprd01... >> >> Is it possible to call C++ ObjectArx from .NET arx to overcome >> >> limitations >> >> of .NET arx? >> >> >> >> Many thanks in advance. >> >> Zhongwei Xia >> >> >> >> >> > >> > >> >> > >
0 Likes
Message 6 of 10

Anonymous
Not applicable
As I said, you can use the ObjectARX wizard to create an ARX using Managed C++. Create a managed class, and in that class, declare a static function that implements the C++ sample code that you found. Then, in your C# project, reference the ARX module and call the static function that you declared in your managed class. There are other ways to do this & you can get more complicated and elegant than this, but that's the basic idea. "Zhongwei Xia" wrote in message news:424c6cad_2@newsprd01... > Thank you for your email. > I tried all .net samples from the 2006 ObjectARX SDK and all .NET samples I > could find from ADN web site. But I still could not figure out my problem. > > I want to insert images into AutoCAD drawing file. I found an C++ sample > from ADN, and I tried to user C#.net to do it. It doesn't work. > > Zhongwei > > "Jon Rizzo" wrote in message > news:424c413c_3@newsprd01... > > The 2006 ObjectARX API contains a ton of managed code examples (look in > > Samples/dotNet). In addition, the new ObjectARX wizard gives you the > > option > > to create a project that has all of the compiler settings tweaked for a > > Managed C++ arx. > > > > Jon > > > > > > > > "Zhongwei Xia" wrote in message > > news:424c2568_2@newsprd01... > >> Jon, > >> > >> Thank you for your reply. > >> Your email does help. It's a way to use C++ ObjectARX power to solve C# > > .net > >> problems. We really need to have good documentation and samples for .NET > >> AutoCAD application. > >> > >> Appreciate your help. > >> Zhongwei > >> > >> > >> "Jon Rizzo" wrote in message > >> news:424afb54$1_1@newsprd01... > >> > What you can do is write a managed ObjectARX application in C++, and > >> > expose > >> > the functionality that you need in a managed class. This is similar to > >> > writing a COM wrapper, except that you would essentially be writing a > > .NET > >> > wrapper. Then, you can just reference this arx from your VB.NET or C# > >> > project and create an instance of your managed class. > >> > > >> > Hope this helps, > >> > > >> > Jon > >> > > >> > > >> > "Zhongwei Xia" wrote in message > >> > news:4249acec_2@newsprd01... > >> >> Is it possible to call C++ ObjectArx from .NET arx to overcome > >> >> limitations > >> >> of .NET arx? > >> >> > >> >> Many thanks in advance. > >> >> Zhongwei Xia > >> >> > >> >> > >> > > >> > > >> > >> > > > > > >
0 Likes
Message 7 of 10

Anonymous
Not applicable
BTW: The polysamp example shows a very detailed example of this (samples/entity/polysamp). Hope this helps, Jon "Jon Rizzo" wrote in message news:424c6ffa$1_3@newsprd01... > As I said, you can use the ObjectARX wizard to create an ARX using Managed > C++. Create a managed class, and in that class, declare a static function > that implements the C++ sample code that you found. > > Then, in your C# project, reference the ARX module and call the static > function that you declared in your managed class. There are other ways to > do this & you can get more complicated and elegant than this, but that's the > basic idea. > > > > "Zhongwei Xia" wrote in message > news:424c6cad_2@newsprd01... > > Thank you for your email. > > I tried all .net samples from the 2006 ObjectARX SDK and all .NET samples > I > > could find from ADN web site. But I still could not figure out my problem. > > > > I want to insert images into AutoCAD drawing file. I found an C++ sample > > from ADN, and I tried to user C#.net to do it. It doesn't work. > > > > Zhongwei > > > > "Jon Rizzo" wrote in message > > news:424c413c_3@newsprd01... > > > The 2006 ObjectARX API contains a ton of managed code examples (look in > > > Samples/dotNet). In addition, the new ObjectARX wizard gives you the > > > option > > > to create a project that has all of the compiler settings tweaked for a > > > Managed C++ arx. > > > > > > Jon > > > > > > > > > > > > "Zhongwei Xia" wrote in message > > > news:424c2568_2@newsprd01... > > >> Jon, > > >> > > >> Thank you for your reply. > > >> Your email does help. It's a way to use C++ ObjectARX power to solve C# > > > .net > > >> problems. We really need to have good documentation and samples for > .NET > > >> AutoCAD application. > > >> > > >> Appreciate your help. > > >> Zhongwei > > >> > > >> > > >> "Jon Rizzo" wrote in message > > >> news:424afb54$1_1@newsprd01... > > >> > What you can do is write a managed ObjectARX application in C++, and > > >> > expose > > >> > the functionality that you need in a managed class. This is similar > to > > >> > writing a COM wrapper, except that you would essentially be writing a > > > .NET > > >> > wrapper. Then, you can just reference this arx from your VB.NET or > C# > > >> > project and create an instance of your managed class. > > >> > > > >> > Hope this helps, > > >> > > > >> > Jon > > >> > > > >> > > > >> > "Zhongwei Xia" wrote in message > > >> > news:4249acec_2@newsprd01... > > >> >> Is it possible to call C++ ObjectArx from .NET arx to overcome > > >> >> limitations > > >> >> of .NET arx? > > >> >> > > >> >> Many thanks in advance. > > >> >> Zhongwei Xia > > >> >> > > >> >> > > >> > > > >> > > > >> > > >> > > > > > > > > > > > >
0 Likes
Message 8 of 10

Anonymous
Not applicable
Jon, Your answers are very helpful. I'm trying to do what you suggested. I'll let you know if I get things worked. Thank you very much. Zhongwei "Jon Rizzo" wrote in message news:424d5fcc$1_3@newsprd01... > BTW: The polysamp example shows a very detailed example of this > (samples/entity/polysamp). > > Hope this helps, > > Jon > > > "Jon Rizzo" wrote in message > news:424c6ffa$1_3@newsprd01... >> As I said, you can use the ObjectARX wizard to create an ARX using >> Managed >> C++. Create a managed class, and in that class, declare a static >> function >> that implements the C++ sample code that you found. >> >> Then, in your C# project, reference the ARX module and call the static >> function that you declared in your managed class. There are other ways >> to >> do this & you can get more complicated and elegant than this, but that's > the >> basic idea. >> >> >> >> "Zhongwei Xia" wrote in message >> news:424c6cad_2@newsprd01... >> > Thank you for your email. >> > I tried all .net samples from the 2006 ObjectARX SDK and all .NET > samples >> I >> > could find from ADN web site. But I still could not figure out my > problem. >> > >> > I want to insert images into AutoCAD drawing file. I found an C++ >> > sample >> > from ADN, and I tried to user C#.net to do it. It doesn't work. >> > >> > Zhongwei >> > >> > "Jon Rizzo" wrote in message >> > news:424c413c_3@newsprd01... >> > > The 2006 ObjectARX API contains a ton of managed code examples (look > in >> > > Samples/dotNet). In addition, the new ObjectARX wizard gives you the >> > > option >> > > to create a project that has all of the compiler settings tweaked for > a >> > > Managed C++ arx. >> > > >> > > Jon >> > > >> > > >> > > >> > > "Zhongwei Xia" wrote in message >> > > news:424c2568_2@newsprd01... >> > >> Jon, >> > >> >> > >> Thank you for your reply. >> > >> Your email does help. It's a way to use C++ ObjectARX power to solve > C# >> > > .net >> > >> problems. We really need to have good documentation and samples for >> .NET >> > >> AutoCAD application. >> > >> >> > >> Appreciate your help. >> > >> Zhongwei >> > >> >> > >> >> > >> "Jon Rizzo" wrote in message >> > >> news:424afb54$1_1@newsprd01... >> > >> > What you can do is write a managed ObjectARX application in C++, > and >> > >> > expose >> > >> > the functionality that you need in a managed class. This is > similar >> to >> > >> > writing a COM wrapper, except that you would essentially be >> > >> > writing > a >> > > .NET >> > >> > wrapper. Then, you can just reference this arx from your VB.NET >> > >> > or >> C# >> > >> > project and create an instance of your managed class. >> > >> > >> > >> > Hope this helps, >> > >> > >> > >> > Jon >> > >> > >> > >> > >> > >> > "Zhongwei Xia" wrote in message >> > >> > news:4249acec_2@newsprd01... >> > >> >> Is it possible to call C++ ObjectArx from .NET arx to overcome >> > >> >> limitations >> > >> >> of .NET arx? >> > >> >> >> > >> >> Many thanks in advance. >> > >> >> Zhongwei Xia >> > >> >> >> > >> >> >> > >> > >> > >> > >> > >> >> > >> >> > > >> > > >> > >> > >> >> > >
0 Likes
Message 9 of 10

Anonymous
Not applicable
Hi, Jon, I tried to do that, but I'm still having hard time to make it work. I created a simple C++ ObjectARX (just print a line in AutoCAD), then tried to user managed class to wrap it. It just doesn't work. Do you have any simple sample? Thank you very much. Zhongwei "Jon Rizzo" wrote in message news:424c6ffa$1_3@newsprd01... > As I said, you can use the ObjectARX wizard to create an ARX using Managed > C++. Create a managed class, and in that class, declare a static function > that implements the C++ sample code that you found. > > Then, in your C# project, reference the ARX module and call the static > function that you declared in your managed class. There are other ways to > do this & you can get more complicated and elegant than this, but that's > the > basic idea. > > > > "Zhongwei Xia" wrote in message > news:424c6cad_2@newsprd01... >> Thank you for your email. >> I tried all .net samples from the 2006 ObjectARX SDK and all .NET samples > I >> could find from ADN web site. But I still could not figure out my >> problem. >> >> I want to insert images into AutoCAD drawing file. I found an C++ sample >> from ADN, and I tried to user C#.net to do it. It doesn't work. >> >> Zhongwei >> >> "Jon Rizzo" wrote in message >> news:424c413c_3@newsprd01... >> > The 2006 ObjectARX API contains a ton of managed code examples (look in >> > Samples/dotNet). In addition, the new ObjectARX wizard gives you the >> > option >> > to create a project that has all of the compiler settings tweaked for a >> > Managed C++ arx. >> > >> > Jon >> > >> > >> > >> > "Zhongwei Xia" wrote in message >> > news:424c2568_2@newsprd01... >> >> Jon, >> >> >> >> Thank you for your reply. >> >> Your email does help. It's a way to use C++ ObjectARX power to solve >> >> C# >> > .net >> >> problems. We really need to have good documentation and samples for > .NET >> >> AutoCAD application. >> >> >> >> Appreciate your help. >> >> Zhongwei >> >> >> >> >> >> "Jon Rizzo" wrote in message >> >> news:424afb54$1_1@newsprd01... >> >> > What you can do is write a managed ObjectARX application in C++, and >> >> > expose >> >> > the functionality that you need in a managed class. This is similar > to >> >> > writing a COM wrapper, except that you would essentially be writing >> >> > a >> > .NET >> >> > wrapper. Then, you can just reference this arx from your VB.NET or > C# >> >> > project and create an instance of your managed class. >> >> > >> >> > Hope this helps, >> >> > >> >> > Jon >> >> > >> >> > >> >> > "Zhongwei Xia" wrote in message >> >> > news:4249acec_2@newsprd01... >> >> >> Is it possible to call C++ ObjectArx from .NET arx to overcome >> >> >> limitations >> >> >> of .NET arx? >> >> >> >> >> >> Many thanks in advance. >> >> >> Zhongwei Xia >> >> >> >> >> >> >> >> > >> >> > >> >> >> >> >> > >> > >> >> > >
0 Likes
Message 10 of 10

Anonymous
Not applicable
Can you give me a simple sample? I'm still having trouble to make it work. Thank you very much. Zhongwei "Jon Rizzo" wrote in message news:424c6ffa$1_3@newsprd01... > As I said, you can use the ObjectARX wizard to create an ARX using Managed > C++. Create a managed class, and in that class, declare a static function > that implements the C++ sample code that you found. > > Then, in your C# project, reference the ARX module and call the static > function that you declared in your managed class. There are other ways to > do this & you can get more complicated and elegant than this, but that's > the > basic idea. > > > > "Zhongwei Xia" wrote in message > news:424c6cad_2@newsprd01... >> Thank you for your email. >> I tried all .net samples from the 2006 ObjectARX SDK and all .NET samples > I >> could find from ADN web site. But I still could not figure out my >> problem. >> >> I want to insert images into AutoCAD drawing file. I found an C++ sample >> from ADN, and I tried to user C#.net to do it. It doesn't work. >> >> Zhongwei >> >> "Jon Rizzo" wrote in message >> news:424c413c_3@newsprd01... >> > The 2006 ObjectARX API contains a ton of managed code examples (look in >> > Samples/dotNet). In addition, the new ObjectARX wizard gives you the >> > option >> > to create a project that has all of the compiler settings tweaked for a >> > Managed C++ arx. >> > >> > Jon >> > >> > >> > >> > "Zhongwei Xia" wrote in message >> > news:424c2568_2@newsprd01... >> >> Jon, >> >> >> >> Thank you for your reply. >> >> Your email does help. It's a way to use C++ ObjectARX power to solve >> >> C# >> > .net >> >> problems. We really need to have good documentation and samples for > .NET >> >> AutoCAD application. >> >> >> >> Appreciate your help. >> >> Zhongwei >> >> >> >> >> >> "Jon Rizzo" wrote in message >> >> news:424afb54$1_1@newsprd01... >> >> > What you can do is write a managed ObjectARX application in C++, and >> >> > expose >> >> > the functionality that you need in a managed class. This is similar > to >> >> > writing a COM wrapper, except that you would essentially be writing >> >> > a >> > .NET >> >> > wrapper. Then, you can just reference this arx from your VB.NET or > C# >> >> > project and create an instance of your managed class. >> >> > >> >> > Hope this helps, >> >> > >> >> > Jon >> >> > >> >> > >> >> > "Zhongwei Xia" wrote in message >> >> > news:4249acec_2@newsprd01... >> >> >> Is it possible to call C++ ObjectArx from .NET arx to overcome >> >> >> limitations >> >> >> of .NET arx? >> >> >> >> >> >> Many thanks in advance. >> >> >> Zhongwei Xia >> >> >> >> >> >> >> >> > >> >> > >> >> >> >> >> > >> > >> >> > >
0 Likes