473,396 Members | 1,799 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.

Position owned form relative to owner form on screen

I would like to show an owned form at a predetermined spot on the screen
relative to the the owner form's position on the screen (example:
frmOwner.Top + 100 and frmOwner.Left + 50). How to do?

Thanks,
Dean Slindee
Nov 20 '05 #1
2 2095
Hi Dean,

Thanks for posting in the community.

First of all, I would like to confirm my understanding of your issue.
From your description, I understand that you wants to display the owned
form at a predetermined spot on the screen.
Have I fully understood you? If there is anything I misunderstood, please
feel free to let me know.

Here I write some code for you, if you have concern on this issue, please
post here.

Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Button1.Click
Dim fm As New Form2
fm.StartPosition = FormStartPosition.Manual
fm.Owner = Me
fm.Top = Me.Top + Int32.Parse(TextBox1.Text)
fm.Left = Me.Left + Int32.Parse(TextBox2.Text)
fm.Show()
End Sub
Best regards,

Peter Huang
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.

Nov 20 '05 #2
Hi Dean,

Thanks for posting in the community.

Did my suggestion help you?
If you have any concern on this issue, please post here.

Best regards,

Peter Huang
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.

Nov 20 '05 #3

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

Similar topics

4
by: Wade Chy | last post by:
Hi All I am in a situation where I have to grant select privileges on tables owned by a different owner to a specific role. I am logged in as system/sysdba. I have created a new role...
2
by: Robert Chan | last post by:
I have a form that is 2000x700 it is meant to be run across two monitors I want to get the mouse position relative to the form not to the screen is there any kind of way to reference the forms...
0
by: Ioannis Demetriades | last post by:
Hi On my main form I have a menu with menu shortcuts and I noticed that when I display a new form as an MDIChild form the shortcuts work fine from within the mdi child form. If however i display...
3
by: Jerry Wei | last post by:
Dear all: I have a problem about how to handle the events. For example, there are two forms, Form1 and Form2. Form2 is owned by Form1 and there is a button,Button1, in Form2. It is no problem for...
6
by: pamelafluente | last post by:
Hi guys I am puzzed (???) with a probably stupid problem (VB2003). I must be doing something dumb ... I want to open a owned form (must *not* be mdi child) over an Mdi Container, when the Mdi...
1
by: John | last post by:
Hi How can I set the left position of a form relative to screen? Thanks Regards
2
by: tony | last post by:
Hello! Assume I catch a double click in a form by using the event handler that forms designer create for me. Now to my question when I double click in the form the event handler is trigged...
3
by: Andrew Hall | last post by:
Hi all Can anyone advise how to get the position of an open form and how to set the position of an opening form within the access window. I have: MA Access97 (because I do not have the funds...
0
by: =?Utf-8?B?SkI=?= | last post by:
I would like to create an owned form that is owned by a modal dialog rather than a modeless form. The idea is the following Dim dlg as new Mydlg with dlg .ShowDialog .Dispose end with ...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
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...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
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,...
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
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...
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.