1. S

    customer DLL; run-time error 53

    Dear Mr.Excel; I have the following fragment in my Add-in (written with VBA7.1): Option Explicit Public Declare PtrSafe Sub mysubTst Lib "mylibTst.dll" () Public Sub Tst() mysubTst End Sub it behaves as expected under Windows ver.10.0.19045 with XL 2307(16626.20134) but fails with RTErr 53...
  2. A

    What is Application.Sendkeys for "Windows" key in VBA ?

    There is no documentation of "windows" key :Application.SendKeys method (Excel) So, I tried "Ctrl+Esc" for windows key : Application.SendKeys ("^({ESC}{LEFT})") but it didn't work. Is there a way to send windows key using API, dll etc without using external programs like AutoIt.
  3. Jaafar Tribak

    Getting the list of all Enums in TypeLibs via code (Like the Object Browser)

    Hi all, This is a similar concept to the topic of this thread. Only this time, instead of retrieving Properties and Methods of Objects, the code now retrieves the names and values of all the native ENUM constants contained in typelibs. No extrenal libraries required. the functions in the code...
  4. S

    ActiveX cant create object

    I have created ClassLibrary1 DLL successfully using VSStudio2019. Also, added the .tlb as reference withing VBA. But when I set the object, I get "ActiveX cant create object". My DLL namespace is ClassLibrary1 and the class within the namespace is Class1 and function within is TestFunction()...
  5. S

    VBA / dll project ideas

    Hi, I have quite a few years experience with VBA and have developed various dashboards and tools using APIs and web scraping etc. I'm looking to further increase my skills and wondered if anyone had any cool project ideas. I really don't mind what it is. I'm particularly interested in getting...
  6. B

    Your Microsoft Access database or project contains a missing or broken reference to the file ‘OSAMAXA.dll’ version 1.0.

    Hi When trying to open an access file, I am getting below message. If I click OKAY on this, I get further pop-ups with similar type of messages. Only the dll name is changed. I guess, this is about missing dll, but not sure, also how does I fix this. Can anyone please tell me what does this...
  7. J

    Error handling if VBA reference not found?

    Hi, I have an Excel macro that requires a reference (DLL) and if the DLL isn't found I get "Compile Error, can't find project or library" Is there a way I can handle this error by checking if the DLL exists then msgbox / exit sub Thanks for any help
  8. Y

    Load a custom DLL programmatically from another path

    I have a DLL with I don't want to put it in the system folder. I do I let VBA, how do I load dll from the path I want?
  9. P

    How to set a path to a dll in VBA

    I'd like to ensure that my code is linking to a dll that I've placed in the same folder as my spreadsheet. What code would I use to do this? This is the code that I'm working with. The dll is swedll32.dll. https://pastebin.com/nfwkHRfA
  10. T

    DLL loading question

    so i'm reading this link https://msdn.microsoft.com/en-us/library/office/bb687915.aspx#sectionSection2 i've created a spreadsheet i'm able to do a Public declare of my DLL function called "myfunc" and write a VBA macro calling that DLL function called "mymacro" then i enter that macro name...
  11. J

    Issues with Arrays and DLLs

    I'm having a problem with getting arrays populated with functions that are called from a dll. A quick example is: Private Declare Function MHL200_GetDLLVersion Lib "dll path" (ByRef pulDllVersion() As Long) As MHL200_ErrorEnum Then, I call it as such: Dim ulaVersion(2) As Long...
  12. Y

    How to avoid Excel to shut down if a dll crashes?

    I have developed a dll in Fortran, and calls it from Excel. Normally this works very good. If the dll crashes during execution (for example due to division by zero or some other problem) also Excel crashes down, without saving. I have tried to add On Error Goto... before the call to the dll...
  13. Jaafar Tribak

    Intercepting resetting of vba editor as well as unhandled errors for safe subclassing

    Hi all, As you know, excel doesn't expose many useful events such as when activating excel or when moving or resizing its main window etc... The way to catch these missing events is through subclassing or hooking excel. Both techniques work in compiled programs but they freeze office...
  14. B

    C dll compare integers not behaving as expected

    I am about to transfer a project written in Applescript and Objective C to Excel/VBA/dll. I have started with the Objective C functions that I want to place in a dll and call via VBA. The Objective C is C with a thin dusting of special Obejctive C code to have it talk with Applescript and the...
  15. H

    Calling a DLL based Macro from worksheet

    Hi All, We have successfully implemented a <acronym title="visual basic for applications">VBA</acronym> macro ( below ) that calls and executes a function from a DLL. We are happy with the macro as it behaves as expected. Now, however, we'd like to call the Function that the macro runs from a...
  16. R

    Call C++ DLL from VBA - problem with string and LPCSTR*

    Hi, I'm having problems when I try to call a function in a C++ DLL from VBA. There's a function "execute" in a dll. I don't have the dll code, but I have a C++ function "run_execute" that calls that function "execute", and I'm trying to do the same on a VBA code. I'm not sure what's going...
  17. R

    Tools -> Reference -> Browse -- Hangs

    Hi I'm trying to use DirectSound in Excel VBA. I've gotten it to work in VBA 2010 Express. But when I try to load the reference in VBA -> Tools -> Reference -> Browse and select C:\Windows\Microsoft.Net\DirectX for Managed Code\1.0.2902.0\Microsoft.DirectX.DirectSound.dll, Excel/VBA will work on...
  18. O

    DLL entry point error

    I made a .DLL useing VB 2010 Express and want to call it in Excel VBA. Here is my DLL code PublicFunction MPSIDNum(ByVal LookupType AsLong, ByVal MPSValue AsString) Dim oConnection As ADODB.Connection Dim oRecordset As ADOR.Recordset Dim FieldCol AsString FieldCol = SetField(LookupType)...
  19. L

    How to call a DLL from excel?

    Greetings to the masses of excel officianado's, When it comes to using VBA to manipulate excel, i don't have too many quandaries, yet when it comes to communicating with other programs, i'm not up to speed. I was given the SDK to a third party software to interact with monitoring device that...
  20. D

    Excel 64bit: ActiveX component can't create object

    I've been using a COM dll in all previous versions of XL but now that I'm running Office 2010 64bit I get the error "ActiveX component can't create object" when I try to instantiate the object from the linked library <code> Set mCrypKeyObj = New CrypKeySDK7 </code> The library comes...

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back