• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Compile error on opening excel macro file of 97-2003 in Windows 11

jraju

Member
Hi, I do not know macros. There was a excel macro sheet sent for my use. On opening it, I receive compile error. On clicking ok, button, on opening the excel sheet, there are value, name NA errors all thro the workbook. It was a workbook with macros version 97-2003.
Elsewhere in the discussion on this, I found that I should see the tools reference of enabled references by using alt F11. That is also included for ready reference.
I am using windows 11, as such, there is no 32 bit . The same workbook works perfectly in older machine having excel 2007 and there is no value name na errors.
The work book also contain a swedll32.dll, which I had correctly copied in system folder in program files, system 32 folder, and syswow64folder for it to work correctly. I am unable to send the workbook, as it is done by others .
Could you say how do i fix it. Virtual Box does not support in win 11, as such i am not able to use the older version of excel macro file without error
 

Attachments

  • compile error macro 97-2003 workbook.jpg
    compile error macro 97-2003 workbook.jpg
    330.2 KB · Views: 5
  • compile.png
    compile.png
    238.7 KB · Views: 5
Hi, you are confusing Windows 32 / 64 bits and Excel 32 / 64 bits …​
Your previous 2007 Excel version is only a 32 bits version whatever the Windows version.​
As a 32 bits Excel version can work on Windows 64 bits version, if it's not the case under Windows 11 so no solution …​
Just ask to the creator of the dll file if it is compatible under 64 bits.​
If not, as often the case with old dll, you can very not use it under a 64 bits Excel version but only with a 32 bits Excel version.​
As Microsoft itself since Excel 2010 advises to install 32 bits Excel version rather than 64 bits version …​
 
hi, Thanks for your reply
So, what you say, is use any excel of 32 version and the macro will work.
Will try. But please say, why the dll file has to be installed in system folder. I have worked with macro files which would prompt , enable macros if you trust the source warning and enabling works very well.
Is the dll connected with excel. Normally you open the file and enable macros and then just work with it.
Is there any chance that I could only install excel out of the total microsoft office package
Or should I have to install msoffice 2010 for 32 bit totaly on the system.
Or is there any alternate to excel that is available free to work with.
please say,
 
As a dll file is very not 'connected' with Excel but refers to Windows, to see with your IT, like for the 32 bits Excel installation …​
So any 64 bits 'alternate to Excel' should get the same issue but may be ok with a 32 bits version only.​
According to the error message I suppose you and your IT already tried to add the PtrSafe statement like you can see in VBA help​
or like the other forum should have already shared with you this information, sample here : Declaring API functions in 64 bit Office …​
If still not works with PtrSafe so as Microsoft advises use only a 32 bits Excel version.​
 
Back
Top