473,324 Members | 2,501 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,324 software developers and data experts.

UserControl and Design-time

Hello

I'm writing a control based on UserControl class. My control will paint
itself using only graphics methods like DrawRectangle, DrawString, etc.
The problem is that in design time I can't see the end result in
designer (when I press F7 to change the view from source to designer).
Is it possible (and how) to make this control visible in design time?

When I put this control on sample windows form - it's visible - but I
want to see results without making sample windows form.

Thanks in advance for the answer
Nov 17 '05 #1
1 2108
You need to create a Custom Designer for the Control. See:

http://msdn.microsoft.com/library/de...sgnrdotnet.asp

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer
A watched clock never boils.

"aspirit" <as*****@o2.pl> wrote in message
news:dk**********@nemesis.news.tpi.pl...
Hello

I'm writing a control based on UserControl class. My control will paint
itself using only graphics methods like DrawRectangle, DrawString, etc.
The problem is that in design time I can't see the end result in designer
(when I press F7 to change the view from source to designer).
Is it possible (and how) to make this control visible in design time?

When I put this control on sample windows form - it's visible - but I want
to see results without making sample windows form.

Thanks in advance for the answer

Nov 17 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Tiago Barbutti | last post by:
I have a UserControl that execute methods in Load event, but it hapens in designMode and generate an error and the control disappear from the form. I read that i can use the DesignMode to kwnow...
6
by: steve bull | last post by:
I created a usercontrol class, RGBColorSpace, which is derived from an abstract class, ColorSpace, but when I try to click on the design panel for the control I get an error message "Unable to...
6
by: Javaman59 | last post by:
This must be a common GUI design issue - whether to treat the GUI object which represents a thing as if it were the thing itself. I'll put it in the form which I've come across recently... I...
4
by: Joel Barsotti | last post by:
On certain pages I want to have a user control that is derived not directly from the usercontrol class, but from a class that extends the UserControl class so my objects will have a some...
1
by: Luis Ferrao | last post by:
Happy new year everyone. I'm building a templated website. For each individual content page I have a UserControl that holds the content. The UserControl inherits from a custom PlaceHolder...
3
by: Patrick.O.Ige | last post by:
I created a USERCONTROL and i want to call a LABEL from an ASPX page. The USERCONTROL is in the ASPX page I have the label :- Label lblstr = new Label(); And displaying using:-...
11
by: Crirus | last post by:
I need to derive the Windows.Forms.Control 2 times so I design a class like this Public Class BMControl Inherits System.Windows.Forms.UserControl Public Class MapControl Inherits BMControl
2
by: Patrick McGuire | last post by:
I want to place a tabControl with almost identical properties on several forms. I think the best way is to define a UserControl that inherits System.Windows.Forms.TabControl, and place all my...
0
by: elziko | last post by:
I have a UserControl inside my project. When I click on the UserControl in the design view I get to also view all its properties in the property grid. I the change the AllowDrop property to True. ...
5
by: Pieter | last post by:
Hi, I'm getting a really terrible and anoying bug/problem in VS.NET 2005: 1. Create a new Windows Application. 2. Add a new class Class1. 3. Add a usercontrol UserControl1. 4. Add a public...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.