Support Forums

Search found 10354 matches

by jvierra
Fri Feb 24, 2017 8:38 am
Forum: Windows PowerShell
Topic: OWA Email Signature
Replies: 3
Views: 112

Re: OWA Email Signature

You are welcome.

Spend a bit of time getting more familiar with how PS handles these things and your scripting will become much easier.
by jvierra
Fri Feb 24, 2017 7:13 am
Forum: Windows PowerShell
Topic: OWA Email Signature
Replies: 3
Views: 112

Re: OWA Email Signature

This is a better way using PowerShell. $template = '{0}<br />{1}<br />Sent by ORGANISATIONS NAME Web Outlook System' $ou = 'OU=Staff,OU=Users,OU=BLA - St Catherines,DC=BLA,DC=ORG,DC=UK' Get-ADUser -SearchBase $ou -Filter * -Properties DisplayName, Description | ForEach-Object{ $signa...
by jvierra
Thu Feb 23, 2017 4:10 pm
Forum: PowerShell GUIs
Topic: write-verbose in deployed form?
Replies: 5
Views: 134

Re: write-verbose in deployed form?

I suspected that this was the case so I tested it; THe only thing needed is on line in startup.pss Just do this: #Define a Param block to use custom parameters in the project [CmdletBinding()] Param ($CustomParameter) Once that is added you can call the file with "-Verbose"...
by jvierra
Thu Feb 23, 2017 2:17 pm
Forum: PowerShell GUIs
Topic: write-verbose in deployed form?
Replies: 5
Views: 134

Re: write-verbose in deployed form?

Great. Yes. Startup.pss is the root of all roots for a project script. You should probably save and replace $VerbosePreference in the startupm or ... this ... #Define a Param block to use custom parameters in the project #[CmdletBinding()] #Param ($CustomParameter) function Main { Pa...
by jvierra
Thu Feb 23, 2017 9:43 am
Forum: PowerShell GUIs
Topic: write-verbose in deployed form?
Replies: 5
Views: 134

Re: write-verbose in deployed form?

This would probably also work:

In Startup.pss at the top:

Code: Select all

#Define a Param block to use custom parameters in the project
[CmdletBinding()]
Param ($CustomParameter)
$global:VerbosePreference = 'Continue'
function Main {
<#
by jvierra
Thu Feb 23, 2017 9:24 am
Forum: PowerShell GUIs
Topic: write-verbose in deployed form?
Replies: 5
Views: 134

Re: write-verbose in deployed form?

Well - you really can't because a project is wrapped in a "Main" (in startup.pss) and it has not binding. You can set the global verbose preferences in your profile to see if it will propagate. Verbose acts in the local scope and all child scopes. Global scope sets the default for everythi...
by jvierra
Thu Feb 23, 2017 4:54 am
Forum: PowerShell GUIs
Topic: Which control to use
Replies: 7
Views: 153

Re: Which control to use

It you need two columns use a ListView.

Samples are here: http://info.sapien.com/index.php/guis/gui-controls

Also right click on control in tool box for documentation and sample for that control.
by jvierra
Thu Feb 23, 2017 4:10 am
Forum: PowerShell GUIs
Topic: Which control to use
Replies: 7
Views: 153

Re: Which control to use

Listbox? A listbox is a vertical list.
by jvierra
Thu Feb 23, 2017 2:52 am
Forum: PowerShell GUIs
Topic: Async Progress Bar and compiled Forms Script
Replies: 3
Views: 63

Re: Async Progress Bar and compiled Forms Script

The issue is that the variables in the function do not exist the second time you call the function. Add "Throw $_" to the catch block and you will see what I mean. Make your else statement look like this and you will be able to see and fix the problem: } else { try { $sharedData.Form.close...
by jvierra
Wed Feb 22, 2017 3:25 pm
Forum: VBScript
Topic: Compiling in Primalscript 2016
Replies: 1
Views: 51

Re: Compiling in Primalscript 2016

No way to know without the script.
You say i fails. What error messages do you get?

Go to advanced search