|
-
Sep 18th, 2000, 03:41 PM
#1
Thread Starter
Frenzied Member
I'm trying to do this:
Code:
Private Declare Function DllRegisterServer Lib app.path & "dimava.ocx" () As Long
Private Declare Function DllUnregisterServer Lib "MyDll.Dll" () As Long
Const ERROR_SUCCESS = &H0
so it comes up to a synax error, why?
(P.S. this is the declerations part of the Registaring an OCX/DLL code)
NXSupport - Your one-stop source for computer help
-
Sep 18th, 2000, 04:04 PM
#2
Put dimava.ocx in the C:\Windows\System directory and use this:
Code:
Private Declare Function DllRegisterServer Lib "dimava.ocx" () As Long
Private Declare Function DllUnregisterServer Lib "dimava.ocx" () As Long
Const ERROR_SUCCESS = &H0
-
Sep 18th, 2000, 04:28 PM
#3
Thread Starter
Frenzied Member
that will work, but for many reasons I want ymy ocx's kept in the same folder with my programs, so I was thinking mabye something like:
Code:
Dim strOCX as string
Private Declare Function DllRegisterServer Lib strOCX () As Long
Private Declare Function DllUnregisterServer Lib strOCX () As Long
Const ERROR_SUCCESS = &H0
but that doesn't work either
NXSupport - Your one-stop source for computer help
-
Sep 18th, 2000, 05:15 PM
#4
Instead of using App.Path, simply specify the path manually.
Code:
Private Declare Function DllRegisterServer Lib "C:\MyPath\dimava.ocx" () As Long
-
Sep 18th, 2000, 05:16 PM
#5
If you don't want to do that, than I suggest you move it to the Windows\System directory. It is best to be located there. So no matter where you exe file has been moved, it will always work. Whereas, if your exe file was moved to a different folder, but the ocx stayed in the same place, it would probably create an error.
-
Sep 18th, 2000, 05:19 PM
#6
Thread Starter
Frenzied Member
I want it to be in the same folder as the program, and megatron, the user selects the folder where they want all of the files to be installed to
NXSupport - Your one-stop source for computer help
-
Sep 18th, 2000, 06:50 PM
#7
dimava:
RegSvr32.exe is only about 30kb..
it won't make your apps that much bigger...
not that you could actually make something good enough to distribute.... but thats just IMO.....
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|