I'm programming using MS VS VC++ 2008 Express (Beta 2) in /Cli pure mode.
I've found the Screen class. With it I can very easily get the count and all
the data on the various Screens attached to a system, whether it be a single
screen or multiple screen system.
I believe the FromControl method of the Screen class can be used to
determine which Screen a Form is on. But I can't find how I can place or
move a Form onto the Screen of my choice (in code).
I looked in MSDN2.com. I can't find a Screen property in the Form class. I
can't find something like a Form's list or an AddForm method in Screen. So I
need help.
[==Peter==] 3 1482
I might be close to an answer here, but I could use some confirmation.
There is something called workingArea in the Screen class. I noticed in it
that my right-screen is listed as having a Left and Right value
corresponding to values as if it is an extension of my left-screen i.e., the
right-screen Left equals the left-screen's Right, and the left-screen's
Right is equal to the sum of the two screen's widths).
So, does this mean if a Form is on the right-screen and I give it NEGATIVE X
coordinates it will appear on the left-screen? Or that if a Form is on the
left-screen and I give large enough X coordinates it will start to appear on
the right-screen?
If this is true, that means a form can be logically on one screen and
visually on the other? That seems wrong somehow...
Am I totally off base here?
[==Peter==]
"Peter Oliphant" <pe********@hot mail.comwrote in message
news:1E******** *************** ***********@mic rosoft.com...
I'm programming using MS VS VC++ 2008 Express (Beta 2) in /Cli pure mode.
I've found the Screen class. With it I can very easily get the count and
all the data on the various Screens attached to a system, whether it be a
single screen or multiple screen system.
I believe the FromControl method of the Screen class can be used to
determine which Screen a Form is on. But I can't find how I can place or
move a Form onto the Screen of my choice (in code).
I looked in MSDN2.com. I can't find a Screen property in the Form class. I
can't find something like a Form's list or an AddForm method in Screen. So
I need help.
[==Peter==]
"Peter Oliphant" <pe********@hot mail.comwrote in message
news:57******** *************** ***********@mic rosoft.com...
>I might be close to an answer here, but I could use some confirmation.
There is something called workingArea in the Screen class. I noticed in it
that my right-screen is listed as having a Left and Right value
corresponding to values as if it is an extension of my left-screen i.e.,
the right-screen Left equals the left-screen's Right, and the
left-screen's Right is equal to the sum of the two screen's widths).
So, does this mean if a Form is on the right-screen and I give it NEGATIVE
X coordinates it will appear on the left-screen? Or that if a Form is on
the left-screen and I give large enough X coordinates it will start to
appear on the right-screen?
Yes.
>
If this is true, that means a form can be logically on one screen and
visually on the other? That seems wrong somehow...
Am I totally off base here?
Well, sort of. There is no "logically on one screen". There is a single
coordinate system in which all screens are placed.
If the left screen starts at X=0, and the right screen starts at X=1024,
then if the Form is one the right screen it will have X >= 1024. To move to
the left screen (or spanning the gap) you'd set X < 1024, not negative X.
Hope this is what you needed to know.
>
[==Peter==]
"Peter Oliphant" <pe********@hot mail.comwrote in message
news:1E******** *************** ***********@mic rosoft.com...
>I'm programming using MS VS VC++ 2008 Express (Beta 2) in /Cli pure mode.
I've found the Screen class. With it I can very easily get the count and all the data on the various Screens attached to a system, whether it be a single screen or multiple screen system.
I believe the FromControl method of the Screen class can be used to determine which Screen a Form is on. But I can't find how I can place or move a Form onto the Screen of my choice (in code).
I looked in MSDN2.com. I can't find a Screen property in the Form class. I can't find something like a Form's list or an AddForm method in Screen. So I need help.
[==Peter==]
Hey Ben,
Yup! Just wanted to be sure before I wrote a lot of code. Thanx again!!!
: )
[==Peter==]
"Ben Voigt [C++ MVP]" <rb*@nospam.nos pamwrote in message
news:7F******** *************** ***********@mic rosoft.com...
>
"Peter Oliphant" <pe********@hot mail.comwrote in message
news:57******** *************** ***********@mic rosoft.com...
>>I might be close to an answer here, but I could use some confirmation.
There is something called workingArea in the Screen class. I noticed in it that my right-screen is listed as having a Left and Right value correspondin g to values as if it is an extension of my left-screen i.e., the right-screen Left equals the left-screen's Right, and the left-screen's Right is equal to the sum of the two screen's widths).
So, does this mean if a Form is on the right-screen and I give it NEGATIVE X coordinates it will appear on the left-screen? Or that if a Form is on the left-screen and I give large enough X coordinates it will start to appear on the right-screen?
Yes.
>> If this is true, that means a form can be logically on one screen and visually on the other? That seems wrong somehow...
Am I totally off base here?
Well, sort of. There is no "logically on one screen". There is a single
coordinate system in which all screens are placed.
If the left screen starts at X=0, and the right screen starts at X=1024,
then if the Form is one the right screen it will have X >= 1024. To move
to the left screen (or spanning the gap) you'd set X < 1024, not negative
X.
Hope this is what you needed to know.
>> [==Peter==]
"Peter Oliphant" <pe********@hot mail.comwrote in message news:1E******* *************** ************@mi crosoft.com...
>>I'm programming using MS VS VC++ 2008 Express (Beta 2) in /Cli pure mode.
I've found the Screen class. With it I can very easily get the count and all the data on the various Screens attached to a system, whether it be a single screen or multiple screen system.
I believe the FromControl method of the Screen class can be used to determine which Screen a Form is on. But I can't find how I can place or move a Form onto the Screen of my choice (in code).
I looked in MSDN2.com. I can't find a Screen property in the Form class. I can't find something like a Form's list or an AddForm method in Screen. So I need help.
[==Peter==]
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Steve |
last post by:
Hi all
Is there a way in which I can get the Form's position on the screen in
pixels? I am having to position another form in relation to an MDI Child
form, so I cannot use the Location property, because the MDI Child is
usually 0,0 (Top left in the parent container) so if I position my other
form in that location it goes to the top left of the entire screen. I have
tried using the overloaded ShowDialog method to make the MDI Child form...
|
by: LRD |
last post by:
Form not refreshing after autopostback unless keyboard or mouse move
Hi,
We created several new ASP.NET C# forms for our intranet. In each form we
use panels for different sections of the form that are visible or not
depending on what the user is doing.
Each particular form.aspx page has a user control on it. This user control
contains the form HTML and the C# code.
|
by: David Lauberts |
last post by:
Hi
Wonder if someone has some words of wisdom.
I have a access 2002 form that contains 2 graph objects that overlay each
other and would like to export them as a JPEG to use in a presentation. I
can do this individually for each graph but this does not help me as I need
both on the same JPEG. I thought I would try an export the form that
contains both but I am having trouble. (My VBA is self taught and a little
knowledge is...
|
by: Martin Dennett |
last post by:
Hi
I'm new to this group so go easy on me!
I currently use a database that has had one constant niggle for a while and
I was wondering if anybody can help sort it out. From an opening screen
there is an option to search for a particular record. The search criteria is
entered into a text box. A form is presented over the top of the opening
screen with the query results and an option is then given for another
search. This results in the...
|
by: Smriti Dev |
last post by:
Hi,
I am creating a form that allows users' to enter dates and times staff are
available for work.
They are 2-3 different types of staff. For example, permanent staff that
work M-F 9-5 pm generally
and then contract and volunteer staff that work on particular days and
timings
I am not sure how to design the form so that users' are able to easily put
the availability of permanent staff
| |
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...
|
by: JeffS |
last post by:
Honest, I scoured the comp.lang.c.faq for this but found nothing. :)
Is there a library function for placing the cursor position in the
console? Or is it something that can only be done with a platform API
call?
I was able to do this in Windows with a Windows.h function, but I want
to also do it on Linux/Unix as well.
I won't ask for a Linux API call that positions the cursor, as that is
|
by: Rajat Tandon |
last post by:
Hello there,
I am relatively new to the newsgroups and C#. I have never been disappointed
with the groups and always got the prompt replies to my queries.This is yet
another strange issue, I am facing. Please please help me to solve this as
soon as possible.
So here we go ...
I am not able to take the screen shot of the windows form based "Smart
|
by: objectref |
last post by:
Hi to all folks,
i have the following problem and i have spent many hours to solve it
but without any result, so, here it is:
Imagine that you have a mdi-child form that has a panel on it, a panel that
it's
height has the value of 3000. The panel also has a vertical scrollbar so i
can
|
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...
|
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,...
| |
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...
|
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,...
|
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...
|
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...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 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 a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |
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
| |