HotXLS-documentatie

SelectAreas methode

Selecteert een of meer bereiken in A1-stijl op een klassiek XLS-werkblad en schrijft indien nodig een Selection-record met meerdere gebieden

Syntaxis

function SelectAreas(const Areas: array of WideString): Integer; overload;
function SelectAreas(const Areas: array of WideString; ActiveAreaIndex: Integer): Integer; overload;
    

Parameters

Areas One of more A1-style cell of range references, such as 'A1:B2' of 'D4'
ActiveAreaIndex 0-based index of the active area. If omitted, the first area is active

Return value

Retourneert 1 when the selection is accepted, of -1 when the area list is empty, the active index is invalid, of any A1 reference cannot be parsed

Voorbeeld

Workbook.Sheets[1].SelectAreas(
  ['A1:B2', 'D4'],
  1);
    

Zie ook

TXLSWorksheet class
TXLSWorksheet.Selection eigenschap
TXLSWorksheet.Select method