home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PC World Komputer 1996 February
/
PCWK0296.iso
/
po7_win
/
object10
/
parmodc.frm
< prev
next >
Wrap
Text File
|
1994-09-28
|
9KB
|
292 lines
VERSION 2.00
Begin Form frmEmp
BorderStyle = 3 'Fixed Double
Caption = "Emp Using Parameters"
ClientHeight = 3960
ClientLeft = 2490
ClientTop = 2430
ClientWidth = 6330
Height = 4365
Left = 2430
LinkTopic = "Form1"
MaxButton = 0 'False
ScaleHeight = 3960
ScaleWidth = 6330
Top = 2085
Width = 6450
Begin TextBox txtComm
DataField = "comm"
DataSource = "EmpData"
Height = 285
Left = 2640
TabIndex = 6
Top = 2280
Width = 1215
End
Begin TextBox txtDeptno
DataField = "deptno"
DataSource = "EmpData"
Height = 285
Left = 2640
TabIndex = 7
Top = 2640
Width = 1215
End
Begin TextBox txtSal
DataField = "sal"
DataSource = "EmpData"
Height = 285
Left = 2640
TabIndex = 5
Top = 1920
Width = 1215
End
Begin TextBox txtHireDate
DataField = "hiredate"
DataSource = "EmpData"
Height = 285
Left = 2640
TabIndex = 4
Top = 1560
Width = 1215
End
Begin TextBox txtMgr
DataField = "mgr"
DataSource = "EmpData"
Height = 285
Left = 2640
TabIndex = 3
Top = 1200
Width = 1215
End
Begin TextBox txtJob
DataField = "job"
DataSource = "EmpData"
Height = 285
Left = 2640
TabIndex = 2
Top = 840
Width = 2895
End
Begin TextBox txtEname
DataField = "ename"
DataSource = "EmpData"
Height = 285
Left = 2640
TabIndex = 1
Top = 480
Width = 2895
End
Begin TextBox txtEmpno
DataField = "empno"
DataSource = "EmpData"
Height = 285
Left = 2640
TabIndex = 0
Top = 120
Width = 1215
End
Begin CommandButton cmdExit
Caption = "Exit"
Height = 495
Left = 4200
TabIndex = 10
Top = 3360
Width = 1215
End
Begin CommandButton cmdQuery
Caption = "Query"
Default = -1 'True
Height = 495
Left = 840
TabIndex = 9
Top = 3360
Width = 1215
End
Begin OraData EmpData
AllowMoveLast = -1 'True
AutoBinding = -1 'True
Caption = " Previous Employee -- Next Employee"
Connect = ""
DatabaseName = ""
Height = 270
HiddenName = "EmpData"
Left = 360
Options = 2162688
ReadOnly = 0 'False
RecordSource = ""
TabIndex = 8
Top = 3000
TrailingBlanks = 0 'False
Width = 5535
End
Begin Label Label8
Alignment = 1 'Right Justify
AutoSize = -1 'True
Caption = "Department Number:"
FontBold = -1 'True
FontItalic = 0 'False
FontName = "MS Sans Serif"
FontSize = 9.75
FontStrikethru = 0 'False
FontUnderline = 0 'False
Height = 255
Left = 360
TabIndex = 18
Top = 2640
Width = 2175
End
Begin Label Label7
Alignment = 1 'Right Justify
AutoSize = -1 'True
Caption = "Commission:"
FontBold = -1 'True
FontItalic = 0 'False
FontName = "MS Sans Serif"
FontSize = 9.75
FontStrikethru = 0 'False
FontUnderline = 0 'False
Height = 255
Left = 1200
TabIndex = 17
Top = 2280
Width = 1335
End
Begin Label Label6
Alignment = 1 'Right Justify
AutoSize = -1 'True
Caption = "Salary:"
FontBold = -1 'True
FontItalic = 0 'False
FontName = "MS Sans Serif"
FontSize = 9.75
FontStrikethru = 0 'False
FontUnderline = 0 'False
Height = 255
Left = 1680
TabIndex = 16
Top = 1920
Width = 855
End
Begin Label Label5
Alignment = 1 'Right Justify
AutoSize = -1 'True
Caption = "Hire Date:"
FontBold = -1 'True
FontItalic = 0 'False
FontName = "MS Sans Serif"
FontSize = 9.75
FontStrikethru = 0 'False
FontUnderline = 0 'False
Height = 255
Left = 1440
TabIndex = 15
Top = 1560
Width = 1095
End
Begin Label Label4
Alignment = 1 'Right Justify
AutoSize = -1 'True
Caption = "Manager:"
FontBold = -1 'True
FontItalic = 0 'False
FontName = "MS Sans Serif"
FontSize = 9.75
FontStrikethru = 0 'False
FontUnderline = 0 'False
Height = 240
Left = 1560
TabIndex = 14
Top = 1200
Width = 990
End
Begin Label Label3
Alignment = 1 'Right Justify
AutoSize = -1 'True
Caption = "Job:"
FontBold = -1 'True
FontItalic = 0 'False
FontName = "MS Sans Serif"
FontSize = 9.75
FontStrikethru = 0 'False
FontUnderline = 0 'False
Height = 255
Left = 2040
TabIndex = 13
Top = 840
Width = 495
End
Begin Label Label2
Alignment = 1 'Right Justify
AutoSize = -1 'True
Caption = "Employee Name:"
FontBold = -1 'True
FontItalic = 0 'False
FontName = "MS Sans Serif"
FontSize = 9.75
FontStrikethru = 0 'False
FontUnderline = 0 'False
Height = 255
Left = 720
TabIndex = 12
Top = 480
Width = 1815
End
Begin Label Label1
Alignment = 1 'Right Justify
AutoSize = -1 'True
Caption = "Employee Number:"
FontBold = -1 'True
FontItalic = 0 'False
FontName = "MS Sans Serif"
FontSize = 9.75
FontStrikethru = 0 'False
FontUnderline = 0 'False
Height = 255
Left = 480
TabIndex = 11
Top = 120
Width = 2055
End
End
Sub cmdExit_Click ()
End
End Sub
Sub cmdQuery_Click ()
Dim var As Variant
var = txtJob
EmpData.Database.Parameters("job").Value = var
EmpData.Recordset.DbRefresh
End Sub
Sub EmpData_Reposition ()
If EmpData.Recordset.EOF = True Then
MsgBox "You are already on in the last record."
End If
If EmpData.Recordset.BOF = True Then
MsgBox "You are already on in the first record."
End If
End Sub
Sub Form_Load ()
EmpData.Connect = Connect$
EmpData.DatabaseName = DatabaseName$
EmpData.Refresh
EmpData.RecordSource = EmpQuery$
EmpData.Database.Parameters.Add "job", "MANAGER", 1
txtJob = "MANAGER"
EmpData.Refresh
End Sub