Click here to Skip to main content
15,881,600 members
Home / Discussions / C#
   

C#

 
GeneralRe: Handling of unmanaged code by the .NET environment Pin
Eric Gunnerson (msft)9-Oct-02 8:31
Eric Gunnerson (msft)9-Oct-02 8:31 
GeneralOrder of events when a form is displayed Pin
Wjousts9-Oct-02 2:00
Wjousts9-Oct-02 2:00 
GeneralRe: Order of events when a form is displayed Pin
Daniel Turini9-Oct-02 4:01
Daniel Turini9-Oct-02 4:01 
GeneralRe: Order of events when a form is displayed Pin
Gaul9-Oct-02 5:24
Gaul9-Oct-02 5:24 
GeneralRe: Order of events when a form is displayed Pin
Wjousts9-Oct-02 10:54
Wjousts9-Oct-02 10:54 
Questionhow to do it??? Pin
8-Oct-02 21:04
suss8-Oct-02 21:04 
AnswerRe: how to do it??? Pin
Marc Clifton9-Oct-02 0:10
mvaMarc Clifton9-Oct-02 0:10 
QuestionPlatform invoke??? Pin
Vu Truong8-Oct-02 17:54
Vu Truong8-Oct-02 17:54 
Hi all,

using System.Runtime.InteropServices;
...
[DllImport("ole32.dll")]
public static extern long CLSIDFromProgID(string ProgID, out Guid clsID);
...
Guid clsID;
long ret = CLSIDFromProgID("Excel.Application", out clsID);

if(ret==0)
System.Console.WriteLine("OK.");
else
System.Console.WriteLine("Fail.");

I use above codes for checking Microsoft Excel is installed or not. But it doesn't work at all, even if I already installed Microsoft Excel.

Are there any missing in my codes?
AnswerRe: Platform invoke??? Pin
Stephane Rodriguez.8-Oct-02 19:31
Stephane Rodriguez.8-Oct-02 19:31 
GeneralRe: Platform invoke??? Pin
Vu Truong8-Oct-02 21:08
Vu Truong8-Oct-02 21:08 
AnswerRe: Platform invoke??? Pin
Richard Deeming9-Oct-02 1:22
mveRichard Deeming9-Oct-02 1:22 
AnswerRe: Platform invoke??? Pin
Eric Gunnerson (msft)9-Oct-02 8:25
Eric Gunnerson (msft)9-Oct-02 8:25 
GeneralRe: Platform invoke??? Pin
Jörgen Sigvardsson9-Oct-02 13:43
Jörgen Sigvardsson9-Oct-02 13:43 
GeneralRe: Platform invoke??? Pin
Eric Gunnerson (msft)10-Oct-02 7:58
Eric Gunnerson (msft)10-Oct-02 7:58 
GeneralRe: Platform invoke??? Pin
David Stone9-Oct-02 14:21
sitebuilderDavid Stone9-Oct-02 14:21 
GeneralRe: Platform invoke??? Pin
Eric Gunnerson (msft)10-Oct-02 7:54
Eric Gunnerson (msft)10-Oct-02 7:54 
GeneralRe: Platform invoke??? Pin
Jörgen Sigvardsson10-Oct-02 8:51
Jörgen Sigvardsson10-Oct-02 8:51 
GeneralRe: Platform invoke??? Pin
Eric Gunnerson (msft)10-Oct-02 9:00
Eric Gunnerson (msft)10-Oct-02 9:00 
GeneralRe: Platform invoke??? Pin
Nick Parker10-Oct-02 9:29
protectorNick Parker10-Oct-02 9:29 
GeneralRe: Platform invoke??? Pin
Eric Gunnerson (msft)10-Oct-02 10:17
Eric Gunnerson (msft)10-Oct-02 10:17 
GeneralRe: Platform invoke??? Pin
Nick Parker10-Oct-02 10:20
protectorNick Parker10-Oct-02 10:20 
GeneralRe: Platform invoke??? Pin
David Stone10-Oct-02 11:34
sitebuilderDavid Stone10-Oct-02 11:34 
GeneralRe: Platform invoke??? Pin
Eric Gunnerson (msft)10-Oct-02 11:51
Eric Gunnerson (msft)10-Oct-02 11:51 
GeneralRe: Platform invoke??? Pin
David Stone10-Oct-02 15:53
sitebuilderDavid Stone10-Oct-02 15:53 
GeneralRe: Platform invoke??? Pin
Vu Truong9-Oct-02 18:21
Vu Truong9-Oct-02 18:21 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.