Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
1/2 of the solution to Rightclick() on the image in the
Message
 
To
28/02/2003 16:42:05
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00759590
Message ID:
00759845
Views:
14
>Hi Nick,
>
>>This is not a bug, this is by design. Tecnically there is only one image >control in the column for all visible records. When .Sparse = .t. you see >the image only in the active row when you click on another row, it becomes >active and shows the image control.
>>You want to show the different images in every record and be able to right >click and run some code for any row, correct?
>
>Yes, Do you have a suggestion or solution?

Yes, I have the second (and the most important :) half of the solution. :-)

Place into the grid column not the image control alone, but the container control with the image control in it. (You will need to create a container+image class for that). Then place your desired code into container RightClick() method and it will work. You can set column.Sparse = .F. to see all the images in the grid rows.

I assume you know how to show different images in grid rows. If not - you can do it using Dynamic... properties, for example DynamicFontBold.
form1.grid1.column1.DynamicFontBold = "thisform.ShowPicture()"
*** form1.ShowPicture() method
thisform.Grid1.column1.cntImage1.image1.Picture = your_field_with_picture_pathname
RETURN .f.
If you want, I can send you a sample form.
Nick Neklioudov
Universal Thread Consultant
3 times Microsoft MVP - Visual FoxPro

"I have not failed. I've just found 10,000 ways that don't work." - Thomas Edison
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform