Skip to content

Commit 15bbcbf

Browse files
tduguidtduguid
authored andcommitted
Removed Call statement from procedures
1 parent 7dae32d commit 15bbcbf

6 files changed

Lines changed: 42 additions & 45 deletions

File tree

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
:new: I'm currently working on the C# version.
1818

19-
This Add-In allows the user to ping a list of servers and create a file for Microsoft Remote Desktop Manager from an Excel table. This is used for quickly determining which servers are offline in a list.
19+
This Add-In allows the user to ping a list of servers and creates a file for Microsoft Remote Desktop Manager from an Excel table. This is used for quickly determining which servers are offline in a list.
2020

2121
<!---
2222
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE "MIT License Copyright © 2017 Anthony Duguid")

VB/Scripts/AssemblyInfo.vb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ Namespace Scripts
1616
currentForm.Icon = Icon.FromHandle(bmp.GetHicon)
1717

1818
Catch ex As Exception
19-
Call ErrorHandler.DisplayMessage(ex)
19+
ErrorHandler.DisplayMessage(ex)
2020
Exit Try
2121

2222
End Try
@@ -54,7 +54,7 @@ Namespace Scripts
5454
End If
5555
Next
5656
Catch ex As Exception
57-
Call ErrorHandler.DisplayMessage(ex)
57+
ErrorHandler.DisplayMessage(ex)
5858
End Try
5959
End If
6060
End Sub

VB/Scripts/Ribbon.vb

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ Namespace Scripts
3737
ribbonref = Me
3838

3939
Catch ex As Exception
40-
Call ErrorHandler.DisplayMessage(ex)
40+
ErrorHandler.DisplayMessage(ex)
4141

4242
End Try
4343

@@ -78,7 +78,7 @@ Namespace Scripts
7878
Return tbl.ListColumns(index).Name
7979

8080
Catch ex As Exception
81-
Call ErrorHandler.DisplayMessage(ex)
81+
ErrorHandler.DisplayMessage(ex)
8282
Return "ERROR"
8383

8484
Finally
@@ -101,7 +101,7 @@ Namespace Scripts
101101
End If
102102

103103
Catch ex As Exception
104-
Call ErrorHandler.DisplayMessage(ex)
104+
ErrorHandler.DisplayMessage(ex)
105105
Return 0
106106

107107
Finally
@@ -145,7 +145,7 @@ Namespace Scripts
145145
Return String.Empty
146146

147147
Catch ex As Exception
148-
Call ErrorHandler.DisplayMessage(ex)
148+
ErrorHandler.DisplayMessage(ex)
149149
Return String.Empty
150150

151151
End Try
@@ -178,33 +178,33 @@ Namespace Scripts
178178
Try
179179
Select Case control.Id
180180
Case "btnPing"
181-
Call Ribbon_Button.AddPingColumn()
181+
Ribbon_Button.AddPingColumn()
182182

183183
Case "btnCreateRdgFile"
184-
Call Ribbon_Button.CreateRdgFile()
184+
Ribbon_Button.CreateRdgFile()
185185

186186
Case "btnDownloadNewVersion"
187-
Call Ribbon_Button.DownloadNewVersion()
187+
Ribbon_Button.DownloadNewVersion()
188188

189189
Case "btnOpenNewIssue"
190-
Call Ribbon_Button.OpenNewIssue()
190+
Ribbon_Button.OpenNewIssue()
191191

192192
Case "btnOpenReadMe"
193-
Call Ribbon_Button.OpenReadMe()
193+
Ribbon_Button.OpenReadMe()
194194

195195
Case "btnSettings"
196-
Call Ribbon_Button.OpenSettings()
196+
Ribbon_Button.OpenSettings()
197197

198198
Case "btnRefreshCombobox"
199-
Call Ribbon_Button.RefreshCombobox()
199+
Ribbon_Button.RefreshCombobox()
200200

201201
Case "btnRefreshServerList"
202-
Call Ribbon_Button.RefreshServerList()
202+
Ribbon_Button.RefreshServerList()
203203

204204
End Select
205205

206206
Catch ex As Exception
207-
Call ErrorHandler.DisplayMessage(ex)
207+
ErrorHandler.DisplayMessage(ex)
208208

209209
End Try
210210

@@ -228,7 +228,7 @@ Namespace Scripts
228228

229229

230230
Catch ex As Exception
231-
Call ErrorHandler.DisplayMessage(ex)
231+
ErrorHandler.DisplayMessage(ex)
232232

233233
End Try
234234

@@ -239,7 +239,7 @@ Namespace Scripts
239239
GetItem = col(key)
240240

241241
Catch ex As Exception
242-
Call ErrorHandler.DisplayMessage(ex)
242+
ErrorHandler.DisplayMessage(ex)
243243
GetItem = Nothing
244244

245245
End Try
@@ -259,7 +259,7 @@ Namespace Scripts
259259
'ws.UsedRange 'resets the last cell reference
260260

261261
Catch ex As Exception
262-
Call ErrorHandler.DisplayMessage(ex)
262+
ErrorHandler.DisplayMessage(ex)
263263

264264
Finally
265265
ws = Nothing
@@ -291,7 +291,7 @@ Namespace Scripts
291291
r.Select()
292292

293293
Catch ex As Exception
294-
Call ErrorHandler.DisplayMessage(ex)
294+
ErrorHandler.DisplayMessage(ex)
295295

296296
Finally
297297
tbl = Nothing
@@ -338,7 +338,7 @@ Namespace Scripts
338338
Return result & " : " & Format(Now(), dateFormat)
339339

340340
Catch ex As Exception
341-
Call ErrorHandler.DisplayMessage(ex)
341+
ErrorHandler.DisplayMessage(ex)
342342
Return "Error: " & ex.ToString()
343343

344344
Finally
@@ -361,7 +361,7 @@ Namespace Scripts
361361
Exit Try
362362

363363
Catch ex As Exception
364-
Call ErrorHandler.DisplayMessage(ex)
364+
ErrorHandler.DisplayMessage(ex)
365365
Exit Try
366366

367367
Finally
@@ -397,7 +397,7 @@ Namespace Scripts
397397
Next
398398

399399
Catch ex As Exception
400-
Call ErrorHandler.DisplayMessage(ex)
400+
ErrorHandler.DisplayMessage(ex)
401401

402402
Finally
403403
tbl = Nothing
@@ -424,7 +424,7 @@ Namespace Scripts
424424
Return Nothing
425425

426426
Catch ex As Exception
427-
Call ErrorHandler.DisplayMessage(ex)
427+
ErrorHandler.DisplayMessage(ex)
428428
Return Nothing
429429

430430
End Try

VB/Scripts/Ribbon_Button.vb

Lines changed: 10 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,8 @@ Namespace Scripts
1616
Dim lstCol As Excel.ListColumn
1717
Dim tbl As Excel.ListObject
1818
Dim col As Excel.ListColumn
19-
'Dim qt As String
2019
Dim a As Object
2120
Dim c As Object
22-
'Dim cc As Object
2321
Dim cnt As Integer
2422
Dim i As Integer
2523
Dim colServer As String
@@ -59,7 +57,7 @@ Namespace Scripts
5957
Next
6058

6159
Catch ex As Exception
62-
Call ErrorHandler.DisplayMessage(ex)
60+
ErrorHandler.DisplayMessage(ex)
6361

6462
Finally
6563
lstCol = Nothing
@@ -138,7 +136,7 @@ Namespace Scripts
138136
System.IO.File.WriteAllText(FileName, script)
139137

140138
Catch ex As Exception
141-
Call ErrorHandler.DisplayMessage(ex)
139+
ErrorHandler.DisplayMessage(ex)
142140

143141
Finally
144142
lstCol = Nothing
@@ -161,7 +159,7 @@ Namespace Scripts
161159
Ribbon.InvalidateRibbon()
162160

163161
Catch ex As Exception
164-
Call ErrorHandler.DisplayMessage(ex)
162+
ErrorHandler.DisplayMessage(ex)
165163

166164
Finally
167165
tbl = Nothing
@@ -189,36 +187,35 @@ Namespace Scripts
189187
End If
190188

191189
Catch ex As Exception
192-
Call ErrorHandler.DisplayMessage(ex)
190+
ErrorHandler.DisplayMessage(ex)
193191

194192
End Try
195193

196194
End Sub
197195

198196
Public Shared Sub OpenNewIssue()
199197
Try
200-
Call Ribbon.OpenFile(My.Settings.App_PathNewIssue)
198+
Ribbon.OpenFile(My.Settings.App_PathNewIssue)
201199

202200
Catch ex As Exception
203-
Call ErrorHandler.DisplayMessage(ex)
201+
ErrorHandler.DisplayMessage(ex)
204202

205203
End Try
206204

207205
End Sub
208206

209207
Public Shared Sub OpenReadMe()
210208
Try
211-
Call Ribbon.OpenFile(My.Settings.App_PathReadMe)
209+
Ribbon.OpenFile(My.Settings.App_PathReadMe)
212210

213211
Catch ex As Exception
214-
Call ErrorHandler.DisplayMessage(ex)
212+
ErrorHandler.DisplayMessage(ex)
215213

216214
End Try
217215

218216
End Sub
219217

220218
Public Shared Sub RefreshServerList()
221-
222219
Dim cn As ADODB.Connection
223220
Dim rs As ADODB.Recordset
224221
Dim cmd As ADODB.Command
@@ -265,7 +262,7 @@ Namespace Scripts
265262
End If
266263

267264
Globals.ThisAddIn.Application.Sheets(My.Settings.Rdg_SheetName).Activate
268-
Call Ribbon.ClearSheetContents()
265+
Ribbon.ClearSheetContents()
269266
For iCols = 0 To rs.Fields.Count - 1
270267
ws.Cells(1, iCols + 1).Value = rs.Fields(iCols).Name
271268
Next
@@ -287,7 +284,7 @@ Namespace Scripts
287284
Ribbon.ActivateTab()
288285

289286
Catch ex As Exception
290-
Call ErrorHandler.DisplayMessage(ex)
287+
ErrorHandler.DisplayMessage(ex)
291288

292289
Finally
293290
wb = Nothing

VB/ServerActions.vbproj

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
<IsWebBootstrapper>True</IsWebBootstrapper>
3434
<BootstrapperEnabled>true</BootstrapperEnabled>
3535
<PublishUrl>publish\</PublishUrl>
36-
<InstallUrl>https://raw.githubusercontent.com/aduguid/ServerActions/master/VB/publish/</InstallUrl>
36+
<InstallUrl>https://github.com/Office-projects/Server-Actions/master/VB/publish/</InstallUrl>
3737
<TargetCulture>en</TargetCulture>
3838
<ApplicationVersion>2.0.0.0</ApplicationVersion>
3939
<AutoIncrementApplicationRevision>false</AutoIncrementApplicationRevision>
@@ -42,9 +42,9 @@
4242
<UpdateIntervalUnits>days</UpdateIntervalUnits>
4343
<ProductName>Excel Addin Server Actions</ProductName>
4444
<PublisherName>Anthony Duguid</PublisherName>
45-
<SupportUrl>https://github.com/aduguid/ServerActions/blob/master/README.md</SupportUrl>
45+
<SupportUrl>https://github.com/Office-projects/Server-Actions/blob/master/README.md</SupportUrl>
4646
<FriendlyName>Excel Addin Server Actions</FriendlyName>
47-
<OfficeApplicationDescription>This Add-In allows the user to use an Excel table to ping a list of servers and create a file for Microsoft Remote Desktop Manager.</OfficeApplicationDescription>
47+
<OfficeApplicationDescription>This Add-In pings a list of servers from an Excel table and creates a file for Microsoft Remote Desktop Manager.</OfficeApplicationDescription>
4848
<LoadBehavior>3</LoadBehavior>
4949
</PropertyGroup>
5050
<ItemGroup>
@@ -266,11 +266,11 @@
266266
</ItemGroup>
267267
<ItemGroup>
268268
<COMReference Include="ADODB">
269-
<Guid>{2A75196C-D9EB-4129-B803-931327F72D5C}</Guid>
270-
<VersionMajor>2</VersionMajor>
271-
<VersionMinor>8</VersionMinor>
269+
<Guid>{B691E011-1797-432E-907A-4D8C69339129}</Guid>
270+
<VersionMajor>6</VersionMajor>
271+
<VersionMinor>1</VersionMinor>
272272
<Lcid>0</Lcid>
273-
<WrapperTool>primary</WrapperTool>
273+
<WrapperTool>tlbimp</WrapperTool>
274274
<Isolated>False</Isolated>
275275
<EmbedInteropTypes>True</EmbedInteropTypes>
276276
</COMReference>

VB/ServerActions.vbproj.user

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
33
<PropertyGroup>
44
<PublishUrlHistory>publish\</PublishUrlHistory>
5-
<InstallUrlHistory>https://raw.githubusercontent.com/aduguid/ServerActions/master/VB/publish/</InstallUrlHistory>
5+
<InstallUrlHistory>https://github.com/Office-projects/Server-Actions/master/VB/publish/|https://raw.githubusercontent.com/aduguid/ServerActions/master/VB/publish/</InstallUrlHistory>
66
<SupportUrlHistory>https://github.com/aduguid/ServerActions/blob/master/README.md</SupportUrlHistory>
77
</PropertyGroup>
88
</Project>

0 commit comments

Comments
 (0)