473,408 Members | 2,832 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,408 software developers and data experts.

vb.net / vs2005

Lo all,

I'm creating a small app - I've added a menu across the top and some other
menu items - one of which is the "About" - I've set this to centerparent yet
everytime I run it - its always about 10pixels in from the top and left of
the main window - is there something else I need to set to achieve this?

Any information would be appreciated.

Regards

Rob
Jan 23 '06 #1
5 1365
Ok - I've resolved that one - showdialogue on the calling function...

Next question! :o)

How do I prevent this little window from being moved around - I want it to
appear in the center of the parent and be stuck there until the user clicks
ok - I've been through all of the properties in the form and cant see
anything obvious - have played with a few - none made any difference.

Any info appreciated.

Regards

Rob
Jan 23 '06 #2

on menu click, all you should need to do is...
dim f as frmAbout
f = new frmAbout

f.MinimizeBox = False 'Hides the minimize button
f.MaximizeBox = False 'Hides the maximize button
f.Locked = true 'prevents the form from being resized or repositioned by the
user
f.StartPosition = FormStartPosition.CenterParent 'centers the form in it's
parent's bounds
f.ShowDialog(Me) 'displays the form, sets it's owner.
"Rob Meade" <te**************@edaem.bbor> wrote in message
news:k_****************@text.news.blueyonder.co.uk ...
Ok - I've resolved that one - showdialogue on the calling function...

Next question! :o)

How do I prevent this little window from being moved around - I want it to
appear in the center of the parent and be stuck there until the user
clicks ok - I've been through all of the properties in the form and cant
see anything obvious - have played with a few - none made any difference.

Any info appreciated.

Regards

Rob

Jan 23 '06 #3
HI Amdrit,

Thanks for the reply.

I have the "locked" property set on the "about" form already but it doesn't
seem to do anything...

Does it make a difference if its set on the actual form, or whether its
declared programmatically when calling the about form etc?

Any info appreciated.

Regards

Rob
Jan 23 '06 #4
Oh, and "locked" doesn't appear when I do this:
Dim About as new About

About.

ie there's no intelliesense for "Locked"...neither is there on the actual
About.vb file - when you look at the properties "Locked" only appears under
"Design" - could it be that this only locks the "design" view, and has
nothing to do with the code/application itself when run?

Regards

Rob
Jan 23 '06 #5
No, the Lock() method is avaible from the underlying windows form base, it
is available at run time. Is this your about box from scratch, do you have
any logic in the resize event, initialize, or form_load events? Create a
new form for the project, call it frmTest and replace the logic for about
with frmTest, do you get the same results?
"Rob Meade" <te**************@edaem.bbor> wrote in message
news:OW***************@text.news.blueyonder.co.uk. ..
Oh, and "locked" doesn't appear when I do this:
Dim About as new About

About.

ie there's no intelliesense for "Locked"...neither is there on the actual
About.vb file - when you look at the properties "Locked" only appears
under "Design" - could it be that this only locks the "design" view, and
has nothing to do with the code/application itself when run?

Regards

Rob

Jan 23 '06 #6

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

Similar topics

3
by: Robert | last post by:
I have an application with custom configuration sections in it's app.config file. Here's a shortened excerpt: <monitors> <monitor...
3
by: Darrin | last post by:
Hello, I see that VS2005 and the new framework 2.0 is out to the public now. Wondering about some things. When you install the new framework 2.0 can a person still use visual studio 2003 or...
9
by: Jeff Gaines | last post by:
I have just installed VS 2005 (MSDN version) and I am having problems coping files to the Projects folder while VS2005 is running. The projects folder is on a network share and I have used...
5
by: GaryDean | last post by:
(my original post was inaccurate but this post accurately describes what I think is a very bad vs2005 bug) short description... Deleting a dataset and recreating it from the dataadapter causes...
10
by: musosdev | last post by:
Hi guys I'm trying to migrate to VS2005... I've managed to do that, but realised I'd opened my web projects as file projects, and I'm getting the error about network BIOS command limit. ...
6
by: Brad | last post by:
I have a win2003 server workstation with multiple webs, each web has it's own ip address. In VS2005, if I select to open an existing web site, select Local IIS, the dialog correctly displays a...
7
by: Frank Rizzo | last post by:
Is it me or is the speed of VS2005 actually slower than VS2003? The startup is pretty bad - even though I changed VS to display an empty environment. When I create a new form and want to change...
9
by: yevvi | last post by:
Hi, We have a product with bunch of dlls which are now built with Visual Studio 2003. We want to switch the build to use VS2005. I have read that in VS2005 runtime libraries come as...
15
by: Joseph Geretz | last post by:
OK, I'll admit it up front - I just don't get it. Here's our previous VS2003 development model. Developers develop the WS solution on their own workstations, using their own IIS web servers...
5
by: Gumby | last post by:
Hi there! A "special" project team in our department has decided to purchase XMLSpy. We standardize on VS2005 as our IDE and up to now everyone has used the XML parser in VS2005. Are there...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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...
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
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
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.