• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 208
  • Last Modified:

Shell Command Variables

I have a TextBox, 2 radiobuttons and a "Execute" button.
The command button has

If RadioButton1.Checked Then Shell("shutdown -s -f -t 90")
 If RadioButton2.Checked Then Shell("shutdown -r -f -t 90")


What i want to have is that the TextBox1 control the -t (time) of the shutdown/restart

What would the code be
0
asherap
Asked:
asherap
1 Solution
 
RonaldBiemansCommented:
you mean like

Shell("shutdown -r -f -t " & textbox1.text)
0
 
asherapAuthor Commented:
saved the day mate thx
0

Featured Post

[Webinar] Kill tickets & tabs using PowerShell

Are you tired of cycling through the same browser tabs everyday to close the same repetitive tickets? In this webinar JumpCloud will show how you can leverage RESTful APIs to build your own PowerShell modules to kill tickets & tabs using the PowerShell command Invoke-RestMethod.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now