473,396 Members | 1,942 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,396 software developers and data experts.

How "should" I remember and reuse form size and location?

I have a VC 2005 application that I want to remember some dialog locations
and sizes between executions.
What is the recommended process for this?

Steve
Jan 18 '08 #1
4 1104
>I have a VC 2005 application that I want to remember some dialog locations
>and sizes between executions.
What is the recommended process for this?
Steve,

I'd try handling the WM_WINDOWPOSCHANGED message, save the settings
you want and restore them (using SetWindowPos) in response to the
WM_INITDIALOG message on startup.

Dave
Jan 20 '08 #2
Thanks Dave.
I know how to get and set the position and size, but what is the
recommended/easiest method to store and retrieve the values.
Previously I have used registry entries, but what should I use in dotnet
2.0?

Steve
Jan 20 '08 #3
>I know how to get and set the position and size, but what is the
>recommended/easiest method to store and retrieve the values.
Previously I have used registry entries, but what should I use in dotnet
2.0?
I don't know what's best for your application Steve, it depends on
your requirements as to whether you should continue to use the
registry or store the settings in a configuration file. If it's a
per-user setting, I'd probably stick with the registry myself.

Dave
Jan 21 '08 #4
I already have a configuration file for application settings, but I want to
keep per user stuff for screen layouts.
I will use the regsitry.

Thanks Dave
Jan 22 '08 #5

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

Similar topics

2
by: Jerry Sievers | last post by:
Hello. Maybe I'm just out of practice, maybe not. Suppose we run a command using system() and this command writes to the stderr stream. If I remember correctly, this is normally written to the...
11
by: snnn | last post by:
On the book <Generic Programming and the STL>( Matthew . H . Austern ),this function is defined as iterator set::begin() const. However, why should a const object returns a non-const iterator?...
0
by: tmartsum | last post by:
I have a discussion in comp.std.c++ After a (bit stupid) suggestion on representing a fixed 'big' length int I moderated it to "Bitfields-ints should be allowed to have any fixed length" I...
30
by: Pep | last post by:
Is it best to include the code "using namespace std;" in the source or should each keyword in the std namespace be qualified by the namespace tag, such as std::cout << "using std namespace" <<...
7
by: Chris | last post by:
Hello all... I have a program with the following structure (all classes mentioned are of my own creation, and none of the classes contain try or catch blocks): - main() consists of a large...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
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...
0
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...
0
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,...

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.