Original LoadSequence:

Sub LoadSequence ()
' Use Data Controls to retrieve info about file in FileDef$
Data1.RecordSource = SQL$ + FileDef$
Data1.Refresh
MovesData.RecordSource = MovesSQL$ + FileDef$
MovesData.Refresh
x%=DoEvents()
'if bound file name field is empty, add a new record to Files table
If Label4(0) = "" Then
   Data1.Recordset.AddNew
'  ... 
'  ... populate bound fields for new record
'  ...	
   Data1.Recordset.Update
 ' Restart the routine 	   
   Data1.Refresh
End If
'  ...
'  ... populate unbound controls with additional data
'  ...
End Sub


New server-side LoadSequence:

Public Function GetFileInfo(ByVal InfoRequestFile$) As Variant
Dim Moves() As Variant, mm as Object
FileDef$ = ExtractFileName(InfoRequestFile$)

' new routine replaces two Data Controls in original with
' a single stored parameter query which retrieves fields from
' both Files and Moves table: 

' Stored QUERYDEF named FilesAndMoves:
' PARAMETERS myfile Text;
' SELECT Files.Path, Files.Issue, Moves.*
' From Files, Moves
' WHERE Files.FileName =[myfile] And Files.FileName=Moves.FileName;

' Issue query
Set ParmQD = MyDB.QueryDefs("FileAndMoves")
ParmQD!myfile = FileDef$
Set mm = ParmQD.OpenRecordset(dbOpenDynaset, dbReadOnly)

' Count records in returned data set
With mm
        On Error Resume Next
        .MoveLast
        On Error GoTo 0
        recCount% = .RecordCount

' Redim variant array to record count + 3
' leaving room for data from files table in
' first two array elements, then stuff Moves
' table data in remaining elements 
        If recCount% <> 0 Then
        ReDim Moves(recCount% + 3)
      	  Moves(1) = !Path
        Moves(2) = !Issue
      	  For Counter% = 2 To recCount% + 2
            	Counter% = Counter% + 1
            Moves(Counter%) = !mFrom & comma$ & !mTo & comma$ & !MovedBy & comma$ & !mDate & comma$ & !mTime
.MovePrevious
        Next
      	  GetFileInfo = Moves()
    End If
End With
' Finish up
mm.Close
Set mm = Nothing
Set ParmQD = Nothing
End Function

New client-side LoadSequence:

Private Sub LoadSequence()
' Call GetFileIno method
Dim FileData As Variant, arrSize%
FileData = MyDBobj.GetFileInfo(InfoRequestFile$)

' If return val isn't a string array
' Call RecordMove to create an initial record 
' for file, then repeat call to GetFileInfo
If VarType(FileData) < (vbArray + vbString) Then
    Screen.MousePointer = 0
    Set MyDBobj = Nothing
    Set FileData = Nothing
    x% = DoEvents()
    Set MyDBobj = New cfDBsvr
    MyDBobj.RecordMove ExtractFileName$(InfoRequestFile$), 99, GetQueueNum%(ExtractFilePath$(InfoRequestFile$)), uName$
    Set MyDBobj = Nothing
    x% = DoEvents()
    x% = DoEvents()
    x% = DoEvents()
    Set MyDBobj = New cfDBsvr
    FileData = MyDBobj.GetFileInfo(InfoRequestFile$)
End If

' Extract data from returned Variant array
arrSize% = UBound(FileData)
fPath$ = FileData(1)
fIssue$ = FileData(2)
For x% = 3 To arrSize%
    MoveData = FileData(x%)
    If MoveData = "" Then
'   ...
'   ... fill in fields on GetInfo screen	
'   ...
    End If
Next
End Sub
