Click here to Skip to main content
15,895,656 members
Home / Discussions / C#
   

C#

 
GeneralDrawString with extra spaces Pin
Werdna29-Apr-05 9:11
Werdna29-Apr-05 9:11 
QuestionWindows Installer C# api? Pin
DStarr29-Apr-05 8:48
DStarr29-Apr-05 8:48 
GeneralMdi form AutoScroll property Pin
M. Aamir Malik29-Apr-05 7:11
M. Aamir Malik29-Apr-05 7:11 
GeneralInstalling program Pin
Robske29-Apr-05 7:04
Robske29-Apr-05 7:04 
GeneralRe: Installing program Pin
Dave Kreskowiak29-Apr-05 7:39
mveDave Kreskowiak29-Apr-05 7:39 
GeneralRe: Installing program Pin
Fernando Soto29-Apr-05 7:44
Fernando Soto29-Apr-05 7:44 
GeneralRe: Installing program Pin
MoustafaS29-Apr-05 14:36
MoustafaS29-Apr-05 14:36 
GeneralCalling unmanaged code Pin
Frank Olorin Rizzi29-Apr-05 6:35
Frank Olorin Rizzi29-Apr-05 6:35 
Hi all. I haven't found an answer to this through quite some googling and searching, so I hope someone can provide some tips.

Here's the deal:
How can you call unmanaged code from a C# app?

Yeah, I know about a few ways to do it, but they all seem to rely
on the DllImport attribute initialized with the name of the DLL to be called at compile-time.

For instance:
[DllImport("msvcrt.dll")]

in my case, I will not know the name of the unmanaged dll to be called
until run-time. The name of the dll will come from a config file.
So, imagine

string unmanagedDll = this.GetUnmanagedDllNameFromConfigFile();

and now, is there any way to *programmatically* do the equivalent of
[DllImport(unmanagedDll)]

?

Thanks in advance for any suggestion,
F.O.R.


GeneralRe: Calling unmanaged code Pin
Dan_P29-Apr-05 15:12
Dan_P29-Apr-05 15:12 
GeneralRe: Calling unmanaged code Pin
Frank Olorin Rizzi30-Apr-05 1:31
Frank Olorin Rizzi30-Apr-05 1:31 
GeneralProject Ideas Pin
WillemM29-Apr-05 5:01
WillemM29-Apr-05 5:01 
GeneralRe: Project Ideas Pin
fizikci30-Apr-05 9:55
fizikci30-Apr-05 9:55 
GeneralRe: Project Ideas Pin
WillemM7-May-05 6:04
WillemM7-May-05 6:04 
GeneralRe: Project Ideas Pin
WillemM8-May-05 7:24
WillemM8-May-05 7:24 
QuestionIs their some api in windows for the detection of when a new window or form opens? Pin
FocusedWolf29-Apr-05 4:31
FocusedWolf29-Apr-05 4:31 
GeneralCustom events in VB,NET 2005 and c# Pin
rathishps29-Apr-05 3:55
rathishps29-Apr-05 3:55 
GeneralRe: Custom events in VB,NET 2005 and c# Pin
DavidNohejl29-Apr-05 4:11
DavidNohejl29-Apr-05 4:11 
QuestionHow get The index of last visible ListViewItem of a ListView Pin
djalmao29-Apr-05 3:25
djalmao29-Apr-05 3:25 
AnswerRe: How get The index of last visible ListViewItem of a ListView Pin
mav.northwind29-Apr-05 4:13
mav.northwind29-Apr-05 4:13 
GeneralRe: How get The index of last visible ListViewItem of a ListView Pin
djalmao29-Apr-05 5:16
djalmao29-Apr-05 5:16 
GeneralRe: How get The index of last visible ListViewItem of a ListView Pin
mav.northwind29-Apr-05 21:07
mav.northwind29-Apr-05 21:07 
GeneralRe: How get The index of last visible ListViewItem of a ListView Pin
djalmao3-May-05 20:59
djalmao3-May-05 20:59 
GeneralConvert graphic files to a JPEG format Pin
Anonymous29-Apr-05 2:55
Anonymous29-Apr-05 2:55 
GeneralRe: Convert graphic files to a JPEG format Pin
benjymous29-Apr-05 3:12
benjymous29-Apr-05 3:12 
QuestionDataGrid Control - right choice? Pin
LiamD29-Apr-05 0:50
LiamD29-Apr-05 0:50 

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.