• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 187
  • Last Modified:

graphical component

hi,
i created a component based on the TGraphicControl one, and i overrid its Paint method. now i can use this component during design time, and its behavior seems to be correct (the Paint method is correctly working). but when i try to run an app containing my component, even if the Paint method is called, nothing is displayed. could someone help me?

regards, raph
0
ralph78
Asked:
ralph78
1 Solution
 
zebadaCommented:
Can you post your code?

Are you calling myControl.Invalidate whenever you change the control's data and want the control to be repainted?


0
 
ralph78Author Commented:
my code is quite easy: i just draw some texts and rectangles. and i don't call the Invalidate method: i use Repaint when the control is resized or when one or another text is changed.
0
 
ITugayCommented:
Hi ralph78,

take a look at your HDD, may be there is more then one version of .DCU in search path.

------
Igor.
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
BudaCommented:
Try to use TCustomControl instead of TGraphic control. To make it work faster set the DoubleBuffered propety to true.
0
 
ITugayCommented:
Be carefull with TCustomControl, it is difficult to make it transparent.
0
 
ralph78Author Commented:
my code is quite easy: i just draw some texts and rectangles. and i don't call the Invalidate method: i use Repaint when the control is resized or when one or another text is changed.
0
 
ivobauerCommented:
Hi Ralph78!

When you run the sample project, your control is created programatically at run-time or it was dropped onto the form at design-time? Neverthless, it would be nice to see the component & sample project source if possible.

Best regards, Ivo.
0
 
ralph78Author Commented:
i don't know what i did, but my component is working now!
thanks anyway, ralph
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now