Tech
Forums
Jobs
Books
Events
Videos
Conference
Annual Conference
Bcrypt
Ai Conference
Live
More
Interviews
Certification
Training
Career
Members
News
Blogs
Contribute
An Article
A Blog
A Video
An Ebook
An Interview Question
Register
Login
0
Answer
Pass by value or by reference?
Ask a question
Ask a question
Upload Source Code:
Select only zip and rar file.
normanordas
20y
1.3k
1
Reply
Using P/Invoke how would i know that i should be passing "by value" or "by reference" to the arguments of a method or function of the DLL? 2. Equivalent type in .Net of the used data type for each variable (e.g what's the equivalent type of BSTR in VB.Net/C#? 3. In the type library it says: VARIANT_BOOL _stdcall NE_QueryElementByID( [in] long net, [in] ElementTypeEnum eltype, [in, out] IDAttRec* id, [in, out] HandleAttRec* h); This is the way i called it in VB.Net...is this correct? ...
_ Public Shared Function NE_QueryElementByID(ByRef net As Long, ByRef eltype As ElementTypeEnum, ByRef id As IDAttRec, ByRef h As HandleAttRec) As Boolean End Function ... Dim h1 As HandleAttRec hi.Handle = 0 Dim id1 As IDAttRec Dim m_startid As Int32 = 4424 id1.UserID = 99 id1.LayerKey = 1 dim bol as Boolean = NE_QueryElementByID(net, ElementTypeEnum.NE_EDGE, id1, h1) Tnx a lot!
Post
Reset
Cancel
Answers (
0
)
Next Recommended Forum
Reflecting methods on a module
How to Convert old Visual Basic 6.0 API calls to C#