Einzelnen Beitrag anzeigen

aaron

Registriert seit: 18. Feb 2003
202 Beiträge
 
Delphi 2007 Professional
 
#1

Word -Dokument den Cursor positionieren

  Alt 23. Apr 2008, 10:48
Hallo liebes Forum,

ich füge den Inhalt eines Stringgrid's in Word ein:

Delphi-Quellcode:
  //1. spalte zentriert
    WordApp.Selection.movedown(wdline, lineszaehler, wdextend);
    WordApp.Selection.ParagraphFormat.Alignment := wdAlignParagraphCenter;
  //nächste Spalte
    WordApp.Selection.moveright(wdcharacter, 1);
    if wordversion = '12.0then
      WordTable.Style := 'Tabellengitternetz';
    begin
      ProgressBar1.Max := iRows;
      for iGridRows := 1 to iRows do
      begin
        ProgressBar1.Position := 6 + iGridRows;
        for jGridCols := 1 to iCols do
        begin
          WordTable.Cell(iGridRows, jGridCols).Range.Text := StringGrid2.Cells[jGridCols - 1, igridRows - 1];
        end;
      end;
    end; end else
    ProgressBar1.Position := 0;
Meine Frage wäre, wie kann ich den Cursor ans Ende unter die Tabelle setzen?

Freundliche Grüße
Aaron
  Mit Zitat antworten Zitat