Results 1 to 2 of 2

Thread: Rebootเครื่องด้วยScript

  1. #1
    imoomoo
    Guest


    strComputer = "." ' Local Computer

    Set objWMIService = GetObject("winmgmts:{impersonationLevel=impersonate,(Shutdown)}!\\" & _
    strComputer & "\root\cimv2")

    Set colOS = objWMIService.ExecQuery("Select * from Win32_OperatingSystem")

    For Each objOS in colOS
    objOS.Reboot()
    Next

  2. #2
    Junior Member
    Join Date
    Jul 2007
    Posts
    5


    vb รึเปล่าครับ? เจ้าของกระทู้ แนะนำวิธีใช้ด้วยนะครับ เพราะผู้อ่านบางคนจะไม่ทราบว่าต้องเอาไปใช้ยังไง ^ ^ เห็นคุณ imoomoo ไปโพสไว้หลายอัน แต่ไม่ได้อธิบายไว้ซักอันเลยครับ และถ้าจะให้ดีผมว่ารวมเป็น topic เดียว และมาอธิบายแต่ละ code ดีกว่าครับ ^ ^ ไม่อย่างนั้นผมว่าเป็นการปั้มกระทู้โดยใช่เหตุ ^ ^

Members who have read this thread : 0

Actions : (View-Readers)

There are no names to display.

Members who have read this thread: 0

There are no members to list at the moment.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •