using a win32 api in managed code 
Author Message
 using a win32 api in managed code

Hello all,

        I want to use a win32 api, ShellExecute located
in "shellapi.h". When I directly use it, say just include
the header file, even without actually calling the
function, it's popping up many errors.

        I'm a newbie to .Net environment. Can anyone
suggest a solution to this.

        Thanking you in advance.



Fri, 30 Sep 2005 14:09:27 GMT  
 using a win32 api in managed code

Quote:
> Hello all,

>         I want to use a win32 api, ShellExecute located
> in "shellapi.h". When I directly use it, say just include
> the header file, even without actually calling the
> function, it's popping up many errors.

>         I'm a newbie to .Net environment. Can anyone
> suggest a solution to this.

>         Thanking you in advance.

Ajay,

Include Shlobj.h before including shellapi.h, like this:

#include <Shlobj.h>
#include <shellapi.h>

It should work.

--
Artur Laksberg, Visual C++ Team
This posting is provided AS IS with no warranties, and confers no rights.



Sat, 08 Oct 2005 02:06:19 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Calling managed code from a Win32 dll

2. managed code vs. non-managed code

3. How printing in landscape mode using win32 api?

4. Printing using the Win32 API in C#

5. Info on Running Processes using WIN32 API

6. Can't call Win32 API when used by IIS

7. Win32 ODBC API Question on using SQLConnect() to Personal Oracle8i on Win2000

8. Can't populate Access Memo field using Win32 api

9. Win32 ODBC API Question on using SQLConnect() to Personal Oracle8i on Win2000

10. Creating a thread function using Win32 API

11. Changing User previliges using Win32 API

12. Q: Tabbed Strip/Dialog using Win32 API and native C

 

 
Powered by phpBB® Forum Software