How to order the in accordance report below

  • Thread starter Thread starter Frank Dulk
  • Start date Start date
F

Frank Dulk

I open a report through a button in a form.
This form is a result of a consultation, and the same sql that I use when
making the consultation, I pass for the report.

How to order the in accordance report below:

Private Sub Report_Open(Cancel As Integer)
Report_NSsSituacao.RecordSource = sqlSIT
If Form_frm_Situacao_Fra.txtSituacao = "EM VISTORIA" Then
Report_NSsSituacao.OrderByOn = True
Reports!NSsSituacao.OrderBy = "Matricula"
End If
End Sub
 
Reports don't respect the order of the data in a recordset. The only
reliable way to guarantee the order of records in a report is to use the
Sorting and Grouping dialog.
 
thank you.


Douglas J. Steele said:
Reports don't respect the order of the data in a recordset. The only
reliable way to guarantee the order of records in a report is to use the
Sorting and Grouping dialog.
 
Back
Top