-

   rss_sql_ru_access_programming

 - e-mail

 

 -

 LiveInternet.ru:
: 16.03.2006
:
:
: 4

:


, 03 2015 . 10:31 +
.
, , Access .

. After_update . access , (, msgbox, ). ?

, ...

http://www.sql.ru/forum/168/voros-k-znatokam-vozmozhno-li-zapustit-asinhronno

Dim WithEvents rstComboBox As ADODB.Recordset
Dim boolFlag as Boolean

'
Private Sub Form_Load()
   set rstComboBox = new ADODB.Recordset
   rstComboBox.CursorLocation = adUseClient
end sub


' after_update  
Private Sub cmb1_AfterUpdate()
   Call setRecordset()
End Sub

'  
Private Function setRecordset()
    Dim strFieldName As String, sqlRowSource As String        
    strFieldName = DLookup("[QueryText]", "[tFindAlgo]", "[QueryType] = '" & frm.cmbFind.Value & "'")
    
    sqlRowSource = _
    "SELECT " & _
        "DISTINCT " & strFieldName & _
    "FROM " & _
        "[tCustomerInfo]"
    
    rstComboBox.Open sqlRowSource, CurrentProject.Connection, adOpenStatic, adLockOptimistic, adAsyncExecute
    
End Function

',  
'   2
Private Sub rstComboBox_MoveComplete(ByVal adReason As ADODB.EventReasonEnum, ByVal pError As ADODB.Error, adStatus As ADODB.EventStatusEnum, _
ByVal pRecordset As ADODB.Recordset)
 If boolFlag = False And rstComboBox.State = adStateOpen Then
    rstComboBox.ActiveConnection = Nothing
    Set Me.cmb2.Recordset = rstComboBox.Clone
    rstComboBox.Close
 End If
End Sub


.

http://www.sql.ru/forum/1145283/asinhronnyy-zapros


: [1] []
 

:
: 

: ( )

:

  URL