Hi I wonder if anyone can help me. This piece of soft can bookmarks a row in a dbgrid control when right button is clicked. If right button is clicked again the raw is no more highlighted, say "un-bookmarked". Well I've arrive to this solution, but is very tricky, and I guess there is another simpler approach. Thank you in advance for any comment. Dennis Crawley Argentina. '------------------------------------ Option Explicit 'global variables to the module. Dim RowValue As Integer Dim dbCounter As Integer Dim dbArray(150) As Integer '------------------------------------- Private Sub DBGridSonidos_MouseDown(Button As Integer, Shift As Integer, x As Single, y As Single) Dim i, z As Integer On Error GoTo noplay 'load raw value RowValue = DBGridSonidos.RowContaining(y) 'detect rigth click If Button = 2 Then dbCounter = dbCounter + 1 ' DBGridSonidos.SelBookmarks.Add DBGridSonidos.RowBookmark(RowValue) DBGridSonidos.Refresh 'test if is the same. If dbCounter = DBGridSonidos.SelBookmarks.Count Then 'load the raw value into the array variable. dbArray(dbCounter) = RowValue Else 'proceed to delete the bookmark - not the register - 'and to shift down all registers from 'the deleted one. For i = 0 To DBGridSonidos.SelBookmarks.Count If dbArray(i) = RowValue Then DBGridSonidos.SelBookmarks.Remove (i - 1) For z = i To DBGridSonidos.SelBookmarks.Count + 1 dbArray(z) = dbArray(z + 1) Next z 'reset the counter to the actual index position. dbCounter = DBGridSonidos.SelBookmarks.Count End If Next i End If End If noplay: Resume Next End Sub -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist