Forms :: Opening Childform Creates New Instance Of ParentForm
Dec 31, 2011
I am in the process of upgrading a VB6 Project to Vb.net. My problem is that when I open a child form in my project from within the Parent form a new instance of the Parent form is created. The code is fairly simple:
frmnewContract.MdiParent = Me
frmnewContract.Show()
View 3 Replies
ADVERTISEMENT
Mar 12, 2011
I am developing an application with VB.net and SQL Express. In my application I have many forms as : some of my forms are :
Mainform
selectmonth_form
Form_report[code]....
Forms load normally and also show all data in form_report. With this code these forms open as new windows, but I want to open windows as child window.
View 1 Replies
Sep 20, 2009
I have a Visual Basic form with a public sub procedure called xecute_Public_User_Defined_Sub_Procedure.I tried to call the sub procedure from the "ParentForm" below but could not.
Dim ParentForm As Form = CurrentTextBox.Parent
If ParentForm IsNot Nothing Then
ParentForm.Execute_Public_User_Defined_Sub_Procedure()
[code].....
View 1 Replies
Dec 8, 2009
I have a form that creates an instance of a New Class. The code is simple so there is no issues with the programming.
I can step through the code on the Main Form without issues. Stepping Into moves from 1 line to the next.
I can't seem to debug the code within the class though. I set breakpoints but "stepping into" doesn't work. The code gets executed, but it doesn't step through each instruction.
I've tried changing many of the options within Tools > Debug with no luck.
I've tried deleting files from bindebug and obdebug.
Not being able to debug my programs.
View 6 Replies
Oct 2, 2009
The Parent has a Tool Strip and on the tool strip is a button that when clicked loads the child, this works fine.But when I set the child form to maximize its title-bar jumps over the Parent tool strip. Pushing it down a bit. I do what this. I would like the child to be completely contained within the Parent including the Parent forms tool strip.
View 6 Replies
May 11, 2011
My application having one mdiform in that form six child forms are there.Switching of one form into anather form blur bars are appearing form at the title of every opened child form.These six child forms are opens in mdiform.how to remove the blue bars are appearing from every opened child form in mdiform.how to remove blue bar are appearing from switching of one childform into anather in mdiform using vb.net?. how to remove these blue bar.
View 1 Replies
Jul 17, 2009
Anyone know of a product/solution that creates web forms on the fly? I want to allow my users to create their own web forms.
View 1 Replies
Jan 9, 2010
I'm working on a project that will create new windows components. (If this is possible). I have made a button that creates new forms when clicked in the MDI container.Now I'm just wondering if someone can figure out a code to make it so when I click a button it creates a new button on the new created form. [code]
View 37 Replies
May 20, 2010
I need to create a new instance of a class that needs a member of the calling class. But i can't pass a reference to the calling class through the constructor.The solution i am looking for is something like this:
Public Class ChildClass
Public Sub New(args)
_MyMember = GetMemberFromCallingClass()
[code]....
I want this to work without having to manually pass any references or variables from the calling class to the new instance of ChildClass.
View 2 Replies
Sep 16, 2010
I have 3 forms, say Form1, Form2, Form3. Form1 has a public method assigning an image to a picture box:
[code]...
The problem is that this code is Opening a new second instance of the first form (Form1), when I see in debug mode and move my cursor over the frmPers variable, It's value is Nothing, altough I am seen it at the screen ¿Why is this? I am loosing my hair after three days trying several forms to do it without any results.
View 2 Replies
Jul 24, 2010
I have an application that has a tabcontrol to handle multiple documents, just like Notepad++. And I also have file association working correctly with it.All I want to do is to make it open the double-clicked file onto a new "codetab" instead of creating a new instance of the program just to open a file.
View 2 Replies
Aug 18, 2010
Hi, I'm working on a program that reads text entered into a textbox and creates a list of items by separating entries by commas. Everything is working fine, except, because I am using an array to store the items in the list, I have a limited number of entries. This is only a problem because, as it is written currently, each comma counts as an individual entry. Therefore, users can enter ",,," for example, and it would use up 3 places in the array.
I'm looking for a way to check to make sure there is text after the comma before adding an entry. I've attempted to use the .substring command to check the character after, which works until it gets to the last character. Because there is no character after that, it will give an error.
Here is my code for extra clarity:
Public Class frmMain
Dim intCounter As Integer 'Stores the # of commas in the string
Dim Messages(49) As MessageProperties
[code]...
View 4 Replies
Apr 20, 2010
When internet explorer open and have it maximized on the screen, and if then goback to my application and then click on menuitem. Which popups a child form. Upon closing child form, parent form loosing its focus and IE show uop on Top of my application. How i can i activate my Application when any child form closed.
View 1 Replies
Nov 26, 2010
i have a MDI application with parent and childforms.
i have a global timer in a module that makes a com search and writes the result to a parentform status strip label.
the problem is that the label do not change.
i have tried the following:
1) on timer.elapsed
parentForm.statusstriplabel.text =...
2) to create a delegate and invoke a parent form function
3) to create and raise an event
although all 3 seened to run the label didn't changed.
the timer was created in a different module than the parentform class for many reasons.
one of them is because i want to access the timer.start , timer.stop from all the childforms
when i tried a local timer to paretform worked perfect but i couidnt start and stop it from the childs
View 2 Replies
Sep 5, 2010
I'm developing this Usercontrol and I want it to capture theParentForm 's WM-Messages.I know how to just Subclass a Form, from the Forms code. Like:[code]But how do I do this from the Usercontrol? In VB6 I would have used code like:[code]All I want is to capture messages from the ParentForm's Window.
View 5 Replies
Jan 23, 2011
I got a question can I make a dll for opening forms?
View 3 Replies
Jul 9, 2009
I'm new to non internet programing. But I got to start somewhere. So i'll try and make this simple I have a MDI parent form with a tab control section. From a link in the toolbar i would like to open a diffrent form in my tab section. This is what I figured out so far if its even close.
[Code]...
View 2 Replies
Apr 10, 2012
on visual basic how can you open random forms? (im doing a quiz with questions on separate forms and would like to open random forms to show the random questions)
View 24 Replies
Nov 13, 2010
Firstly though, I'll have to mention that I'm a relative newcomer to vb.net and don't really know that much about advanced functions.I have my main form which dynamically generates 15 buttons.
Each of these buttons will need to open another form, depending on which form has been assigned to that button in a config file (the config file isn't yet done, as I want to get it working simply by hardcoding the name of the forms for the time being)
The way I have it in my head is that I would assign the form name that needs to be open to the name of the button, if that makes sense....However, I have absolutely no clue how to do it, I've tried a couple of things but to no avail.
Here's my code, and I have no problem changing any part of it if it will help things along, this is just the only way I know how to create dynamic buttons.[CODE...]
View 8 Replies
Feb 22, 2010
I am attempting to find a way to get an existing form to close and re-open (with the controls re-set). If I use a method like
[Code]...
View 4 Replies
Sep 17, 2011
Is there any switch that will allow you to open an application over all the other currently open applications? My problem is getting Explorer to open over all the other currently open applications. Right now, it only opens in the background......
View 5 Replies
Sep 15, 2009
I want to open a VB.net form using a ThreadPool with a maximum of 10 threads. I need to do this because, the form should open based on a live event and i need atmost 10 forms on the desktop at a time. If i open the form on every live event without using a ThreadPool, the desktop will be floaded with many forms. I am using QueueUserWorkItem method of threadpool to queue a method which opens the form. In this queued method, there is form1.show() statement called. But after displaying the form, this method finishes execution and again we have 10 threads available in the system. I somehow want to either keep this method running so that 1 thread is occupied or i want to keep the thread alive till the form1 is closed by the user. I want the 11th form to appear on the desktop, only when any of the existing forms out of the 10 (already on desktop) is closed.
View 2 Replies
May 16, 2012
I have a group of buttons all with different labels. I want to have each of these specific buttons open up the same form, but my problem is when I write the code of form1.show it pops open twenty or so different windows. How to I make one button open just one window?
View 15 Replies
Apr 29, 2010
Over the past months I have been working on small windows forms applications and learning vb as i go along. The aim was to pull these altogether into one big application.
I am now at the stage of pulling these together I have created a new project (called MainMenu) and designed all the buttons and interface. I have added my other projects (SISApp, CURApp) to this project. File > Add > Existing Project. I can see these projects in the solution explorer.
Now my problem. How can show Form2 in the SISApp project when I click ButtonX in the MainMenu project.
I dont just want to show Form2, i want all the functionality and the database connection in form2 to also work etc.
View 1 Replies
Jan 16, 2012
I might be going about this the wrong way, but I'm trying to create a form that will include a single button, for instance "Enter". When "Enter" is clicked, I want the form to then display the contents of form 2, which might include more buttons and/or a textbox, etc. I want to do all this without ever opening or closing a form.
View 3 Replies
Dec 29, 2010
In a MDI application, for opening a form in the MDI, I am using the following code
Private Sub RoleToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles RoleToolStripMenuItem.Click
Dim lobj_ChildForm As frmRole
'Check if form is already open
lobj_ChildForm = Nothing
[code]....
As you can see, I need loopong through all the open child forms.
View 2 Replies
Jun 6, 2011
I have a form which gets populated by 15 buttons dynamically at runtime (these need to be dynamic as there will be a user config file at some point)What I need these buttons to do is to open a specific form when clicked. Which form that opens will be dealt with in the config file.
Public Class frm_MainScreen
Private Sub frm_MainScreen_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim count As Integer
Dim ImageDir As String
[code].....
View 2 Replies
Jul 4, 2011
I have a button on my form. When I click it, I want a form to be opened exactly on the location where the button is.
View 1 Replies
Jul 20, 2009
I am writing a Class Library for a GIS Windows application. The class has a form that I open when I load the dll command in the application. After the form opens the form moves to the back of the GIS Windows application, and I want it to be in front of the GIS Windows application all the time. How can I do this?
View 1 Replies
May 19, 2010
I am making a webbrowser,how to prevent my browser from opening new IE windows. Because what happens is, there are some links that will open new windows and therefore IE comes in place because it is set as default windows browser which I really don't want because my browser looks really bad if it opens links in another webbrowser.I want it to be just a basic browser, it has only one window, and it should navigate within that window. This is because the browser is integrated in a bigger application only for some website applications that are related to this main application.I am using VB.net 2008 Express Edition?
View 9 Replies