473,395 Members | 1,846 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,395 software developers and data experts.

Bizar problem with a form (different instances act like one!)

Hi all,

I have got a really weird problem:
- A normal VB.net forms application
- One MDI child form with a bunch of controls (tabs, radiobuttons, combo's,
etc.)
- The form is called from several procedures as kind of a dialog
- To my knowledge we haven't done anything in the disigner / code which can
be described as unusual

When de form is called multiple time they seem te listen to each others
events! So when I change a combo, the combobox will change on all forms ?!
All instances are created through a new / contructor and to my knowledge no
variables / controls are declared as static.

Does anyone have ever seen this or made this kind of functionality on
purpose?

I better hope it isn't a little switch in de IDE we turned on by accident.

Hope you can help,

Best regards,

Joost van den Berg
Apr 28 '07 #1
2 1012
On Apr 28, 7:52 am, VLNL <V...@discussions.microsoft.comwrote:
Hi all,

I have got a really weird problem:
- A normal VB.net forms application
- One MDI child form with a bunch of controls (tabs, radiobuttons, combo's,
etc.)
- The form is called from several procedures as kind of a dialog
- To my knowledge we haven't done anything in the disigner / code which can
be described as unusual

When de form is called multiple time they seem te listen to each others
events! So when I change a combo, the combobox will change on all forms ?!
All instances are created through a new / contructor and to my knowledge no
variables / controls are declared as static.

Does anyone have ever seen this or made this kind of functionality on
purpose?

I better hope it isn't a little switch in de IDE we turned on by accident.
Can you list the code here that you use to instantiate the form?

Rich
Apr 28 '07 #2
Location A:

Private Sub ToolStripButtonTemp_Click(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles ToolStripButtonTemp.Click

Dim t As New MRC.Forms.FormProbeEdit
t.MdiParent = Me
t.FormMain = Me
t.Show()

End Sub

Location B:

'Create a new form
CurrentEditForm = New MRC.Forms.FormProbeEdit

With CurrentEditForm

'Set owner
.MdiParent = Me.FormMain
.FormMain = Me.FormMain

'Show form
Call .Show()

'Set probe
.Probe = CurrentProbe

End With

As you can see, they both call the constructor.

"Richard Carpenter" wrote:
On Apr 28, 7:52 am, VLNL <V...@discussions.microsoft.comwrote:
Hi all,

I have got a really weird problem:
- A normal VB.net forms application
- One MDI child form with a bunch of controls (tabs, radiobuttons, combo's,
etc.)
- The form is called from several procedures as kind of a dialog
- To my knowledge we haven't done anything in the disigner / code which can
be described as unusual

When de form is called multiple time they seem te listen to each others
events! So when I change a combo, the combobox will change on all forms ?!
All instances are created through a new / contructor and to my knowledge no
variables / controls are declared as static.

Does anyone have ever seen this or made this kind of functionality on
purpose?

I better hope it isn't a little switch in de IDE we turned on by accident.

Can you list the code here that you use to instantiate the form?

Rich
Apr 28 '07 #3

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

Similar topics

1
by: Jonathan LaRosa | last post by:
Anyone know how to do this with javascript? I'm trying to avoid creating two different forms because then changes become that much harder to manage. Thanks in advance . . . ~ Jon LaRosa jlarosa...
0
by: fchef | last post by:
I am looking for some advice on working with Multiple frame instances. Essentially I need to be able to refer to specific control values in a frame and be able to hide/show a specific frame. In VB...
2
by: Che | last post by:
Greetings, I am writing an application that uses an extendible XML file. in order to validate that XML I use a main XSD and in additional - few more extensions XSD's that uses the types in the...
1
by: thomasb | last post by:
When setting up federation between two databases on the same instance everything works fine. When trying to do the same between two databases on different instances on the same machine I get...
5
by: simonmarkjones | last post by:
Hi I'm having trouble writing to an excel spreadsheet. I have the following code Dim strList As String With Me.trainingplan.Form.RecordsetClone .MoveFirst While Not .EOF strList = strList...
5
by: Hendrik Schober | last post by:
Hi, I had originally suspected this to be a bug in the std lib, that's why I started a thred in the STL newsgroup. However, it seems as if it is a compiler bug, so I'm transfering it to here....
4
by: Miguel Dias Moura | last post by:
Hello, i created an ASP.net / VB page with a really big form. Now i want to create 4 pages and in each one i will place 1/4 of the big form. The last page will send all the form values by...
2
by: ezly80 | last post by:
hai... i have problems to connect the jboss server with two different database which is Oracle and Mysql. this two db have same db name example Student. if one of the db corrupt the server can...
16
mikek12004
by: mikek12004 | last post by:
How to copy a table (with the data) from one server to another (the two servers are in different PCs)? Basically if I could move the data to a txt file inthe form of the insert command (like the...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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:
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
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
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...

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.