Search found 19 matches

by jerris
Thu Sep 10, 2015 7:57 am
Forum: PowerShell Studio
Topic: Adding additional Controls to PowerShell Studio
Replies: 1
Views: 812

Adding additional Controls to PowerShell Studio

I couldn't find this answer, so I hope it's not a duplicate post. Is it possible to add additional controls into PowerShell Studio? If not, is there an article that shows the appropriate way to add external .net controls into a GUI form?

Same question for Control Sets.
by jerris
Tue Feb 03, 2015 9:45 am
Forum: PowerShell GUIs
Topic: PING TEST
Replies: 6
Views: 1631

Re: PING TEST

Looks like you almost go it. All you need to do now is instead of writing it to output, you change the text of the textbox. You can do this by calling the textbox by name and modifying the .text property like this: $buttonPing_Click={ $DC = '192.168.10.1' $HYPERSRV = '192.168.10.2' $EXCHG = '192.168...
by jerris
Wed Mar 19, 2014 2:29 pm
Forum: PowerShell GUIs
Topic: Help with PS script side of a datagridview box...
Replies: 12
Views: 5739

Re: Help with PS script side of a datagridview box...

I forgot you had to be a member of the site to view the "Upload file" portion of that page. :( The site's still a work in progress. I got the comment though and will dig through the code tonight sometime and make some suggestions.
by jerris
Wed Mar 19, 2014 2:21 pm
Forum: PowerShell GUIs
Topic: Help with PS script side of a datagridview box...
Replies: 12
Views: 5739

Re: Help with PS script side of a datagridview box...

You're so close.

Add -AsPlainText before -force
PowerShell Code
Double-click the code block to select all.
ConvertTo-secureString "P@$$word1" -AsPlainText -force
by jerris
Wed Mar 19, 2014 1:10 pm
Forum: PowerShell GUIs
Topic: Help with PS script side of a datagridview box...
Replies: 12
Views: 5739

Re: Help with PS script side of a datagridview box...

If you want, you can upload a copy of the .ps1 export to here:
http://www.powershellguiscripts.com/upload/

I'll take a crack at cleaning it up for you.
by jerris
Wed Mar 19, 2014 12:49 pm
Forum: PowerShell GUIs
Topic: Help with PS script side of a datagridview box...
Replies: 12
Views: 5739

Re: Help with PS script side of a datagridview box...

It does appear to be a syntax error with your get-content command. I don't think it does what you think it does. You're grabbing the text from the textbox in your form that has "bentest" in it and trying to use get-content incorrectly. Get-Content grabs the content of a text file. It's looking on yo...
by jerris
Wed Mar 19, 2014 12:34 pm
Forum: Windows PowerShell
Topic: Combing listbox items in command
Replies: 23
Views: 10113

Re: Combing listbox items in command

Try this:
PowerShell Code
Double-click the code block to select all.
$buttonExecute_Click={
	foreach($user in $listbox1.SelectedItems)
	{
		foreach($group in $listbox2.SelectedItems){
			Add-DistributionGroupMember -Identity $group -Member $user.ToString()
		}
	}
}
by jerris
Wed Mar 19, 2014 11:08 am
Forum: PowerShell GUIs
Topic: Simple database example
Replies: 5
Views: 1955

Re: Simple database example

Call me old school, but personally, for settings, I'm a much bigger fan of storing those in an external .ini file that can be easily viewed and modified using a text editor. This gives a good overview: http://blogs.technet.com/b/heyscriptingguy/archive/2011/08/20/use-powershell-to-work-with-any-ini-...
by jerris
Wed Mar 19, 2014 10:55 am
Forum: PowerShell GUIs
Topic: Pass form text in quotes to cmdlet
Replies: 2
Views: 1530

Re: Pass form text in quotes to cmdlet

I'm not understanding what exactly you're trying to do. Are you basically prompting for an email account and then returning the permissions (like who has full mailbox access) to that email account?
by jerris
Wed Mar 19, 2014 10:36 am
Forum: PowerShell GUIs
Topic: Help with PS script side of a datagridview box...
Replies: 12
Views: 5739

Re: Help with PS script side of a datagridview box...

I would suggest using a listview instead of a datagridview. It's much more friendly to work with in my opinion. You can get the same effect as a datagridview by changing the "View" of listview to "Details" and specifying the columns you want for your listview under the "Columns" property for the lis...