Wrox Programmer Forums
|
C# Programming questions specific to the Microsoft C# language. See also the forum Beginning Visual C# to discuss that specific Wrox book and code.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the C# section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old September 2nd, 2004, 08:46 PM
Authorized User
 
Join Date: Jul 2004
Posts: 69
Thanks: 0
Thanked 1 Time in 1 Post
Default P/Invoking

I am just a little confused as to what the CRL does when I do a DllImport.

What if the function that I import is dependant upon other functions in the dll? Do I need to explicitly import them as well or are they imported, but I just don't have reference to them or is it something else entirely.

Thanks in advance

www.CoderForRent.com
Get A Computer Job!
 
Old September 4th, 2004, 01:31 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 453
Thanks: 0
Thanked 1 Time in 1 Post
Send a message via AIM to Ankur_Verma Send a message via MSN to Ankur_Verma
Default

If you look at how COM connects two islands, it gives out a standard interface with just the number and type of pointers that will enable you to call and excecute the desired functionality boxed inside the COM component. If any of the functions called needs to call another function in the COMponent it would do it internaly and the client (caller) doesnt need to know about it.

I think DLLImport provides the same type of run-time connectivity.
 
Old September 5th, 2004, 06:59 PM
Kep Kep is offline
Authorized User
 
Join Date: Aug 2003
Posts: 79
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Ankur is right. You only need to use DllImport for the functions YOU need to call in YOUR assembly.
Any internal calls within the imported library are handled without further coding on your part.

Kep.
 
Old September 7th, 2004, 09:26 PM
Authorized User
 
Join Date: Jul 2004
Posts: 69
Thanks: 0
Thanked 1 Time in 1 Post
Default

Thanks for the info. Cleared things right up!

www.CoderForRent.com
Get A Computer Job!





Similar Threads
Thread Thread Starter Forum Replies Last Post
Invoking ORACLE function asraj16 SQL Server 2005 4 August 20th, 2007 09:02 AM
Invoking Help File MichaelRReed1939 VB How-To 1 October 26th, 2006 10:37 AM
Invoking OWC in JSP sunildath_019 JSP Basics 0 March 17th, 2004 05:51 AM
Invoking OWC in JSP sunildath_019 Pro JSP 0 March 17th, 2004 05:48 AM
Invoking Wizard from VBA rcheikes Access VBA 0 January 28th, 2004 02:43 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.