Jump to content


Photo

How to address/reference ActiveView.InsertRow data


  • Please log in to reply
2 replies to this topic

#1 ted

ted
  • Members
  • 1 posts

Posted 21 April 2017 - 02:16 AM

Hi

 

After activating the insert row

1. How do I have the cursor be placed automatically in first cell to add data (without having to use mouse)?

    Nextgrid6.selectCell(0,-1) does not work.

    Nextgrid6.selectCell(0,0) places cursor in row below the insert row.

 

2. How do I address/reference retrieve the data I key into each cell for verification etc?

 

Thanks



#2 Boki (Berg)

Boki (Berg)

    Boki (Berg)

  • Forum Admin
  • PipPipPipPipPip
  • 8,191 posts
  • Gender:Male

Posted 21 April 2017 - 09:19 AM

Hi,

You can use InsertValue property of each column. This is like temporary cell for only insert row:

  MyStrVar := NextGrid61.Columns.InsertValue.AsString;
Hope it helps.
boki@bergsoft.net | LinkedIn Profile
--
BergSoft Home Page: www.bergsoft.net
Users Section: users.bergsoft.net
Articles and Tutorials: help.bergsoft.net (Developers Network)
--
BergSoft Facebook page
--
Send us applications made with our components and we will submit them on: www.bergsoft.net/apps.htm. Link to this page will be also set on home page too.

#3 cuefejen

cuefejen
  • Members
  • 9 posts
  • Gender:Male
  • Location:Japan

Posted 27 February 2018 - 08:54 AM

Hi,

 

Because it has passed considerably, it may have already been solved ...

procedure TfrmMain.NxButton61Click(Sender: TObject);
begin
  NextGrid61.SetFocus;
  if not NextGrid61.Inserting then
  begin
    NxReportGridView61.ShowInsertRow := True;
    NextGrid61.SelectedCol := 0;
  end;
end;

If it is continuous input ...

procedure TfrmMain.NextGrid61InsertRowAdd(Sender: TObject);
begin
  NextGrid61.SelectedCol := 0;
end;

Thanks.






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users