Ver Mensaje Individual
  #2  
Antiguo 03-01-2007
Avatar de Cabanyaler
Cabanyaler Cabanyaler is offline
Miembro
 
Registrado: jun 2003
Ubicación: País Valencià
Posts: 339
Reputación: 22
Cabanyaler Va por buen camino
Bueno a falta de conocer como pasarlo como parametro, esta es la mejor "y única" forma que he visto para hacerlo. Aunque no me mola mucho, ya que el orden se establece en el lado cliente, con el consecuente coste de proceso.

Cita:
VCL Reference
TCustomADODataSet.Sort

TCustomADODataSet See also

Specifies the sort order of the recordset.

property Sort: WideString;

Description

Set Sort to establish or change the list of fields on which the recordset is sorted. Set sort to the name of a single field or to a comma-separated list of fields. Each field may optionally be followed by the keyword ASCENDING or DESCENDING to specify a sort direction for the field. If one of these keywords is not used, the default sort direction for the field is ascending. Set Sort to an empty string to reset the recordset to the sort order originally used when the recordset’s data was first retrieved.

ADOQuery1.Sort := 'LastName ASC, DateDue DESC'

Read Sort to determine the field (or fields) on which the recordset is sorted.

Note: If the cursor is client-side (the dataset component’s CursorLocation property or that of an associated TADOConnection component is clUseClient) and no index already exists matching the requested field sort order, a temporary index is created. Resetting the sort order by setting Sort to an empty string automatically deletes the temporary index.

No obstante si sabeis, conoceis, os han contado..... otra solución como la que yo busco..., gracias
__________________
El meu país és tan petit, que des de dalt d'un campanar es pot veure el campanar veí.
Responder Con Cita