Resources Related To Hiding And Showing A Windows Form
Feb 25, 2011
I have a form which has a picturebox and after clicking on a button another form will appear with a picture box containing the exact same picture. I use this line of code:Image1.Image = vImage.Image..The thing is after I do this i need to hide the form and show it again to be able to see the changes.[code]
View 1 Replies
ADVERTISEMENT
Mar 21, 2011
I'm having an issue with my app where IE will get brought to the front of the screen when I am switching between forms. Basically I have a form with the man menu which consist of a few command buttons that will start up another form once a user clicks on the button. I do not want the users loading up multiple forms in my application, so once they load one form I end up hiding the main form. So my code looks as shown below when a button is clicked.
[Code]...
View 6 Replies
Jul 5, 2009
basically i have a form with loads of controls. So many infact it stretches the whole hieght of my screen.I only need half these showing since the rest are just a sort of 'log'I have seen ti done loads, that only the controls i want to show at start up are displayed then when some one hits a little button in the bottem it expands the rest leaving them showing to.
View 9 Replies
Sep 13, 2010
It is times like these that I miss the old VB6 language I wish I could hide the current forn and show another form which - this is the important thing - to be on the same level that the previous form was . You see , I used to use this code :
Me.Hide Form2.Show However , sometimes in VB .NET this does not work the way I want it to . You see , the current form does get hidden and Form2 is shown indeed ; however , Form2 is shown somewhere in the background . If there are other programs opened at that time , then Form2 is shown behind all those programs , that's what I mean by saying I want it to be shown in the same level as the previous form was the only way out , I found , was to reverse the code :
Form2.Show Me.Hide In this way Form2 is successfully shown right where the previous form was shown (above the other programs) but in some cases this also is not pleasant because it might take some time for Form2 to load while at the same time the previous form is still visible on the screen and therefore for a slight time both forms are shown one over the other , which is surely not nice . That's why I still want to first hide the first form and later show Form2 .
View 17 Replies
Nov 19, 2009
I have a vb.net program that opens up an excel workbook and runs a macro ("Report") in that workbook when a button is clicked. [code]...
View 1 Replies
Sep 8, 2011
As part of a new program, I need 2 forms and an openfiledialog. On Form1, a button event opens Form2. Form2 has an openfiledialog triggered by a button shown below.
'Form1's button to open Form2
Private Sub Button1_Click(sender As System.Object, e As System.EventArgs) Handles Button1.Click
[Code].....
View 13 Replies
Oct 11, 2009
I was just googleing this, and i came across this
Dim p As New System.Diagnostics.Process
p.StartInfo.WindowStyle = ProcessWindowStyle.Hidden
p.StartInfo.CreateNoWindow = True
p.StartInfo.UseShellExecute = True
p.StartInfo.FileName = "cmd.exe"
p.Start()
Does that mean that i could show it again? if so, is there a code that can do this?Also, if i wanted to get the window that the user is currently in, how would i be able to hide that?
View 16 Replies
May 4, 2010
When my login screen loads, if the user has not created an account the form will close and a form to create an account will appear. However when I code this both forms stay visible, instead of just the one. Where am I going wrong?[code...]
View 6 Replies
Mar 11, 2009
I've just upgraded from Visual Basic 6 to Visual Basic 2008 Express Edition.
1. Show anothor form (ie. Form2)
2. Close Form1.
At present when I use the me.form1 , but both Form1 and Form2 both closes.I would like to press a button or on a timer, to show Form2, while closing Form1.
View 4 Replies
Jul 29, 2010
I am trying to show or hide tabpages as per user choice. If user selects gender male then form for male in a tabpage "male" should be displayed and if user selects female then similar next form should be displayed in next tab "female"I tried using
tabControl1.TabPages.Remove(...)
and
tabControl1.TabPages.Add(...)
It adds and removes the tabpages but doing so will loose my controls on tabpages too... i can't see them back. what's the problem here?
View 3 Replies
Dec 26, 2011
The idea is simple, if I have a string value "ABCD" then with a ButtonClick event it should randomly reveal a char while others are hidden. i.e, "B*" another click would "AB**" and so on. So far, my I have been stuck in a for loop.
[Code]...
View 2 Replies
Apr 25, 2010
I'm trying to search through all tabs to find a specific text. if the text is found, the tab will be hidden, or shown.
I tried this to hide:
btnHide
Dim txt As Object
Dim tabp As TabPage
For Each tabp In TabControl1.TabPages
[Code].....
View 8 Replies
May 20, 2010
I have a form that searches a db. Some searches will always result in one row of data, others might return multiple rows. I want to have the data from a single row shown in text boxes and the multiple rows show in a datagridview is it possible to hide/show those depending on the amount of rows.
View 6 Replies
Feb 16, 2012
I am using a MDI parent to house each of the forms in my application. I have a main form and 2 sub forms. The sub forms are opened using the code below. Also, when I am finished entering info into these forms, i am hiding them so that I can reopen them with the same info still entered.
The problem is that when i show the form again, it is blank. Why would this be the case? I am never closing or disposing the form, so shouldn't it just unhide easily?Showing the sub-form(savingsfrm1) and and hiding the main form(riskfrm1)Public savingsfrm1 As Savings
Private Sub Button1_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
[Code]...
View 1 Replies
Mar 31, 2009
I have a form e.g. Form1 , which displays a datagridview.
1) On form load, the datagridview doesn't have any data
2) The user clicks on a button called filter, this opens a form where the user can specify parameters to filter the data by
3) This form calls a setData() in Form1, which fills the dataset with the data
This works fine. If I click on a button called controlPanel it launches another form and hides this. E.g.
dim cp as new ControlPanel()
this.hide()
cp.show()
On the controlpanel I have a button that links to form1. If I click on it. E.g.
dim frm as new Form1()
this.hide()
frm.show()
It redisplays Form1 but without any data in the datagridview.
I think the problem is that since I am creating a new instance for Form1 it comes up with the blank Form1. Is there a way to redisplay Form1 so that it retains the data that was displayed last, without having to retrieve the data from the database.
View 1 Replies
Jan 8, 2010
I've embedded a form into another form by changing the Top Level property. My problem is that the new implementation does not allow me to edit the DataGridView at runtime. Here's the code I'm using from my main form:
Dim f As New form2()
f.TopLevel = False
Me.Controls.Add(f)
f.Show()
f.showRows()
f.showDbvHeader()
When I call the two methods on the onload event in form2 they run OK for the remainder of the event but as soon as it ends, the DGV reverts back to default.
View 2 Replies
Jun 10, 2011
Iam using vb 2005,sqlserver 2005,vb.net web application in my datagrid properties window not showing the rowcommand. I need create row command/.
View 1 Replies
Feb 10, 2011
Can anyone with more experience with User Controls see what I've done wrong here? The mouse cursor disappears as soon as the user enters the area of the Form although MouseMove, MouseEnter and MouseLeave event handlers are firing correctly. I want an overridden custom cursor to appear on the form with a reticle such as occurs here in this image as per the code listed below and in a
VS2010 solution on SkyDrive.
Option Explicit On
Option Strict On
Imports System.Drawing
[Code]....
View 6 Replies
May 7, 2010
Showing and Hiding Forms from a Console Application causes "Cross-thread operation not valid."
View 1 Replies
Nov 20, 2009
I saw an application for cashier system in a certain store. I noticed that while the application was running, the window form of their application occupies the entire screen and the windows taskbar seems to be hidden. I'm just curious how did they hide the windows taskbar? Do they hide the taskbar in a manual settings on their computer before the application was launched? If not, how did they make their application capable of hiding the taskbar? Please put a detail code if applicable. I just want to know how to hide the taskbar when you launch the application and put it back when you exits the application as well.
View 4 Replies
Aug 2, 2011
I saw an application for cashier system in a certain store. I noticed that while the application was running, the window form of their application occupies the entire screen and the windows taskbar seems to be hidden. I'm just curious how did they hide the windows taskbar? Do they hide the taskbar in a manual settings on their computer before the application was launched? If not, how did they make their application capable of hiding the taskbar? I just want to know how to hide the taskbar when you launch the application and put it back when you exits the application as well.
View 2 Replies
May 21, 2009
I'm wanting to start some vb.net programming related entirely to msn/windows live messenger My first and only question is... is it possible to write and create messenger bots in vb.net and if so also have the feature for manual text feed...
View 2 Replies
Aug 16, 2010
I have three forms: A, B and C. Upon a button being clicked, A displays B. Similarly, B displays C. Both using the ShowDialog() method.
However when I use the Hide() method (inside a Button Click event) on form C to close it, form B also closes. Why would this be? As far as I can see, it shouldn't be doing this. I certainly didn't write any code to tell it to do that.
[Code]...
UPDATE: I am an idiot. DialogResult was set to Cancel on the button as I'd copy+pasted it from the existing Close button and not realised that property was set
View 3 Replies
Dec 3, 2010
I am working on a project in VB.net 2008. I have a problem arising while opening a form as modal from a modeless form. I have attached a project to demonstrate the problem. This demonstration contains three forms with following characteristics. [code]...
View 3 Replies
Feb 18, 2012
Dim Result As Integer
Result = MessageBox.Show("Question...", "Key", MessageBoxButtons.YesNoCancel, MessageBoxIcon.Question)
[code]....
View 1 Replies
May 1, 2012
I have a log in form, and once you log in, it's supposed to show a new form.
The problem here is...if I use Me.Close(), then both of the forms close, and the application terminates.
If I use Me.Hide(), than the first form doesn't actually stop running in the memory, and proceeds to run in the background even after you're done with the program.
View 3 Replies
Jun 8, 2011
I am learning VB.NET and as a first task I am creating a login form. I've been trying to link it to another form once a correct username and password are entered. However, despite that I still cant be able to hide it or unload it once the next form is loaded.
Here is the Code
Private Sub OK_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles OK.Click
If UsernameTextBox.Text = "chris" And PasswordTextBox.Text = "chrispass" Then
Me.Hide()
Form2.Show()
End If
Me.Close()
End Sub
The Form2 appears as coded above but the 'Me.Hide()' manages to hide the login form but then it appears again.
View 2 Replies
May 1, 2011
I am working on a project where I need to hide the mouse however the Cursor.hide and the ShowCursor API (Which doesn't even work) will only hide the cursor on a specific form. How would I go about hiding the mouse everywhere? (Desktop/Internet Browsers/etc...)
View 2 Replies
Dec 19, 2010
I have a small app with one form (form1) which is supposed to be hidden until a hot key combo is pressed. I have read and taken sample code from: [URL]. I do have a keyboard class that hooks keyboard input, (I have my reasons) but it's odd that it will recognise the first hotkey and fire the event, but none after that? The problem is, I can make the form show, but not hide again. It will only recognise one shortcut, one time. How do I make it respond to another hotkey combo? Is the handle changing? Even with focus, the enabled form is not hiding again.
View 4 Replies
Jan 28, 2010
i am hiding a form and showing another form by this bit of
form1.show()
form2.hide()
form 2 contains of a dgv and by the form1 i am editing the contents of the dgv present in the form 2.......
after making the changes when again i show the form2 and hide the form1,then the changes made did not appears in the form2............
i have this bit of code at the form load of the form2:
con = New OleDbConnection("Provider=Microsoft.Jet.Oledb.4.0;Data Source=LibraryManagement.mdb")
con.Open()
[Code]....
now when i close my application and again reload it then then changes that i made appears in the dgv of the form2........
if i am showing the hidden form then at the time of showing it,does the form load event of the hidden form is raised?
or,
the hidden form is already loaded and there is NO form load event and only the form is shown and hidden...
View 3 Replies