473,505 Members | 13,982 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Disabling Main Form

60 New Member
Hi,

I want to have custom dialog box to work like a messagebox, whereby if the custom dialog box is shown, the main form that calls it will still be visible but cannot be clicked or closed until the opened dialog box is closed.

Thanks,
Alan
Apr 5 '07 #1
5 1239
gsgurdeep
94 New Member
Please try this


Declare a variable of custom messagebox (desisngn by u) on class level in ur project.

EX:-
dim message as new custom messagebox



And
on button click or event raise write this code

message.visible=true
me.enable=false.
Apr 5 '07 #2
alan75
60 New Member
if i do that, everything in the form is disabled and buttons grayed out, i dun want that.
Apr 5 '07 #3
ruckus
8 New Member
if i do that, everything in the form is disabled and buttons grayed out, i dun want that.
Why don't you want that? Well, anyway you could have a boolean variable that is false unless the messagebox is up. All of the controls on the form will only be usable if the variable is false.
Apr 6 '07 #4
stlarmon
12 New Member
From Form1 use something like

Dim f As New Form2
f.ShowDialog()

The ShowDialog makes Form2 a Modal Form so Form1 can be seen but not accessed. Hope this helps.
Apr 6 '07 #5
alan75
60 New Member
exactly what i need! thanks!
Apr 9 '07 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

5
5031
by: Lyn | last post by:
Hi, I hope someone can help. I have a main form which mostly fills the Access window. In the bottom half of this form I have a tab control to display various types of data related to the main...
1
1794
by: Jason Galvin | last post by:
I would like to disable the auto-populating feature (remembers form element text between post-backs) when creating a .NET form. I have succeeded in disabling auto-populate by creating my controls...
1
2183
by: Robert | last post by:
I borrowed one of the forms from the MS Access Solutions database and altered it to fit my needs. The form was the 'EditProducts' form where you select a category from a combo which then populates...
11
2206
by: shankwheat | last post by:
I have a function which passes text from txtdebt to debtsbox which works fine. However, I want to add code which examines the value of debtsbox and if any of the values the user entered contain the...
4
12531
by: stpark22 | last post by:
Hello, I've constructed a data entry form in Access 2003 that is bound to two related tables. A subform is embedded into the main form. I enter data for the parent table into the main form and...
1
2987
by: 3338761 | last post by:
I fished through previous posts and found this link to microsoft's site for the code and steps to disable the mousewheel from scrolling through records: ...
3
5150
by: Jim Armstrong | last post by:
Hello all - This is driving me crazy. I have a table called tblClients - very simple, has the following fields: taxID (PK) ClientName SalesName The main form of my application allows a...
3
1163
by: hitesh bhalkiya | last post by:
i want to disable main menu in the mdi parent form when i use any of the child form. what should i do ? in detail any user open any of child form through main menu untill he completes all the steps...
8
10305
by: wassimdaccache | last post by:
Dear Friend Working on access 2007 sp2. My form is consisting from a form and a subform. while i am using the alowedits=no option on the property of the main form it is preventing me to...
0
7216
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
7098
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
7303
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
7471
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
4699
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3187
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3176
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
754
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
407
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

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.