cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Responding to NWAdmin in PowerShell?

I need to send a PowerShell script to my hosting enclave to run on my production server that will run NWAdmin.exe and use the RemoveAction

operation to get rid of some dead custom activties that didn't get uninstalled properly.

However, when I invoke NWAdmin.exe through PowerShell I can't figure out if it is possible to bypass the yes/no prompt NWAdmin

surfaces when the command is executed.

870 - Get Login Name (Category: Custom)

Activity: {Redacted}, {Redacted}, Version=1.0.1.4, Culture=neutral, PublicKeyToken={Redacted}

Adapter:  {Redacted}, {Redacted}, Version=1.0.1.4, Culture=neutral, PublicKeyToken= {Redacted}

Are you sure you want to remove this action? (yes / no)

Is there some way to pipe yes back to the command automatically or do I need to write a BAT file instead?

Tags (2)
0 Kudos
Reply
1 Reply
Not applicable

Re: Responding to NWAdmin in PowerShell?

So basically I couldn't figure it out and after some google-fu I came to the conclusion that I should just punt and write a

batch script which works just fine.

cd c:\Program Files\Nintex\Nintex Workflow 2010

echo y| NWAdmin.exe -o RemoveAction -id 874

Now I can have my production enclave run this after uninstalling our custom actions to eliminate any stale or

orphaned entries without having to worry about the prompts. Of course I need to add logging and a bunch of

other stuff to make it more robust, but you get the idea =)

0 Kudos
Reply