home *** CD-ROM | disk | FTP | other *** search
- VERSION 4.00
- Begin VB.Form frmMain
- Caption = "Corporate Widget Tracker"
- ClientHeight = 930
- ClientLeft = 1095
- ClientTop = 1530
- ClientWidth = 3840
- BeginProperty Font
- name = "MS Sans Serif"
- charset = 1
- weight = 700
- size = 8.25
- underline = 0 'False
- italic = 0 'False
- strikethrough = 0 'False
- EndProperty
- Height = 1335
- Left = 1035
- LinkTopic = "Form1"
- ScaleHeight = 930
- ScaleWidth = 3840
- Top = 1185
- Width = 3960
- Begin VB.CommandButton cmdLogin
- Caption = "Display &Login Dialog"
- BeginProperty Font
- name = "MS Sans Serif"
- charset = 1
- weight = 400
- size = 8.25
- underline = 0 'False
- italic = 0 'False
- strikethrough = 0 'False
- EndProperty
- Height = 345
- Left = 225
- TabIndex = 0
- Top = 375
- Width = 2115
- End
- Begin VB.CommandButton cmdClose
- Caption = "&Close"
- BeginProperty Font
- name = "MS Sans Serif"
- charset = 1
- weight = 400
- size = 8.25
- underline = 0 'False
- italic = 0 'False
- strikethrough = 0 'False
- EndProperty
- Height = 345
- Left = 2475
- TabIndex = 1
- Top = 375
- Width = 1140
- End
- Attribute VB_Name = "frmMain"
- Attribute VB_Creatable = False
- Attribute VB_Exposed = False
- Option Explicit
- Private Sub cmdClose_Click()
- Unload Me
- End Sub
- Private Sub cmdLogin_Click()
- Dim dlg As New StdLoginDialogs.SQLLoginDialog
- Dim strResult As String
- ' Because the variable 'dlg' was declared with
- ' the New keyword, the SQLLoginDialog object
- ' will be created when the following line of
- ' code is executed.
- strResult = dlg.Show(Me.Caption, "JoeUser", "CorpWidgetBase")
- MsgBox "Your login string is: " & strResult
- ' Destroy the object.
- Set dlg = Nothing
- End Sub
- Sub Form_Load()
- Dim dlg As StdLoginDialogs.SQLLoginDialog
- Dim strResult As String
- ' In contrast to the 'Dim dlg As New ...' syntax
- ' used in the command button click event, here
- ' the new SQLLoginDialog object is created by
- ' using the New operator with the Set statement.
- Set dlg = New StdLoginDialogs.SQLLoginDialog
- ' In this case, the object already exists when
- ' the following line of code is executed.
- strResult = dlg.Show(Me.Caption, "JoeUser", "CorpWidgetBase")
- MsgBox "Your login string is: " & strResult
- ' Destroy the object.
- Set dlg = Nothing
- End Sub
-