www.pudn.com > the PC Host examples .zip > I2CStartUp.frm


VERSION 5.00 
Begin VB.Form StartupWindow  
   BackColor       =   &H00FF8080& 
   Caption         =   "USB Design By Example: Reader Board" 
   ClientHeight    =   5595 
   ClientLeft      =   3000 
   ClientTop       =   2145 
   ClientWidth     =   9840 
   FillStyle       =   0  'Solid 
   ForeColor       =   &H8000000E& 
   LinkTopic       =   "Form1" 
   NegotiateMenus  =   0   'False 
   OLEDropMode     =   1  'Manual 
   ScaleHeight     =   5874.016 
   ScaleMode       =   0  'User 
   ScaleWidth      =   9840 
   ShowInTaskbar   =   0   'False 
   Begin VB.CommandButton OKbutton  
      Caption         =   "OK" 
      BeginProperty Font  
         Name            =   "MS Sans Serif" 
         Size            =   12 
         Charset         =   0 
         Weight          =   400 
         Underline       =   0   'False 
         Italic          =   0   'False 
         Strikethrough   =   0   'False 
      EndProperty 
      Height          =   495 
      Left            =   4200 
      Style           =   1  'Graphical 
      TabIndex        =   0 
      Top             =   2520 
      Width           =   1455 
   End 
   Begin VB.TextBox StatusBox  
      Alignment       =   2  'Center 
      BeginProperty Font  
         Name            =   "MS Sans Serif" 
         Size            =   12 
         Charset         =   0 
         Weight          =   400 
         Underline       =   0   'False 
         Italic          =   0   'False 
         Strikethrough   =   0   'False 
      EndProperty 
      Height          =   1935 
      Left            =   2880 
      MultiLine       =   -1  'True 
      TabIndex        =   1 
      Text            =   "I2CStartUp.frx":0000 
      Top             =   1320 
      Width           =   4095 
   End 
End 
Attribute VB_Name = "StartupWindow" 
Attribute VB_GlobalNameSpace = False 
Attribute VB_Creatable = False 
Attribute VB_PredeclaredId = True 
Attribute VB_Exposed = False 
Private Sub Form_Load() 
'   Search through attached HID devices for the "I2C Bridge" hardware. 
' 
If OpenUSBdevice("I2C Bridge") Then 
    DisplayWindow.Show (1) ' Pass control to the DisplayWindow form 
    StatusBox.Text = vbCrLf & "Hope you had fun!" ' Change the text for the return from DisplayWindow 
    End If 
' StartupWindow will be displayed now 
End Sub 
Private Sub OKButton_Click() 
Stop ' Exit the program 
End Sub