Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Dragging onto a Grid
Message
From
12/05/2004 16:16:17
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00903336
Message ID:
00903349
Views:
21
Thanks! That's what I needed. Here's the code that I use. It works quite nicely:

LPARAMETERS oSource, nXCoord, nYCoord
LOCAL nRow, nCol
nRow = 1
nCol = 1
IF this.GridHitTest( nXCoord, nYCoord, 3, @nRow, @nCol )
= this.ActivateCell( nRow, nCol )
this.Column1.Text1.Value = oSource.Value
oSource.Value = '* ' + ALLTRIM( oSource.Value ) && Let's user know it's been selected
this.Refresh()
ENDIF

This code is in the DragDrop method of the Grid, not the Text1 object.

>I have not tested this but it may be a possible starting point. Look into the GridHitTest Method in combination with MouseMove/Dragover.
>
>HTH,
>
>Richard
>
>>Hi All -- Is there a way to drag and drop onto a grid so that the cell under the mouse recieved the effect of the drop rather than the active row in the grid. For example, in the target grid, row six is selected, but you drag an object and drop it over row 10 of the grid. How can you get the data in row 10 to accept the drop rather than row six?
>>
>>TIA
Previous
Reply
Map
View

Click here to load this message in the networking platform