d.bernaert Posted November 14, 2018 Share Posted November 14, 2018 Hello, for a custom project I need to multi-select a number of records in the left grid. I must be able to drag them to a second grid and there I have to find out on which record they are dropped in the grid. This is because I have to insert them before the record they are dropped on (sequence in the database). Is there any way to get the record I'm dropping the selected records on? The rest is database stuff, should be able to handle the order on that level. Thx, Bernaert Dominique Quote Link to comment Share on other sites More sharing options...
erich.wanker Posted November 15, 2018 Share Posted November 15, 2018 i think you mean this: uniDBGrid - properties: i use a grid with checkboxes ... multiselect .. to find the selected records: s:='-1'; with UniDBGrid1.DataSource.DataSet do for i:=0 to UniDBGrid1.SelectedRows.Count-1 do begin GotoBookmark(UniDBGrid1.SelectedRows.Items); s:=s+','+ UniDBGrid1.DataSource.DataSet.FieldByName('INR').asstring; end; unimainmodule.markierte_anteile:= 'SELECT * FROM ANTEILE WHERE INR IN ('+s+')'; hth erich Quote Link to comment Share on other sites More sharing options...
Sherzod Posted November 15, 2018 Share Posted November 15, 2018 14 hours ago, d.bernaert said: I must be able to drag them to a second grid and there I have to find out on which record they are dropped in the grid. Hello, Have you seen this demo?: \FMSoft\Framework\uniGUI\Demos\Desktop\Grid - DragDrop - Custom Handler Quote Link to comment Share on other sites More sharing options...
d.bernaert Posted November 15, 2018 Author Share Posted November 15, 2018 No, sorry. Will review it. Thx. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.