Board index » delphi » TDBGrid.SelectedRows.Items[] ???

TDBGrid.SelectedRows.Items[] ???

TDBGrid.SelectedRows.Items[] returns a TBookmarkStr... how do I use this to
get to the values of columns in the selected rows of the DBGrid?

Any help will be appreciated.

Thanks
Joshua

 

Re:TDBGrid.SelectedRows.Items[] ???


Here's some coding example, hope this helps !
DisableControls;
    bmTemp := GetBookMark;
    for I := 0 To  dbGridAnsp.SelectedRows.Count -1 Do
      begin
       Bookmark := ( dbGridAnsp.SelectedRows.ITems[I]);
       if (FieldByName('EMAIL').AsString <> '') Then
        Begin
         if strSelectedEmails <> '' Then strSelectedEmails :=
strSelectedEmails + '; ';
         strSelectedEmails := strSelectedEmails +
FieldByName('EMAIL').AsString;
        end;
    end;
    GotoBookMark(bmTemp);
    EnableControls;

Joshua Saayman <j...@BTSConsulting.com> schrieb im Beitrag
<6fq4jj$f...@news01.iafrica.com>...

Quote
> TDBGrid.SelectedRows.Items[] returns a TBookmarkStr... how do I use this
to
> get to the values of columns in the selected rows of the DBGrid?

> Any help will be appreciated.

> Thanks
> Joshua

Other Threads