home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic 4 Unleashed / Visual_Basic_4_Unleashed_SAMS_Publishing_1995.iso / crystal / extras / vbxdemo / server.frm (.txt) < prev    next >
Encoding:
Visual Basic Form  |  1994-12-15  |  5.1 KB  |  182 lines

  1. VERSION 2.00
  2. Begin Form SetLogon 
  3.    BackColor       =   &H00C0C0C0&
  4.    Caption         =   "SQL Server"
  5.    ClientHeight    =   3900
  6.    ClientLeft      =   1875
  7.    ClientTop       =   2460
  8.    ClientWidth     =   5205
  9.    Height          =   4590
  10.    Left            =   1815
  11.    LinkTopic       =   "Form1"
  12.    ScaleHeight     =   3900
  13.    ScaleWidth      =   5205
  14.    Top             =   1830
  15.    Width           =   5325
  16.    Begin CommandButton Command5 
  17.       Caption         =   "Help"
  18.       Height          =   330
  19.       Left            =   3390
  20.       TabIndex        =   7
  21.       Top             =   1890
  22.       Width           =   1575
  23.    End
  24.    Begin SSFrame Frame3D1 
  25.       Caption         =   "Logon Information"
  26.       Font3D          =   0  'None
  27.       Height          =   3210
  28.       Left            =   330
  29.       TabIndex        =   9
  30.       Top             =   360
  31.       Width           =   2865
  32.       Begin TextBox Text4 
  33.          Height          =   375
  34.          Left            =   180
  35.          PasswordChar    =   "*"
  36.          TabIndex        =   3
  37.          Top             =   2580
  38.          Width           =   2175
  39.       End
  40.       Begin TextBox Text3 
  41.          Height          =   375
  42.          Left            =   180
  43.          TabIndex        =   2
  44.          Top             =   1890
  45.          Width           =   2175
  46.       End
  47.       Begin TextBox Text2 
  48.          Height          =   375
  49.          Left            =   150
  50.          TabIndex        =   1
  51.          Top             =   1215
  52.          Width           =   2175
  53.       End
  54.       Begin TextBox Text1 
  55.          Height          =   375
  56.          Left            =   150
  57.          TabIndex        =   0
  58.          Top             =   495
  59.          Width           =   2175
  60.       End
  61.       Begin Label Label8 
  62.          BackColor       =   &H00C0C0C0&
  63.          Caption         =   "Password(PWD)"
  64.          ForeColor       =   &H00000000&
  65.          Height          =   255
  66.          Left            =   180
  67.          MousePointer    =   11  'Hourglass
  68.          TabIndex        =   8
  69.          Top             =   2340
  70.          Width           =   1455
  71.       End
  72.       Begin Label Label7 
  73.          BackColor       =   &H00C0C0C0&
  74.          Caption         =   "User ID(UID)"
  75.          Height          =   255
  76.          Left            =   180
  77.          TabIndex        =   12
  78.          Top             =   1665
  79.          Width           =   1695
  80.       End
  81.       Begin Label Label6 
  82.          BackColor       =   &H00C0C0C0&
  83.          Caption         =   "Database Name(DSQ)"
  84.          Height          =   255
  85.          Left            =   180
  86.          TabIndex        =   11
  87.          Top             =   990
  88.          Width           =   1695
  89.       End
  90.       Begin Label Label5 
  91.          BackColor       =   &H00C0C0C0&
  92.          Caption         =   "Server Name(DSN)"
  93.          Height          =   255
  94.          Left            =   180
  95.          TabIndex        =   10
  96.          Top             =   270
  97.          Width           =   1695
  98.       End
  99.    End
  100.    Begin CommandButton Command4 
  101.       Caption         =   "Clear Settings"
  102.       Height          =   330
  103.       Left            =   3360
  104.       TabIndex        =   5
  105.       Top             =   750
  106.       Width           =   1575
  107.    End
  108.    Begin CommandButton Command2 
  109.       Caption         =   "Connect"
  110.       Height          =   330
  111.       Left            =   3360
  112.       TabIndex        =   4
  113.       Top             =   360
  114.       Width           =   1575
  115.    End
  116.    Begin CommandButton Command1 
  117.       Caption         =   "Done"
  118.       Height          =   330
  119.       Left            =   3390
  120.       TabIndex        =   6
  121.       Top             =   1500
  122.       Width           =   1575
  123.    End
  124.    Begin Menu MenuFileSQLLogon 
  125.       Caption         =   "&File"
  126.       Begin Menu MenuFileExit 
  127.          Caption         =   "&Exit"
  128.       End
  129.    End
  130. Dim DLLName As String
  131. Sub Command1_Click ()
  132.  Unload Me
  133. End Sub
  134. Sub Command2_Click ()
  135. 'Set Logon parameters for SQL type Datasource
  136.     ConnectString$ = "DSN=" & Text1.Text & ";UID=" & Text3.Text & ";PWD=" & Text4.Text & ";DSQ=" & Text2.Text
  137.     Main.Report1.Connect = ConnectString$
  138.     Main!StatusBar.Caption = ConnectString$
  139. End Sub
  140. Sub Command4_Click ()
  141.   Text1.Text = " "
  142.   Text2.Text = " "
  143.   Text3.Text = " "
  144. End Sub
  145. Sub Command5_Click ()
  146.  RCode = Shell("Winhelp c:\crw\crw.hlp", 3)
  147.  If RCode = False Then
  148.    MsgBox ("CRWDEMO cannot find the Crystal Help file in C:\CRW directory")
  149.    Exit Sub
  150.  End If
  151. End Sub
  152. Sub Command6_Click ()
  153. End Sub
  154. Sub Command7_Click ()
  155. End Sub
  156. Sub Command8_Click ()
  157.    Dim nTables As Integer
  158.    If (tableN > 0) Then
  159.       tableN = tableN - 1
  160.    End If
  161. End Sub
  162. Sub Form_Load ()
  163.    Main!StatusBar.Caption = "Ready"
  164.    tableN = 0
  165. End Sub
  166. Sub MenuConnectivityDLL_Click ()
  167.  MsgBox DLLName
  168. End Sub
  169. Sub MenuConnectivityDLLtype_Click ()
  170.   If DLLName = "PDSODBC.DLL" Or DLLName = "pdsodbc.dll" Then
  171.    MsgBox "Connection via ODBC."
  172.   Else
  173.    MsgBox "Connection via Q+E Lib."
  174.   End If
  175. End Sub
  176. Sub MenuExitSQLLogon_Click ()
  177.    Unload Me
  178. End Sub
  179. Sub MenuFileExit_Click ()
  180.  Unload Me
  181. End Sub
  182.