PROFESSIONAL NEWSGROUPS
WINDEV
,
WEBDEV
and
WINDEV Mobile
Home
|
Recent messages
|
Connect
|
Sign out
|
English
Home
→
WINDEV 2024
→
Simplified Drag & Drop with Tables
Simplified Drag & Drop with Tables
Started by VEGEboss, Oct., 10 2019 12:47 PM - 1 reply
Connect yourself…
VEGEboss
#1
Registered member
88 messages
Popularité : +2 (2 votes)
Posted on October, 10 2019 - 12:47 PM
hello folks
I have 2 tables in the same Windows and I have activated
the DnD Source on the Table A and the DnD Target on the Table B
When I drag row(s) from A to B I correctly get a copy of the data
in the second table
The question is: can I know HOW MANY rows are passing from
A to B to automatically change some data in the B tables?
If I put some code in the "Drop in Target" Section, the rows
are NO MORE COPIED and I can't understand how to workaround...
Thank you very much
Report
0
0
BALTASAR
#2
Registered member
52 messages
Popularité : +3 (3 votes)
Posted on October, 11 2019 - 12:53 PM
Not sure if you want this:
add "DROP IN TARGET DRAG/DROP (DNDDROP) ON table_target" event
and this code:
Rows_to_Drop
is int
=
ListSelectCount
(
_DND.SourceControl
)
Later, I saw what you meant .... OK
try this:
at "DROP IN TARGET DRAG/DROP (DNDDROP) ON table_target" event
Rows_to_Drop
is int
=
ListSelectCount
(
_DND.SourceControl
)
FOR
E
ACH SELECTED ROW OF
TABLE_
SOURCE
TableAdd
(
TABLE_
TARGET
,
TABLE_
SOURCE
[
TABLE_
SOURCE
]
)
END
Notice: TABLE_SOURCE and TABLE_TARGET must have same number of columns, but you can change code to avoid this.
Message modified, October, 11 2019 - 1:20 PM
Report
0
0
→ Go back to WINDEV 2024
WINDEV 2024
WEBDEV 2024
WINDEV Mobile 2024
WINDEV (earlier versions)
Français
English
Español
Portuguesa
Close this window
Search type
Only topics
All the messages
Search period
Any time
Past hour
Past 24 hours
Past week
Past month
Past year
Cancel
Preview of your message
Adding an image
Import an image from a URL
Send an image from a file of your disk
Drop a file or click "Browse..."
or
Cancel
0%
WLanguage
SQL
XML, HTML
JAVA, Javascript
Text