Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Windows Forms / Design Time / October 2005

Tip: Looking for answers? Try searching our database.

Third-party control property at design time

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
AlexZh - 30 Sep 2005 22:56 GMT
Hi,

I have a problem with changing properties of a third-party control at
design time when the control is encapsulated into my own user control.

I have a third-party control (TPControl) that allows me to change
properties at design time. I mean, if the control is dropped on a form
and some properties are changed in PropertyGrid atg design time all the
changes are persistent (some code lines are generated).

Different result when I use this control encapsulated into my
UserControl.
I create my own UserControl (MyUC) and encapsulate this third-party
control in my UserControl (by dropping it on UserControl). I manually
create a property that exposes this third-party control.

private TPControl tpControl;
public TPControl TheTPControl
{
get
{
    return tpControl;
}
}

I drop my UserControl on a form.
When I open PropertyGrid for my UserControl being set on a form I can
expand the property item (TheTPControl), which is responsible for
third-party control. PropertyGrid allows me to change any value for
that third-party control, but these changes are not persistent. I mean,
after project is rebuild all the changes are lost, no code lines are
generated.

Any ideas?

Thank you,
Alex Zhitlenok
Atul - 11 Oct 2005 06:37 GMT
Make sure you have set DesignerSerializibiltyAttribute to Content for the
TheTPControl property.

----------------
-Atul, Sky Software http://www.ssware.com
Shell MegaPack For .Net & ActiveX :
Windows Explorer GUI Controls
&
Quick-Launch Like Appbars, MSN/Office2003 Style Popups,
System Tray Icons and Shortcuts/Internet Shortcuts
----------------

> Hi,
>
[quoted text clipped - 33 lines]
> Thank you,
> Alex Zhitlenok

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.