-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathtemplate.ps1
More file actions
60 lines (48 loc) · 1.18 KB
/
template.ps1
File metadata and controls
60 lines (48 loc) · 1.18 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
<#
.SYNOPSIS
[Incomplete script!] This is a template for new scripts
.DESCRIPTION
[Incomplete script!] This is a template for new scripts
.EXAMPLE
C:\PS>.\template.ps1
This will bring up the new script
.INPUTS
There are no inputs that can be directed to this script
.OUTPUTS
All outputs are sent to the console and logged in the log folder
.NOTES
Author: Robert Weber
Date: Nov 19, 2015
#>
[CmdletBinding()]
param ( )
clear
$error.clear()
. .\lib\PSClass.ps1
(gci .\lib) | % { . "$($_.FullName)" }
$templateClass = new-PSClass template{
note -static PsScriptName "template"
note -static Description ( ($(((get-help .\template.ps1).Description)) | select Text).Text)
note -private mainProgressBar
note -private gui
method publicFunction{
param($par)
write-host "publicFunction called"
}
method -private privateFunction{
param($par)
write-host "privateFunction called"
}
constructor{
param()
$private.gui = $null
$private.gui = $guiClass.New("template.xml")
$private.gui.generateForm() | out-null;
$private.gui.Form.ShowDialog() | Out-Null
}
method Execute{
param($par)
$uiClass.errorLog()
}
}
$templateClass.New().Execute() | out-null