+ Reply to Thread
Results 1 to 4 of 4

Thread: Extracting hostname from mapped drive variable

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1

    Default Extracting hostname from mapped drive variable

    A registry entry I want to use needs the UNC hostname and path to the folder, but my users will often just select a mapped drive. Can SB extract the host and folderpath name from, say, the PROGDIR variable so it can be used in the Registry.

    For context, I need the registry entry so that end users can open a specific chm help file located on a different machine without permitting all chm files to be opened.

    Any suggestions would be very much appreciated.

    Thanks.

  2. #2
    Join Date
    Mar 2004
    Posts
    4,307

    Default Re: Extracting hostname from mapped drive variable

    Hello,

    Please see String Functions (Extract Server Name and Extract Share Name).

    Does this help?

  3. #3

    Default Re: Extracting hostname from mapped drive variable

    Thanks, Freidrich, that's half the battle. The Extract Server Name and Share Name functions use the UNC for the shared resource. First, I need to convert the mapped drive its UNC equivalent. Any suggestions?

  4. #4
    Join Date
    Mar 2004
    Posts
    4,307

    Default Re: Extracting hostname from mapped drive variable

    Perhaps a DLL Call to Windows Networking WNetGetUniversalName (MPR.DLL) API?

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. #00015: Is there a system PATH Environment Variable Size Limit in XP?
    By FAQ in forum SetupBuilder FAQs, Tips and Techniques
    Replies: 0
    Last Post: 04-03-2006, 07:42 AM
  2. Using a variable in Install Files
    By NewsArchive in forum SetupBuilder - NNTP
    Replies: 11
    Last Post: 01-24-2006, 01:30 AM
  3. Cannot open and compress service file - error
    By NewsArchive in forum SetupBuilder - NNTP
    Replies: 6
    Last Post: 12-06-2005, 04:40 AM
  4. _SB_ROOT and variable paths
    By NewsArchive in forum SetupBuilder - NNTP
    Replies: 6
    Last Post: 03-16-2005, 10:35 AM

Tags for this Thread

Posting Permissions

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