teratail header banner
teratail header banner
質問するログイン新規登録

回答編集履歴

1

KBより引用

2021/10/28 07:35

投稿

退会済みユーザー
answer CHANGED
@@ -2,4 +2,15 @@
2
2
  [INFO: The Windows 95 Rundll and Rundll32 Interface
3
3
  ](https://www.betaarchive.com/wiki/index.php?title=Microsoft_KB_Archive/164787)
4
4
 
5
+ > How to Write Your DLL
6
+ In your DLL, write the <entrypoint> function with the following prototype:
7
+
8
+ > 16-bit DLL:
9
+ void FAR PASCAL __loadds
10
+ EntryPoint(HWND hwnd, HINSTANCE hinst, LPSTR lpszCmdLine, int nCmdShow);
11
+
12
+ > 32-bit DLL:
13
+ void CALLBACK
14
+ EntryPoint(HWND hwnd, HINSTANCE hinst, LPSTR lpszCmdLine, int nCmdShow);
15
+
5
16
  rundllはDLLのどのようなエクスポート関数でも実行出来る訳ではなく、rundllで実行出来るように作られた形式の関数じゃないと正しく動作しません。元々Microsoftが内部使用する為に存在するものなので、安易に使うものではないです。