Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 80005
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 10, 20262026-05-10T21:14:05+00:00 2026-05-10T21:14:05+00:00

I’d like to call caspol from within a script inside a custom action in

  • 0

I’d like to call caspol from within a script inside a custom action in an msi (setup project). I’d prefer a standard msi to ClickOnce, because with a standard msi I can install drivers & associate filetypes with our application whereas with ClickOnce I can’t.

When I execute the caspol command from the command line it succeeds, but from within vbscript it always fails with the error ‘Fehler: Unbekannte Mitgliedschaftsbedingung – -url..’ – which translates as ‘Error: Unknown membership condition: -url’. To further clarify: A copy & paste of the generated command works fine on the command line directly on the local drive of a virgin virtual machine, as local administrator, as part of a workgroup.

I have two ideas: 1. I’m no vbscript king, so maybe I’ve missed quotes or made some other sort of syntax error. 2. Caspol recognises that I’m running it from within a script and halts with an intentionally nonsensical error.

Personally, I believe it’s just a dumb syntax error.

Here’s my script:

set sh = CreateObject('Wscript.Shell') Set fso = CreateObject('Scripting.FileSystemObject')  dim command dim location dim retVal  location = fso.GetFile(Wscript.ScriptFullName).ParentFolder  '%windir%\microsoft.net\framework\v2.0.50727\caspol.exe -pp off -m -addgroup 1 –url file://COMPUTER/SHARE/* FullTrust -name sbw2 command = fso.GetSpecialFolder(0) & '\microsoft.net\framework\v2.0.50727\caspol.exe -pp off -m -ag 1 –url file://' for each s in Split(location, '\')         if Len(s) > 0 then                 command = command & s & '/'         end if next command = command & '* FullTrust -name sbw2'  'DEBUG 'command = fso.GetSpecialFolder(0) & '\microsoft.net\framework\v2.0.50727\caspol.exe -m -ag 1 –url file://mjlaptop/sbw2/* FullTrust' Wscript.StdOut.WriteLine VbClrf Wscript.StdOut.WriteLine command Wscript.StdOut.WriteLine VbClrf  Set output = sh.Exec(command)  dim text while Not output.StdOut.AtEndOfStream         text = text & output.StdOut.Read(1) Wend Wscript.StdOut.WriteLine text 

Thanks in advance,

Matt

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-10T21:14:05+00:00Added an answer on May 10, 2026 at 9:14 pm

    Change url formatting of url in command to \\mjlaptop\sbw2* for some reason, formatted as ‘file://…’ won’t work. With or without quotes.

    This uid (yossarian) belongs to me (Matt Jacobsen) too. I’d had to use the above as claimid was down for maintennance.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 80k
  • Answers 80k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer I agree with @Ken White's answer that comma-delimited lists have… May 11, 2026 at 4:21 pm
  • Editorial Team
    Editorial Team added an answer You can specify any CSS selector to get at your… May 11, 2026 at 4:21 pm
  • Editorial Team
    Editorial Team added an answer This is ultimately handled in Web.config. Look for the httpRuntime… May 11, 2026 at 4:21 pm

Related Questions

I ran into a problem. Wrote the following code snippet: teksti = teksti.Trim() teksti
I am currently running into a problem where an element is coming back from
Seemingly simple, but I cannot find anything relevant on the web. What is the
Configuring TinyMCE to allow for tags, based on a customer requirement. My config is
Is it possible to replace javascript w/ HTML if JavaScript is not enabled on

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.