Powershell menu , multiple choice (cli)

This topic contains 4 replies, has 3 voices, and was last updated by  bvi1998 . 3 years, 6 months ago.

  • Author
    Posts
  • #15241

    bvi1998 .
    Participant

    Hi, I have using this script found at posh:
    http://poshcode.org/2893

    I am trying to figure out how to use the multiple choice parameter, but am not advanced enough in Powershell to figure out how to do this. Would someone please help?
    Thanks!

  • #15243

    GregW
    Participant

    The parameter $multiplechoice is a switch parameter, so in order to call this function with that enabled you would just add "-multiplechoice" to your command line.

    If the switch parameter is passed, the value of $multiplechoice is $true, if it is not, the value is $false

    I didn't mention the alternate syntax because I don't really see when it would be useful, but you can see more in the following article.

    http://blogs.technet.com/b/orchestrator/archive/2012/05/04/oit-quick-tip-using-powershell-switch-parameters-in-cli-activities.aspx

  • #15244

    bvi1998 .
    Participant

    Excellent thanks for making that clear. Would there be a way to have a checkbox (in my dreams?) to choose?
    Is there a simpler way for them to choose as opposed to choosing them individually?
    Thanks!

  • #15258

    Don Jones
    Keymaster

    You'd have to code all of that yourself.

    • #15259

      bvi1998 .
      Participant

      yep, just wondering if it's possible to do any kind of checkmarks...
      My limitation here is that I am working with Powershell for Web Access which does not allow popups.
      I will be attending TechMentor in Redmond in August, so I hope to be improving my skills 🙂

You must be logged in to reply to this topic.