Results 1 to 6 of 6
  1. #1
    Platinum Lounger
    Join Date
    Feb 2001
    Location
    Yilgarn region of Toronto, Ontario
    Posts
    5,453
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Bad DLL calling convention (Excel 2003)

    Also known as "Run time error 49".
    A couple of threads refer to this - <post#=507,914>post 507,914</post#> and <post#=478,440>post 478,440</post#>.
    I spent some time trying to figure out which parameters to my called function were corrupted before I stumbled across several references elsewhere to ExcelVBA corruption.
    Rob Bovey's Code Cleaner not being available to me (on this locked-down system), I had to resort to manually exporting the forms and modules to a fresh folder, and reimporting them to a new workbook, at my standard hourly rates, of course.
    Problem appears to be solved.
    (Although I still miss Rob Bovey's Code Cleaner http://www.appspro.com/Utilities/CodeCleaner.htm...)

  2. #2
    Platinum Lounger
    Join Date
    Feb 2001
    Location
    Yilgarn region of Toronto, Ontario
    Posts
    5,453
    Thanks
    0
    Thanked 0 Times in 0 Posts
    [quote name='chrisgreaves' post='755893' date='29-Jan-2009 17:17'][/quote]
    FYI
    I've had it again, this time in a long-time working Word2000 application of my own authorship.

    Over the past week I've had occasion to install Office 2003, de-install it, re-install it, repair Office 2000, and so on.

    This afternoon some WordVBA code tries to:
    Code:
    Dim xlApp As New Excel.Application
    Dim docTemplate As Excel.workbook
    Set docTemplate = xlApp.Workbooks.Open(strTemplate)
    and baulks, even though the reference is correctly pointing to the Microsoft Excel 9.0 Object Library.

    Repairing the Office 2000 installation did not bring success.
    Deleting the Office 2000 installation, and then re-installing it appears to have got me over the hurdle.

  3. #3
    Platinum Lounger
    Join Date
    Feb 2001
    Location
    Weert, Limburg, Netherlands
    Posts
    4,812
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I still have the old version, which is an Excel addin.
    Attached Files Attached Files
    Jan Karel Pieterse
    Microsoft Excel MVP, WMVP
    www.jkp-ads.com
    Professional Office Developers Association

  4. #4
    Platinum Lounger
    Join Date
    Feb 2001
    Location
    Yilgarn region of Toronto, Ontario
    Posts
    5,453
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Thanks, Jan Karel
    I have this and several other methods of cleaning code.
    Especially when I am working on graphic objects, such as GUI forms, within a Word/Excel project, I code-clean about once every two hours. It is fast, and cheaper than losing 6 hours work.
    In this case, even through the project was being cleaned regularly, it came up with the error. The re-install of Office 2000 seemed to fix the problem.

  5. #5
    Platinum Lounger
    Join Date
    Feb 2001
    Location
    Weert, Limburg, Netherlands
    Posts
    4,812
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I attached the xla because you said you had a locked down system and hence didn't have access to Bovey's code cleaner (which is a COM addin now)
    Jan Karel Pieterse
    Microsoft Excel MVP, WMVP
    www.jkp-ads.com
    Professional Office Developers Association

  6. #6
    Platinum Lounger
    Join Date
    Feb 2001
    Location
    Yilgarn region of Toronto, Ontario
    Posts
    5,453
    Thanks
    0
    Thanked 0 Times in 0 Posts
    [quote name='pieterse' post='777016' date='26-May-2009 11:39']... because you said you had a locked down system ...[/quote]
    Ah! I see.
    Thanks.
    The locked down system was somewhere else (as a result of which I did back then d/l the earlier version of which you speak.
    I replied to my own post mainly to assemble a couple of fixes to one problem in one place. I ought to have stated that in my original reply to the original post.
    I apologize for the confusion.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •