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

acdbWcs2Ucs in vb.net ?

6 REPLIES 6
Reply
Message 1 of 7
Anonymous
351 Views, 6 Replies

acdbWcs2Ucs in vb.net ?

Hi,

In C i was using the functions acdbWcs2Ucs to convert from one coordinate
system to another.
Because I can't find the function in VB i've made following function

CallingConvention:=CallingConvention.Cdecl)> _
Public Function acdbUcs2Wcs(ByVal fromPoint As Double(), ByVal toPoint
As Double(), ByVal vector As Boolean) As Integer
End Function
but when i'am using the function Acad crashes.

Any idea ?

Or another solution to convert from WCS2UCS, UCS2WCS, DCS2WCS,.... in vb ?

tnx,

Peter
6 REPLIES 6
Message 2 of 7
Anonymous
in reply to: Anonymous

EntryPoint:="?acdbUcs2Wcs@@YA_NQAN0_N@Z",
CallingConvention:=CallingConvention.Cdecl)> _
Public Shared Function acdbUcs2Wcs( ByRef inPt As Point3d, ByRef outPt As Point3d, ByVal vec As Boolean) As Boolean
End Function


--
http://www.caddzone.com

AcadXTabs: MDI Document Tabs for AutoCAD 2008
Supporting AutoCAD 2000 through 2008
http://www.acadxtabs.com

"Peter Warnez" wrote in message news:5541564@discussion.autodesk.com...
Hi,

In C i was using the functions acdbWcs2Ucs to convert from one coordinate
system to another.
Because I can't find the function in VB i've made following function

CallingConvention:=CallingConvention.Cdecl)> _
Public Function acdbUcs2Wcs(ByVal fromPoint As Double(), ByVal toPoint
As Double(), ByVal vector As Boolean) As Integer
End Function
but when i'am using the function Acad crashes.

Any idea ?

Or another solution to convert from WCS2UCS, UCS2WCS, DCS2WCS,.... in vb ?

tnx,

Peter
Message 3 of 7
Anonymous
in reply to: Anonymous


Hi. Don't use the declaration I posted in the last
message.

 

Autodesk's news server has mangled it.

 

To call the degree of stupidity and
size=1>ignorance reflected

by the design of Autodesk's online
size=1>discussion groups

astonishing, is an understatement.

 

I'll try it one more time:

 
<DllImport("acdb17.dll", EntryPoint:="?acdbUcs2Wcs@@YA_NQAN0_N@Z", CallingConvention:=CallingConvention.Cdecl)> _
Public Shared Function acdbUcs2Wcs(<Out> ByRef inPt As Point3d, <Out> ByRef outPt As Point3d, ByVal vec As Boolean) As Boolean
End Function
 

--
http://www.caddzone.com

 

AcadXTabs: MDI Document Tabs for AutoCAD 2008
Supporting
AutoCAD 2000 through 2008

size=1>http://www.acadxtabs.com


Hi,

In C i was using the functions
acdbWcs2Ucs to convert from one coordinate
system to another.
Because I
can't find the function in VB i've made following
function

<DllImport("acad.exe", EntryPoint:="acdbUcs2Wcs",

CallingConvention:=CallingConvention.Cdecl)> _
   
Public Function acdbUcs2Wcs(ByVal fromPoint As Double(), ByVal toPoint
As
Double(), ByVal vector As Boolean) As Integer
    End
Function
but when i'am using the function Acad crashes.

Any idea
?

Or another solution to convert from WCS2UCS, UCS2WCS, DCS2WCS,.... in
vb ?

tnx,

Peter
Message 4 of 7
Anonymous
in reply to: Anonymous

And sorry about all the embedded hyperlinks in the code
(actually it would be great if it lead you to the related
MSDN or other docs, rather than to Lutz Roeder's website).

--
http://www.caddzone.com

AcadXTabs: MDI Document Tabs for AutoCAD 2008
Supporting AutoCAD 2000 through 2008
http://www.acadxtabs.com

"Tony Tanzillo" wrote in message news:5541646@discussion.autodesk.com...
Hi. Don't use the declaration I posted in the last message.

Autodesk's news server has mangled it.

To call the degree of stupidity and ignorance reflected
by the design of Autodesk's online discussion groups
astonishing, is an understatement.

I'll try it one more time:

_
Public Shared Function acdbUcs2Wcs( ByRef inPt As Point3d, ByRef outPt As Point3d, ByVal vec As Boolean) As BooleanEnd Function
-- http://www.caddzone.com
AcadXTabs: MDI Document Tabs for AutoCAD 2008
Supporting AutoCAD 2000 through 2008
http://www.acadxtabs.com

"Peter Warnez" wrote in message news:5541564@discussion.autodesk.com...
Hi,

In C i was using the functions acdbWcs2Ucs to convert from one coordinate
system to another.
Because I can't find the function in VB i've made following function

CallingConvention:=CallingConvention.Cdecl)> _
Public Function acdbUcs2Wcs(ByVal fromPoint As Double(), ByVal toPoint
As Double(), ByVal vector As Boolean) As Integer
End Function
but when i'am using the function Acad crashes.

Any idea ?

Or another solution to convert from WCS2UCS, UCS2WCS, DCS2WCS,.... in vb ?

tnx,

Peter
Message 5 of 7
Anonymous
in reply to: Anonymous

Tnx a lot
Where can I find all that kind of stuff ?
If don't understand the way the function works....

greetings,

Peter


"Tony Tanzillo" schreef in bericht
news:5541652@discussion.autodesk.com...
And sorry about all the embedded hyperlinks in the code
(actually it would be great if it lead you to the related
MSDN or other docs, rather than to Lutz Roeder's website).

--
http://www.caddzone.com

AcadXTabs: MDI Document Tabs for AutoCAD 2008
Supporting AutoCAD 2000 through 2008
http://www.acadxtabs.com

"Tony Tanzillo" wrote in message
news:5541646@discussion.autodesk.com...
Hi. Don't use the declaration I posted in the last message.

Autodesk's news server has mangled it.

To call the degree of stupidity and ignorance reflected
by the design of Autodesk's online discussion groups
astonishing, is an understatement.

I'll try it one more time:

CallingConvention:=CallingConvention.Cdecl)> _
Public Shared Function acdbUcs2Wcs( ByRef inPt As Point3d, ByRef
outPt As Point3d, ByVal vec As Boolean) As BooleanEnd Function
-- http://www.caddzone.com
AcadXTabs: MDI Document Tabs for AutoCAD 2008
Supporting AutoCAD 2000 through 2008
http://www.acadxtabs.com

"Peter Warnez" wrote in message
news:5541564@discussion.autodesk.com...
Hi,

In C i was using the functions acdbWcs2Ucs to convert from one coordinate
system to another.
Because I can't find the function in VB i've made following function

CallingConvention:=CallingConvention.Cdecl)> _
Public Function acdbUcs2Wcs(ByVal fromPoint As Double(), ByVal toPoint
As Double(), ByVal vector As Boolean) As Integer
End Function
but when i'am using the function Acad crashes.

Any idea ?

Or another solution to convert from WCS2UCS, UCS2WCS, DCS2WCS,.... in vb ?

tnx,

Peter
Message 6 of 7
Anonymous
in reply to: Anonymous

Read this topic: http://through-the-interface.typepad.com/through_the_interface/2006/07/calling_objecta.html
Message 7 of 7
Anonymous
in reply to: Anonymous

You can use Depends.exe to look up exported functions
and their signatures.

--
http://www.caddzone.com

AcadXTabs: MDI Document Tabs for AutoCAD 2008
Supporting AutoCAD 2000 through 2008
http://www.acadxtabs.com

"Peter Warnez" wrote in message news:5541748@discussion.autodesk.com...
Tnx a lot
Where can I find all that kind of stuff ?
If don't understand the way the function works....

greetings,

Peter


"Tony Tanzillo" schreef in bericht
news:5541652@discussion.autodesk.com...
And sorry about all the embedded hyperlinks in the code
(actually it would be great if it lead you to the related
MSDN or other docs, rather than to Lutz Roeder's website).

--
http://www.caddzone.com

AcadXTabs: MDI Document Tabs for AutoCAD 2008
Supporting AutoCAD 2000 through 2008
http://www.acadxtabs.com

"Tony Tanzillo" wrote in message
news:5541646@discussion.autodesk.com...
Hi. Don't use the declaration I posted in the last message.

Autodesk's news server has mangled it.

To call the degree of stupidity and ignorance reflected
by the design of Autodesk's online discussion groups
astonishing, is an understatement.

I'll try it one more time:

CallingConvention:=CallingConvention.Cdecl)> _
Public Shared Function acdbUcs2Wcs( ByRef inPt As Point3d, ByRef
outPt As Point3d, ByVal vec As Boolean) As BooleanEnd Function
-- http://www.caddzone.com
AcadXTabs: MDI Document Tabs for AutoCAD 2008
Supporting AutoCAD 2000 through 2008
http://www.acadxtabs.com

"Peter Warnez" wrote in message
news:5541564@discussion.autodesk.com...
Hi,

In C i was using the functions acdbWcs2Ucs to convert from one coordinate
system to another.
Because I can't find the function in VB i've made following function

CallingConvention:=CallingConvention.Cdecl)> _
Public Function acdbUcs2Wcs(ByVal fromPoint As Double(), ByVal toPoint
As Double(), ByVal vector As Boolean) As Integer
End Function
but when i'am using the function Acad crashes.

Any idea ?

Or another solution to convert from WCS2UCS, UCS2WCS, DCS2WCS,.... in vb ?

tnx,

Peter

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

Post to forums  

Autodesk DevCon in Munich May 28-29th


Autodesk Design & Make Report

”Boost