Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Grid1.Column1.Text1.MousePointer = 1 --- ignored!!!
Message
 
 
À
30/03/1998 19:45:46
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00088270
Message ID:
00088276
Vues:
31
Larry,

If you are trying to achieve "read-only grid", I whipped this up a couple of weeks ago in response to a newsgroup post:

I'm not sure there's a way to do it with the native grid and control properties. Here's one way to do it. Put a Shape object over the cell portion of the grid with this code in it's MouseUp:

LPARAMETERS nButton, nShift, nXCoord, nYCoord

* converts a mouse click in the shape to activate the underlying grid cell

local lnRow, lnCol, lnWidth

lnRow = int( 1 + ( nYcoord - this.Top ) / thisform.grdTheGrid.RowHeight )

lnWidth = 0
nXCoord = nXCoord - this.Left

for lnCol = thisform.grdTheGrid.LeftColumn to thisform.grdTheGrid.ColumnCount
lnWidth = lnWidth + thisform.grdTheGrid.Columns[lnCol].Width + thisform.grdTheGrid.GridLineWidth
if ( lnWidth > nXCoord )
exit
endif
endfor

lnCol = lnCol - thisform.grdTheGrid.LeftColumn + 1

thisform.grdTheGrid.ActivateCell( lnRow, lnCol )


>How can I set the mouse pointer to an arrow when it's over a grid? I wasn't able to get the MousePointer property to work.
df (was a 10 time MVP)

df FoxPro website
FoxPro Wiki site online, editable knowledgebase
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform