home *** CD-ROM | disk | FTP | other *** search
/ Mastering Visual Basic 6 / mastvb6.iso / ch_code / ch18 / denv1 / dataenv.dsr < prev    next >
Encoding:
Visual Basic Active Designer file  |  1998-07-14  |  4.7 KB  |  142 lines

  1. VERSION 5.00
  2. Begin {C0E45035-5775-11D0-B388-00A0C9055D8E} DataEnvironment1 
  3.    ClientHeight    =   5055
  4.    ClientLeft      =   1080
  5.    ClientTop       =   1500
  6.    ClientWidth     =   6300
  7.    _ExtentX        =   11113
  8.    _ExtentY        =   8911
  9.    FolderFlags     =   7
  10.    TypeLibGuid     =   "{A5DC9AF5-9235-11D1-B067-00DD01144174}"
  11.    TypeInfoGuid    =   "{A5DC9AF6-9235-11D1-B067-00DD01144174}"
  12.    TypeInfoCookie  =   0
  13.    Version         =   4
  14.    NumConnections  =   1
  15.    BeginProperty Connection1 
  16.       ConnectionName  =   "Connection1"
  17.       ConnDispId      =   1006
  18.       SourceOfData    =   3
  19.       ConnectionSource=   "Provider=MSDASQL.1;Persist Security Info=False;Data Source=NWINDDB"
  20.       QuoteChar       =   96
  21.       SeparatorChar   =   46
  22.    EndProperty
  23.    NumRecordsets   =   1
  24.    BeginProperty Recordset1 
  25.       CommandName     =   "Command1"
  26.       CommDispId      =   1007
  27.       RsDispId        =   1010
  28.       CommandText     =   "Customers"
  29.       ActiveConnectionName=   "Connection1"
  30.       CommandType     =   2
  31.       dbObjectType    =   1
  32.       Locktype        =   2
  33.       CommandCursorLocation=   2
  34.       Expanded        =   -1  'True
  35.       IsRSReturning   =   -1  'True
  36.       NumFields       =   11
  37.       BeginProperty Field1 
  38.          Precision       =   0
  39.          Size            =   5
  40.          Scale           =   0
  41.          Type            =   200
  42.          Name            =   "CustomerID"
  43.          Caption         =   "CustomerID"
  44.       EndProperty
  45.       BeginProperty Field2 
  46.          Precision       =   0
  47.          Size            =   40
  48.          Scale           =   0
  49.          Type            =   200
  50.          Name            =   "CompanyName"
  51.          Caption         =   "CompanyName"
  52.       EndProperty
  53.       BeginProperty Field3 
  54.          Precision       =   0
  55.          Size            =   30
  56.          Scale           =   0
  57.          Type            =   200
  58.          Name            =   "ContactName"
  59.          Caption         =   "ContactName"
  60.       EndProperty
  61.       BeginProperty Field4 
  62.          Precision       =   0
  63.          Size            =   30
  64.          Scale           =   0
  65.          Type            =   200
  66.          Name            =   "ContactTitle"
  67.          Caption         =   "ContactTitle"
  68.       EndProperty
  69.       BeginProperty Field5 
  70.          Precision       =   0
  71.          Size            =   60
  72.          Scale           =   0
  73.          Type            =   200
  74.          Name            =   "Address"
  75.          Caption         =   "Address"
  76.       EndProperty
  77.       BeginProperty Field6 
  78.          Precision       =   0
  79.          Size            =   15
  80.          Scale           =   0
  81.          Type            =   200
  82.          Name            =   "City"
  83.          Caption         =   "City"
  84.       EndProperty
  85.       BeginProperty Field7 
  86.          Precision       =   0
  87.          Size            =   15
  88.          Scale           =   0
  89.          Type            =   200
  90.          Name            =   "Region"
  91.          Caption         =   "Region"
  92.       EndProperty
  93.       BeginProperty Field8 
  94.          Precision       =   0
  95.          Size            =   10
  96.          Scale           =   0
  97.          Type            =   200
  98.          Name            =   "PostalCode"
  99.          Caption         =   "PostalCode"
  100.       EndProperty
  101.       BeginProperty Field9 
  102.          Precision       =   0
  103.          Size            =   15
  104.          Scale           =   0
  105.          Type            =   200
  106.          Name            =   "Country"
  107.          Caption         =   "Country"
  108.       EndProperty
  109.       BeginProperty Field10 
  110.          Precision       =   0
  111.          Size            =   24
  112.          Scale           =   0
  113.          Type            =   200
  114.          Name            =   "Phone"
  115.          Caption         =   "Phone"
  116.       EndProperty
  117.       BeginProperty Field11 
  118.          Precision       =   0
  119.          Size            =   24
  120.          Scale           =   0
  121.          Type            =   200
  122.          Name            =   "Fax"
  123.          Caption         =   "Fax"
  124.       EndProperty
  125.       NumGroups       =   0
  126.       ParamCount      =   0
  127.       RelationCount   =   0
  128.       AggregateCount  =   0
  129.    EndProperty
  130. End
  131. Attribute VB_Name = "DataEnvironment1"
  132. Attribute VB_GlobalNameSpace = False
  133. Attribute VB_Creatable = False
  134. Attribute VB_PredeclaredId = True
  135. Attribute VB_Exposed = False
  136. Private Sub rsCommand1_WillChangeField(ByVal cFields As Long, ByVal Fields As Variant, adStatus As ADODB.EventStatusEnum, ByVal pRecordset As ADODB.Recordset)
  137.     reply = MsgBox("This record's fields have changed. Proceed?", vbYesNo)
  138.     If reply = vbNo Then
  139.         DataEnvironment1.rsCommand1.CancelUpdate
  140.     End If
  141. End Sub
  142.