|
Help!
by VoroneTZ. 10/14/25 05:04
|
|
|
|
|
|
|
|
4 registered members (Quad, AndrewAMD, TipmyPip, 1 invisible),
5,959
guests, and 2
spiders. |
Key:
Admin,
Global Mod,
Mod
|
|
|
[SOLVED] Using the SHCreateDirectoryExA function
#481192
08/12/20 13:33
08/12/20 13:33
|
Joined: Sep 2009
Posts: 1,032 Budapest
Aku_Aku
OP
Serious User
|
OP
Serious User
Joined: Sep 2009
Posts: 1,032
Budapest
|
Hi All! I tried to use this function: SHCreateDirectoryExAI can't call it to life. Here is how I tried to do: int WINAPI SHCreateDirectoryEx(HWND hwnd, LPCSTR pszPath, void* psa);
#define PRAGMA_API SHCreateDirectoryEx;Shell32.dll!SHCreateDirectoryExA
SHCreateDirectoryEx(NULL, _chr(pif), NULL);
I got a crash for the third line: "Script crash in main" I included the following headers: #include <acknex.h>
#include <strio.c>
#include <windows.h>
#include <stdio.h>
What should be the correct way of the usage of this function?
Last edited by Aku_Aku; 08/13/20 18:42.
|
|
|
Re: Using the SHCreateDirectoryExA function
[Re: Aku_Aku]
#481213
08/13/20 14:32
08/13/20 14:32
|
Joined: Sep 2009
Posts: 1,032 Budapest
Aku_Aku
OP
Serious User
|
OP
Serious User
Joined: Sep 2009
Posts: 1,032
Budapest
|
Interesting... I going to try it again, maybe I did something wrong. Thanks.
Edit: OK, I've catched the reason. The function declaration was in the main at my side. After I moved that out of the main, it suddenly began to work. Now it is OK. Thanks again Emre.
Last edited by Aku_Aku; 08/13/20 18:41.
|
|
|
Re: Using the SHCreateDirectoryExA function
[Re: Emre]
#481220
08/13/20 18:30
08/13/20 18:30
|
Joined: Sep 2009
Posts: 1,032 Budapest
Aku_Aku
OP
Serious User
|
OP
Serious User
Joined: Sep 2009
Posts: 1,032
Budapest
|
@Emre: Strange... Doesn't work for me... I have got the message: Script crashes in main. I am investigating more on that. It is OK now, as I explained in my edited previous post.
Last edited by Aku_Aku; 08/13/20 18:43.
|
|
|
|