Re: Restoring font/form size at run time problem - help!
- From: rowe_newsgroups <rowe_email@xxxxxxxxx>
- Date: Tue, 25 Mar 2008 11:42:26 -0700 (PDT)
On Mar 25, 1:10 pm, Terry <Ter...@xxxxxxxxxxxxx> wrote:
Hope someone has some ideas - this is driving me nuts,
I am using VS2008 and have a tightly layed out form at 8 pts. The form
has a font dialog and when the user changes the font size, everything works
great. I go through the forms control collection (recurively) and everything
resizes as it should.
Ok, so the next step is to remember the font size selected by the user
and select it when the form is loaded. Woops - does not work! So, I try to
do it 'earlier' in a Sub New() and it still does not work. I try it later,
in the Activated event and same problem, the form never resizes. So all the
controls have the new (larger) font, but the form (and the controls in it)
have not resized!
Ok, so I think, well I will also have to set the form size myself. This
almost works!
Some parts grow as they should, some grow more then they should and some
don't grow at all!
So, if the user is able to select a font, and it works, how do I
duplicate that when the user starts up the application again? Is there some
place besides New/Load/Activated that I should be doing this from?
TIA,
--
Terry
Is your restore font size method different than the one you are using
to change the font size when the user changes it? Ideally, the restore
should be just retrieving a font value from a data store (.config,
registry, seperate xml, etc) and then running the same method you use
when the users changes the font size.
Thanks,
Seth Rowe [MVP]
.
- References:
- Prev by Date: read sql record into memory, use/modify fields then save changes
- Next by Date: Re: read sql record into memory, use/modify fields then save changes
- Previous by thread: Restoring font/form size at run time problem - help!
- Next by thread: syntax for EnumPrinters printer object
- Index(es):
Relevant Pages
|