473,786 Members | 2,607 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Question about visual inheritance

Hi,

i've created a base-form from which all the forms in my application need to
inherit.

This works just fine.
I've put some buttons on my base-form.
They are displayed correctly, only if my inheriting form is bigger than my
base-form, the buttons stay at the position where i've put them on my
base-form.

How can I change that?

Greetings.
Nov 20 '05 #1
6 1301
Did you try to use the Anchor property of your button(in the base form) ?

Ernest
"Bart Schelkens" <bs********@hot mail.com> wrote in message
news:ua******** *****@TK2MSFTNG P10.phx.gbl...
Hi,

i've created a base-form from which all the forms in my application need to inherit.

This works just fine.
I've put some buttons on my base-form.
They are displayed correctly, only if my inheriting form is bigger than my
base-form, the buttons stay at the position where i've put them on my
base-form.

How can I change that?

Greetings.

Nov 20 '05 #2
Yes, but when i anchor it to the bottom right, it still has the same
problem.
"Ernest Morariu" <er****@gesora. com> schreef in bericht
news:ua******** ******@TK2MSFTN GP12.phx.gbl...
Did you try to use the Anchor property of your button(in the base form) ?

Ernest
"Bart Schelkens" <bs********@hot mail.com> wrote in message
news:ua******** *****@TK2MSFTNG P10.phx.gbl...
Hi,

i've created a base-form from which all the forms in my application need

to
inherit.

This works just fine.
I've put some buttons on my base-form.
They are displayed correctly, only if my inheriting form is bigger than my base-form, the buttons stay at the position where i've put them on my
base-form.

How can I change that?

Greetings.


Nov 20 '05 #3
When I played with Visual Inheritance (until I eventually gave up), seems to
me you had to scope your controls as Protected, instead of the default
Friend.

Greg

"Bart Schelkens" <bs********@hot mail.com> wrote in message
news:en******** ******@tk2msftn gp13.phx.gbl...
Yes, but when i anchor it to the bottom right, it still has the same
problem.
"Ernest Morariu" <er****@gesora. com> schreef in bericht
news:ua******** ******@TK2MSFTN GP12.phx.gbl...
Did you try to use the Anchor property of your button(in the base form) ?

Ernest
"Bart Schelkens" <bs********@hot mail.com> wrote in message
news:ua******** *****@TK2MSFTNG P10.phx.gbl...
Hi,

i've created a base-form from which all the forms in my application
need to
inherit.

This works just fine.
I've put some buttons on my base-form.
They are displayed correctly, only if my inheriting form is bigger
than my base-form, the buttons stay at the position where i've put them on my
base-form.

How can I change that?

Greetings.



Nov 20 '05 #4
I tried it and it worked fine, thx.
"Greg Burns" <gr********@hot mail.com> schreef in bericht
news:uo******** *******@TK2MSFT NGP10.phx.gbl.. .
When I played with Visual Inheritance (until I eventually gave up), seems to me you had to scope your controls as Protected, instead of the default
Friend.

Greg

"Bart Schelkens" <bs********@hot mail.com> wrote in message
news:en******** ******@tk2msftn gp13.phx.gbl...
Yes, but when i anchor it to the bottom right, it still has the same
problem.
"Ernest Morariu" <er****@gesora. com> schreef in bericht
news:ua******** ******@TK2MSFTN GP12.phx.gbl...
Did you try to use the Anchor property of your button(in the base form)
?

Ernest
"Bart Schelkens" <bs********@hot mail.com> wrote in message
news:ua******** *****@TK2MSFTNG P10.phx.gbl...
> Hi,
>
> i've created a base-form from which all the forms in my application need to
> inherit.
>
> This works just fine.
> I've put some buttons on my base-form.
> They are displayed correctly, only if my inheriting form is bigger

than
my
> base-form, the buttons stay at the position where i've put them on

my > base-form.
>
> How can I change that?
>
> Greetings.
>
>



Nov 20 '05 #5
Glad to hear it worked.

Backup frequently. I can't tell you how many times I designed a child form,
that the IDE would suddenly remove all the added controls.

Have you ran into this error yet? I got so frustrated seeing it, that I
stopped working with visual inheritance.

"An error occurred while loading this document. Fix the error, and then try
loading the document again. The error messge follows:
The designer must create an instance of type 'FooBar' but it cannot because
the type is declared as abstract."

(Usually recompiling, will fix that. Make sure you have all [Design] forms
closed in the IDE first!. Restarting the IDE sometimes helped too.)

I had some success, using code like this to get around certain issue with
the designer. But, again it was just too frustrating.

#If DEBUG Then
Public Class Foo
#Else
Public MustInherit Class FooBar
#End If

good luck!
Greg
"Bart Schelkens" <bs********@hot mail.com> wrote in message
news:O9******** ******@TK2MSFTN GP10.phx.gbl...
I tried it and it worked fine, thx.
"Greg Burns" <gr********@hot mail.com> schreef in bericht
news:uo******** *******@TK2MSFT NGP10.phx.gbl.. .
When I played with Visual Inheritance (until I eventually gave up), seems
to
me you had to scope your controls as Protected, instead of the default
Friend.

Greg

"Bart Schelkens" <bs********@hot mail.com> wrote in message
news:en******** ******@tk2msftn gp13.phx.gbl...
Yes, but when i anchor it to the bottom right, it still has the same
problem.
"Ernest Morariu" <er****@gesora. com> schreef in bericht
news:ua******** ******@TK2MSFTN GP12.phx.gbl...
> Did you try to use the Anchor property of your button(in the base form)
?
>
> Ernest
>
>
> "Bart Schelkens" <bs********@hot mail.com> wrote in message
> news:ua******** *****@TK2MSFTNG P10.phx.gbl...
> > Hi,
> >
> > i've created a base-form from which all the forms in my

application need
> to
> > inherit.
> >
> > This works just fine.
> > I've put some buttons on my base-form.
> > They are displayed correctly, only if my inheriting form is bigger

than
my
> > base-form, the buttons stay at the position where i've put them on

my > > base-form.
> >
> > How can I change that?
> >
> > Greetings.
> >
> >
>
>



Nov 20 '05 #6
I haven't had that error just yet.
Might still come though.
"Greg Burns" <gr********@hot mail.com> schreef in bericht
news:u2******** ******@TK2MSFTN GP10.phx.gbl...
Glad to hear it worked.

Backup frequently. I can't tell you how many times I designed a child form, that the IDE would suddenly remove all the added controls.

Have you ran into this error yet? I got so frustrated seeing it, that I
stopped working with visual inheritance.

"An error occurred while loading this document. Fix the error, and then try loading the document again. The error messge follows:
The designer must create an instance of type 'FooBar' but it cannot because the type is declared as abstract."

(Usually recompiling, will fix that. Make sure you have all [Design] forms
closed in the IDE first!. Restarting the IDE sometimes helped too.)

I had some success, using code like this to get around certain issue with
the designer. But, again it was just too frustrating.

#If DEBUG Then
Public Class Foo
#Else
Public MustInherit Class FooBar
#End If

good luck!
Greg
"Bart Schelkens" <bs********@hot mail.com> wrote in message
news:O9******** ******@TK2MSFTN GP10.phx.gbl...
I tried it and it worked fine, thx.
"Greg Burns" <gr********@hot mail.com> schreef in bericht
news:uo******** *******@TK2MSFT NGP10.phx.gbl.. .
When I played with Visual Inheritance (until I eventually gave up), seems
to
me you had to scope your controls as Protected, instead of the default
Friend.

Greg

"Bart Schelkens" <bs********@hot mail.com> wrote in message
news:en******** ******@tk2msftn gp13.phx.gbl...
> Yes, but when i anchor it to the bottom right, it still has the same
> problem.
>
>
> "Ernest Morariu" <er****@gesora. com> schreef in bericht
> news:ua******** ******@TK2MSFTN GP12.phx.gbl...
> > Did you try to use the Anchor property of your button(in the base

form)
?
> >
> > Ernest
> >
> >
> > "Bart Schelkens" <bs********@hot mail.com> wrote in message
> > news:ua******** *****@TK2MSFTNG P10.phx.gbl...
> > > Hi,
> > >
> > > i've created a base-form from which all the forms in my application need
> > to
> > > inherit.
> > >
> > > This works just fine.
> > > I've put some buttons on my base-form.
> > > They are displayed correctly, only if my inheriting form is bigger than
> my
> > > base-form, the buttons stay at the position where i've put them

on my
> > > base-form.
> > >
> > > How can I change that?
> > >
> > > Greetings.
> > >
> > >
> >
> >
>
>



Nov 20 '05 #7

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

Similar topics

2
3094
by: Matt | last post by:
I have created an MDI child form that I am using as a base form in a VB.Net MDI application. The base MDI child form has a series of menu options on it. I then use this form to create other MDI child forms (using inheritance). The problem is that the derived MDI child form's menu options don't seem to have inherited the functionality from the base form (i.e. the inherited menu options don't work). If I place a command button or other...
4
385
by: aap | last post by:
Hi, I have the following code. #include <iostream> using namespace std; class Root { public: virtual void Root1() = 0; virtual void Root2() = 0;
30
1956
by: Elhanan | last post by:
hi all i have a question in desgning a form.. the application in question is something a indexing station. the user in this indexing station views a document in pdf/tiff format on the right side of the form and enters the index data through various fields and listboxes on the left side.
10
1410
by: Gopal Prabhakaran | last post by:
Hi Pls Help me to do Visual Inheritance with ASP.NET -- Thanx Gopal Prabhakaran
6
1771
by: Peter Oliphant | last post by:
I just discovered that the ImageList class can't be inherited. Why? What could go wrong? I can invision a case where someone would like to add, say, an ID field to an ImageList, possible so that the individual elements in an array of ImageList's could be identified by the ID, thereby allowing re-ordering the array without harm. A person could identify by index into the array, but that would not be preserved by re-ordering (and re-ordering...
3
1363
by: Dino Buljubasic | last post by:
Hi, I am thinking of using visual inheritance. I am using C# VS 2005. I am concerned about how good it is. I have heard about problems like controls dissapearing or so. Any hints, tips, ideas, concerns ??? Thank you, _dino_
4
1732
by: MikeB | last post by:
I've been all over the net with this question, I hope I've finally found a group where I can ask about Visual Basic 2005. I'm at uni and we're working with Visual Basic 2005. I have some books, - Programming Visual Basic by Balena (MS Press) and - Visual Basic 2005 by Willis (WROX), but they don't go into the forms design aspects and describing the various controls at all. What bookscan I get that will cover that?
7
4474
by: jason | last post by:
In the microsoft starter kit Time Tracker application, the data access layer code consist of three cs files. DataAccessHelper.cs DataAcess.cs SQLDataAccessLayer.cs DataAcccessHelper appears to be checking that the correct data type is used DataAcess sets an abstract class and methods
30
1911
by: Logos | last post by:
I have what may be a bug, or may be a misunderstanding on how pass by reference and class inheritance works in PHP. Since I'm relatively new to PHP, I'm hoping for a little outside help to shed some light on this! (code abbreviated for clarity) I have a parent class, DetailCollection, with a child class KeycodeTracker:
0
9647
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
10164
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10110
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9961
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
6745
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
5534
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4066
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
3669
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2894
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.