+ Reply to Thread
Results 1 to 2 of 2

ExecuteExcel4Macro, REGISTER, and DLLs

Hybrid View

  1. #1
    Registered User
    Join Date
    01-18-2005
    Posts
    1

    Question ExecuteExcel4Macro, REGISTER, and DLLs

    I am trying to use ExecuteExcel4Macro to REGISTER functions in an external DLL for use within an add-in. I want to do this, instead of a standard "Declare" or "RegisterXLL" statement, because the ExecuteExcel4Macro (REGISTER) allows argument descriptions to show up on the function-paste wizard. As far as I know, this is the only way to show argument descriptions for a user defined function (UDF).

    My problem is this: it seems that calling ExecuteExcel4Macro has a 255 character string length limitation on the argument string, so the argument descriptions end up being very short. I am also having problems executing the REGISTER function in an Excel 4 Macro Sheet directly. I am using Excel 2002 SP-1, and I am wondering if REGISTER has been disabled from Excel 97, or if my calling is just wrong.

    The following website has the statement "REGISTER.ID can be used on worksheets (unlike REGISTER), but you cannot specify a function name and argument names with REGISTER.ID."

    Even an example taken from the Microsoft Web Page describing REGISTER.ID, does not work:
    REGISTER.ID("Kernel32", "GetTickCount", "J!")
    The return value of the above statement, when entered into cell A1 of a macro sheet is FALSE instead of a registration number, as if the function call failed.

    For more information on REGISTER itself, look here.

    So, I am looking for help on the proper way to use REGISTER, either by calling with ExecuteExcel4Macro or in an Excel 4 macro sheet which will allow argument descriptions and not be limited by a 255 character string length.

    Thanks for any help or advice.

  2. #2
    Registered User
    Join Date
    02-07-2012
    Location
    Sunderland, UK
    MS-Off Ver
    Excel 2007
    Posts
    1

    Re: ExecuteExcel4Macro, REGISTER, and DLLs

    Hi RileyF,

    This may be a little late, but I think I know the answer to this question.

    Sir david

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1