VirtualBox

source: vbox/trunk/src/VBox/Frontends/VBoxShell/vboxinfo.vb@ 27963

Last change on this file since 27963 was 21569, checked in by vboxsync, 15 years ago

property set for VB and VBS

  • Property svn:eol-style set to CRLF
  • Property svn:keywords set to Author Date Id Revision
File size: 1.5 KB
Line 
1'
2' Copyright (C) 2009 Sun Microsystems, Inc.
3'
4' This file is part of VirtualBox Open Source Edition (OSE), as
5' available from http://www.virtualbox.org. This file is free software;
6' you can redistribute it and/or modify it under the terms of the GNU
7' General Public License (GPL) as published by the Free Software
8' Foundation, in version 2 as it comes in the "COPYING" file of the
9' VirtualBox OSE distribution. VirtualBox OSE is distributed in the
10' hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
11'
12' Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa
13' Clara, CA 95054 USA or visit http://www.sun.com if you need
14' additional information or have any questions.
15'
16Imports System
17Imports System.Drawing
18Imports System.Windows.Forms
19
20Module Module1
21
22 Sub Main()
23 Dim vb As VirtualBox.IVirtualBox
24 Dim listBox As New ListBox()
25 Dim form As New Form
26
27 vb = CreateObject("VirtualBox.VirtualBox")
28
29 form.Text = "VirtualBox version " & vb.Version
30 form.Size = New System.Drawing.Size(400, 320)
31 form.Location = New System.Drawing.Point(10, 10)
32
33 listBox.Size = New System.Drawing.Size(350, 200)
34 listBox.Location = New System.Drawing.Point(10, 10)
35
36 For Each m In vb.Machines
37 listBox.Items.Add(m.Name & " [" & m.Id & "]")
38 Next
39
40 form.Controls.Add(listBox)
41
42 'form.ShowDialog()
43 form.Show()
44 MsgBox("OK")
45 End Sub
46
47End Module
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette