473,779 Members | 2,083 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Inherited form doesn't have controls from parent

I have a simple form with a panel that is docked in the base form. The panel
has three controls - two buttons and one treeview.

I use "Inherited Form" when creating a second form derived from this parent
form. The only thing is there are no controls in the inherited form. I made
all the base controls "protected" . What am I dong wrong?

--
-----------
Thanks,
Steve
May 2 '06 #1
2 1755
Steve,

I was able to create inherited forms two different ways, one of them using
the inherited form method, and one just using a reference to another project.
If I was guessing, I would guess that your base form was created as a
Windows application and compiled as an exe. If you will go to the properties
of that project and change it to a library application, then build it, that
should solve your problem.

HTH

WhiteWizard (aka Gandalf)
MCSD.NET, MCAD, MCT
"Steve Teeples" wrote:
I have a simple form with a panel that is docked in the base form. The panel
has three controls - two buttons and one treeview.

I use "Inherited Form" when creating a second form derived from this parent
form. The only thing is there are no controls in the inherited form. I made
all the base controls "protected" . What am I dong wrong?

--
-----------
Thanks,
Steve

May 2 '06 #2
I discovered my inherited form needed to call the base class form's
constructor and it had to call the InitializeComon ents.
--
-----------
Thanks,
Steve
"Steve Teeples" wrote:
I have a simple form with a panel that is docked in the base form. The panel
has three controls - two buttons and one treeview.

I use "Inherited Form" when creating a second form derived from this parent
form. The only thing is there are no controls in the inherited form. I made
all the base controls "protected" . What am I dong wrong?

--
-----------
Thanks,
Steve

May 2 '06 #3

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

Similar topics

11
18837
by: Jozef | last post by:
I have some old code that I use from the Access 95 Developers handbook. The code works very well, with the exception that it doesn't seem to recognize wide screens, and sizes tab controls so that they are too big and wind up covering up some of the fields on the main form. Is there any good code out there that works in a similar fashion that will also either a) stretch the form width wise on widescreens or b), rely on height rather than...
8
6715
by: Spam Trap | last post by:
I am getting strange resizing problems when using an inherited form. Controls are moving themselves seemingly randomly, but reproducibly. "frmBase" is my base class (a windows form), and contains a few controls anchored to the sides of the form. "frmChild" inherits from "frmBase"... and the controls appear on the inherited form as expected. However things start going wrong when I place addition controls on the "frmChild" form. When I...
24
1835
by: Nak | last post by:
Hi there, I have some inherited forms that I wish to make "localizable", unfortunately none of the items I wish to be "localizable" are actually being "localized". For example, I have a few of properties which set the text of some labels on the form which are inherited from the base form, these text values aren't "localized" Has anyone any ideas where I'm going wrong? Nick.
4
3758
by: dbuchanan | last post by:
Is the following behavior normal? Both the 'Protected sub' in the inherited form and the 'Private Shadows sub' in the derived form fires. My interpretation of MSDN help on the topic "Shadows" does not seem to indicate that this is the designed behavior. (the topic is rather cryptic to me. Here is my code;
10
5113
by: John M. Gabriele | last post by:
The following short program fails: ----------------------- code ------------------------ #!/usr/bin/python class Parent( object ): def __init__( self ): self.x = 9 print "Inside Parent.__init__()"
4
1948
by: asad.naeem | last post by:
hi to all this is the problem about inheritence. I have designed a form with some essential controls which are required for every form which will inherited from it. for example i have Button1 on parent form and this button is visible to me on inherited form. The problem is: I have written a click event of the button1 on both of the forms. tell me the way if i click the button on inherited form only parents' click event will be called and...
4
16265
by: Mikus Sleiners | last post by:
I can't seem to add new controls to form that is inherited from another form. I have BaseForm wich have table layout on it 2 panelsm and some buttons. Now i create InheritedForm : BaseForm and want to add some new controls and add them to pannels but i can't drag and drop them ... designer does not allow me. Why is that ? Panels and table layout modifiers is set to public.
14
2644
by: lovecreatesbea... | last post by:
Could you tell me how many class members the C++ language synthesizes for a class type? Which members in a class aren't derived from parent classes? I have read the book The C++ Programming Language, but there isn't a detail and complete description on all the class members, aren't they important to class composing? Could you explain the special class behavior in detail? Thank you very much.
4
3502
by: EmilH | last post by:
Hi. I couldn't find it in msdn. I have a form AddCategory. Now I need EditCategory form which should look exactlay like AddCategory. I add an inherited form to the project. Now all controls' properties are read-only. I need to change AddButton's Name and Text properties to Edit. I change Modifier property of the parent control to public, but it doesn't solve. Can anybody help me? Thanks.
0
9633
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9474
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8959
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6724
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5373
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5503
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4037
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3632
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2867
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.