cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
angusmf
Level 3

How to call WINAPI CreateFile instead of IS wrapper?

I need to get a file handle to a volume (not an actual file) and it's not clear that I can do that with the IS CreateFile function. What I actually need is the CreateFile function provided by kernel32.dll. Re-declaring CreateFile causes a compilation error. Is there a way to prototype this function with a different name for my IS script to use?
Labels (1)
0 Kudos
(1) Reply
joshstechnij
Level 10 Flexeran
Level 10 Flexeran

The Win32 CreateFile API is already prototyped in InstallScript as CreateFileA and CreateFileW. Use CreateFileW for the Unicode version of the API. You can see the existing prototypes in \InstallShield\2011\Script\ISRT\Include\ISRTWindows.h.
0 Kudos