Page 1 of 2 12 LastLast
Results 1 to 5 of 7

Thread: InstallScript generate GUID's?

  1. #1
    Join Date
    Jan 2008
    Posts
    10

    InstallScript generate GUID's?

    Is it possible to write an Installscript function to generate a GUID/Uniqueidentifier?

  2. #2
    Join Date
    Oct 2001
    Location
    Here and there
    Posts
    16,233
    There's nothing built in, but please search these forums for "generate GUID installscript" to see several code samples...
    Robert Dickau - This and That - Flexera Software

    Want help? See Windows Installer white papers, training courses, newsletters, HelpNet, forum search, Knowledge Base, ...
    Want more help?
    See our InstallTalk blog.
    Want even more help? See our relatively new Advanced Windows Installer (MSI) training course.

  3. #3
    Join Date
    Jan 2008
    Posts
    10
    Maybe I am just blind, but I searched these forums for code/suggestions to do this, and was unable to figure it out. If I used some of the old code, it would not compile in version 14. I also found where in around version 6, someone submitted a help idea to Macrovision, and supposedly they came up with an object "InstallShield.GUID" that would create a guid. Yet I try this and have no luck either.

  4. #4
    Join Date
    Oct 2001
    Location
    Here and there
    Posts
    16,233
    I haven't tried it, but does the code in this thread work? Or could you post the code that fails?

    (There is a GenerateGUID method of the ISWiProject object, but that's available only at design/build time, and not run time.)
    Robert Dickau - This and That - Flexera Software

    Want help? See Windows Installer white papers, training courses, newsletters, HelpNet, forum search, Knowledge Base, ...
    Want more help?
    See our InstallTalk blog.
    Want even more help? See our relatively new Advanced Windows Installer (MSI) training course.

  5. #5
    Join Date
    Jan 2008
    Posts
    10
    Here are the error messages when it compiles...

    C:\HelloWorld\InstallShield\HelloWorldInstall\script files\setup.rul(116) : error C8025: 'S_OK' : undefined identifier
    C:\HelloWorld\InstallShield\HelloWorldInstall\script files\setup.rul(145) : error C8025: 'WideCharToMultiByte' : undefined identifier
    C:\HelloWorld\InstallShield\HelloWorldInstall\script files\setup.rul(146) : error C8025: 'CP_ACP' : undefined identifier
    C:\HelloWorld\InstallShield\HelloWorldInstall\script files\setup.rul(145) : error C8041: '(' : function type required

Page 1 of 2 12 LastLast

Posting Permissions

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