Hello,
I am having trouble with two buttons I inserted in a WinGrid. I added the two buttons side by side and they show correctly when I run the program but if i scroll to the right to see more columns and then scroll back to the left, the buttons overlap.
I would like some help to resolve this. Please see the image below:
Thank you.
Hello RichSee,
I`m not familar with your scenario, so could you please provide us more details. Are you using CreationFilter to add these buttons or you are using other approach. Please try to gice us more details or small sample with your issue and I`ll be glad to reseacrh it for you.
Let me know if you have any questions.
Regards
Have you been able to resolve your issue ? Did you have a time to take a look at the attached sample. Let me know if you have any questions.
Regareds
I actually didnt see the sample until I came back to respond. I am using a creation filter that builds the button programmatically.
Does that clue help?
In the mean time I can check out the sample code. Please let me know if you need me to send any of my code. Thanks!
Please take a look at the attached sample where I`m using CreationFilter and let me know if you have any questions. If you think that I didn`t reproduce your scenario, please feel free to modify this sample and revert it back to me. I`ll be glad to research this issue for you.,
Hi Georgi,
I looked at the sample you sent using the CreationFilter and modified it as little as I could by just adding one button. After adding the one button I got the same behavior I get in my project. Please take a look at the sample code that was modified.
Thank you, Georgi.
This helped a lot and we were able to solve our problem now.
Cheers.
Thanks for attached sample. I saw your issue, but the mentioned behavior is expected because your are using :
newButton.Rect =new Rectangle(33, 25, 70, 26); instead of my code:
newButton.Rect = new Rectangle(El.Rect.X +El.Rect.Width - 20, El.Rect.Y, 18, 18);
By this way you will get two different issues:
1. when you scroll your grid, the button will keep always his position
2. you will get issue with redraws of your control.
Please take a look at the attached video for more details and use my suggestion from my sample. Let me know if you have any questions.