Removing the upper right default close button of a dialog
Removing the upper right default close button of a dialog
Removing the upper right default close button of a dialog
Removing the upper right default close button of a dialog
Removing the upper right default close button of a dialog
Removing the upper right default close button of a dialog Removing the upper right default close button of a dialog Removing the upper right default close button of a dialog Removing the upper right default close button of a dialog Removing the upper right default close button of a dialog Removing the upper right default close button of a dialog Removing the upper right default close button of a dialog Removing the upper right default close button of a dialog
Removing the upper right default close button of a dialog Removing the upper right default close button of a dialog
Removing the upper right default close button of a dialog
Go Back  Xtreme Visual Basic Talk > > > Removing the upper right default close button of a dialog


Reply
 
Thread Tools Display Modes
  #1  
Old 06-29-2011, 07:43 AM
45minutes 45minutes is offline
Regular
 
Join Date: Jan 2011
Posts: 75
Default Removing the upper right default close button of a dialog


How do you go about doing this? I've disabled the maximise and minimise buttons, but how do I get rid of the close button or disable it without losing the whole windows form boarder. I had a quick look in properties but couldn't find anything to deal with it. Which is a bit odd because I remember seeing it there once before or something similar to it. Thank you.
Reply With Quote
  #2  
Old 06-29-2011, 07:47 AM
DrPunk's Avatar
DrPunkRemoving the upper right default close button of a dialog DrPunk is offline
Senior Contributor

* Expert *
 
Join Date: Apr 2003
Location: Never where I want to be
Posts: 1,403
Default

Me.ControlBox = False
__________________
There are no computers in heaven!
Reply With Quote
  #3  
Old 06-29-2011, 03:57 PM
snarfblam's Avatar
snarfblamRemoving the upper right default close button of a dialog snarfblam is offline
Senior Contributor

Forum Leader
* Expert *
 
Join Date: Apr 2005
Location: USA
Posts: 896
Default

Why would you want to get rid of the close button?
__________________
C# _VB.NET _
Reply With Quote
  #4  
Old 06-30-2011, 03:20 AM
dayan dayan is offline
Newcomer
 
Join Date: Jun 2010
Posts: 1
Default

I usually set the formboaderstyle to none.
Then you can design you own form.
Reply With Quote
  #5  
Old 06-30-2011, 06:56 AM
45minutes 45minutes is offline
Regular
 
Join Date: Jan 2011
Posts: 75
Default

Quote:
Originally Posted by dayan View Post
I usually set the formboaderstyle to none.
Then you can design you own form.
I did this for my forms but not for my dialogs (I have too many dialogs)
Reply With Quote
  #6  
Old 06-30-2011, 11:20 PM
45minutes 45minutes is offline
Regular
 
Join Date: Jan 2011
Posts: 75
Default

Quote:
Originally Posted by DrPunk View Post
Me.ControlBox = False
Tried it, didn't work. I put it in form load event sub for the dialog.
Reply With Quote
  #7  
Old 07-01-2011, 02:01 AM
CodeCruncher CodeCruncher is offline
Junior Contributor
 
Join Date: Jul 2006
Posts: 355
Default

Quote:
Originally Posted by 45minutes View Post
Tried it, didn't work. I put it in form load event sub for the dialog.
Select the Form you are trying to alter, so the properties come up and try it again this time change the "ControlBox" property in the "Properties" pane window (normally on the right of your VB screen) from "True" to "False" and it dissapears even without typing or running code.
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump

Advertisement:





Free Publications
The ASP.NET 2.0 Anthology
101 Essential Tips, Tricks & Hacks - Free 156 Page Preview. Learn the most practical features and best approaches for ASP.NET.
subscribe
Programmers Heaven C# School Book -Free 338 Page eBook
The Programmers Heaven C# School book covers the .NET framework and the C# language.
subscribe
Build Your Own ASP.NET 3.5 Web Site Using C# & VB, 3rd Edition - Free 219 Page Preview!
This comprehensive step-by-step guide will help get your database-driven ASP.NET web site up and running in no time..
subscribe
Removing the upper right default close button of a dialog
Removing the upper right default close button of a dialog
Removing the upper right default close button of a dialog Removing the upper right default close button of a dialog
Removing the upper right default close button of a dialog
Removing the upper right default close button of a dialog
Removing the upper right default close button of a dialog Removing the upper right default close button of a dialog Removing the upper right default close button of a dialog Removing the upper right default close button of a dialog Removing the upper right default close button of a dialog Removing the upper right default close button of a dialog Removing the upper right default close button of a dialog
Removing the upper right default close button of a dialog
Removing the upper right default close button of a dialog
 
Removing the upper right default close button of a dialog
Removing the upper right default close button of a dialog
 
-->