473,770 Members | 2,133 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Problem with Multi-Project Solution

Hello All,

Yes, I'm back again on this subject.

I've started again to set up the solution and I can, if you like, move
deeper into the program, accessing various forms as I go BUT I cannot for the
life of me work out how to get back. I have set "CommonForm s" in the
Properties/References of StartUp.

Just working with two projects "StartUp" & "CommonForm s" I place a parent
form with child in "StartUp" and one form in "CommonForm s". In the "StartUp"
child form I have the following code:

Public Class OpenSplash

Private Sub Button3_Click(B yVal sender As System.Object, _
ByVal e As System.EventArg s) Handles Button3.Click

Dim FormChild2 As New CommonForms.For m1
FormChild2.MdiP arent = Background
FormChild2.Show ()
Me.Hide()
End Sub
End Class

This closes the OpenSplash screen and shows Form1. How do I close Form1 and
get back to OpenSplash?

With this solved I can move forward, I'm sure.

Best Rgds,
22Pom
Sep 20 '08 #1
8 1167
Try changing:

FormChild2.Show ()
Me.Hide()

to:

Me.Visible = False
FormChild2.Show Dialog()
Me.Visible = True

Does that achieve what you wanted?

"22Pom" <22***@discussi ons.microsoft.c omwrote in message
news:40******** *************** ***********@mic rosoft.com...
Hello All,

Yes, I'm back again on this subject.

I've started again to set up the solution and I can, if you like, move
deeper into the program, accessing various forms as I go BUT I cannot for
the
life of me work out how to get back. I have set "CommonForm s" in the
Properties/References of StartUp.

Just working with two projects "StartUp" & "CommonForm s" I place a parent
form with child in "StartUp" and one form in "CommonForm s". In the
"StartUp"
child form I have the following code:

Public Class OpenSplash

Private Sub Button3_Click(B yVal sender As System.Object, _
ByVal e As System.EventArg s) Handles Button3.Click

Dim FormChild2 As New CommonForms.For m1
FormChild2.MdiP arent = Background
FormChild2.Show ()
Me.Hide()
End Sub
End Class

This closes the OpenSplash screen and shows Form1. How do I close Form1
and
get back to OpenSplash?

With this solved I can move forward, I'm sure.

Best Rgds,
22Pom
Sep 20 '08 #2
You cannot 'close' the main form that starts off the application.
The most you can do is 'hide' it and show it.

Miro

"22Pom" <22***@discussi ons.microsoft.c omwrote in message
news:40******** *************** ***********@mic rosoft.com...
Hello All,

Yes, I'm back again on this subject.

I've started again to set up the solution and I can, if you like, move
deeper into the program, accessing various forms as I go BUT I cannot for
the
life of me work out how to get back. I have set "CommonForm s" in the
Properties/References of StartUp.

Just working with two projects "StartUp" & "CommonForm s" I place a parent
form with child in "StartUp" and one form in "CommonForm s". In the
"StartUp"
child form I have the following code:

Public Class OpenSplash

Private Sub Button3_Click(B yVal sender As System.Object, _
ByVal e As System.EventArg s) Handles Button3.Click

Dim FormChild2 As New CommonForms.For m1
FormChild2.MdiP arent = Background
FormChild2.Show ()
Me.Hide()
End Sub
End Class

This closes the OpenSplash screen and shows Form1. How do I close Form1
and
get back to OpenSplash?

With this solved I can move forward, I'm sure.

Best Rgds,
22Pom
Sep 20 '08 #3
Hi Family Tree Mike,

Sorry mate, no it doesn't. I have tried to use the following code in Form1,
as I have done in a single project solution, but in this case I get the error
"Formchild2 is not declared".

Public Class Form1

Private Sub Button1_Click(B yVal sender As System.Object, _
ByVal e As System.EventArg s) Handles Button1.Click

Dim FormChild2 As New StartUp.Openspl ash
FormChild2.MdiP arent = background
FormChild2.Show ()
Me.Hide()
End Sub
End Class

There is probably a simple way of doing this, like most other problems I've
had in the past, but I cannot work it out.

Best Rgds,
22Pom

"Family Tree Mike" wrote:
Try changing:

FormChild2.Show ()
Me.Hide()

to:

Me.Visible = False
FormChild2.Show Dialog()
Me.Visible = True

Does that achieve what you wanted?
Sep 20 '08 #4
Hi Miro,

I don't want to close off the application with my code I just want to close
the current form and go back to the previous form. I have tried this code
but I get the error that Formchild2 is not declared.

Public Class Form1

Private Sub Button1_Click(B yVal sender As System.Object, _
ByVal e As System.EventArg s) Handles Button1.Click

Dim FormChild2 As New StartUp.Openspl ash
FormChild2.MdiP arent = background
FormChild2.Show ()
Me.Hide()
End Sub
End Class

If I can't overcome this problem then I'm lost. My current Single Solution
project has well over 70 Forms, Modules etc in it and I was advised that the
only real way to develop such a large program was to go to the Multi-Project
Solution.

Best Rgds,
22Pom
"Miro" wrote:
You cannot 'close' the main form that starts off the application.
The most you can do is 'hide' it and show it.

Miro
Sep 20 '08 #5
22Pom wrote:
<snip>
Just working with two projects "StartUp" & "CommonForm s" I place a parent
form with child in "StartUp" and one form in "CommonForm s". In the "StartUp"
child form I have the following code:

Public Class OpenSplash

* * Private Sub Button3_Click(B yVal sender As System.Object, _
* * * * * * * * * * ByVal e As System.EventArg s) Handles Button3.Click

* * * * Dim FormChild2 As New CommonForms.For m1
* * * * FormChild2.MdiP arent = Background
* * * * FormChild2.Show ()
* * * * Me.Hide()
* * End Sub
End Class

This closes the OpenSplash screen and shows Form1. How do I close Form1 and
get back to OpenSplash?
<snip>

I'm not sure if I really understand your setup, but since it seems
Opensplash will be controlling the other forms' lifetime, you could
have a form variable *with events* in Opensplash, so it could know
when the current form closed.

<example>
Public Class OpenSplash
Private WithEvents CurrentForm As Form
Private Sub Button3_Click(B yVal sender As System.Object, _
ByVal e As System.EventArg s) Handles Button3.Click

Dim FormChild2 As New CommonForms.For m1
'***********
CurrentForm = FormChild2
'***********
FormChild2.MdiP arent = Background
FormChild2.Show ()
Me.Hide()
End Sub
Private Sub CurrentForm_For mClosed( _
ByVal sender As Object, _
ByVal e As FormClosedEvent Args _
) Handles CurrentForm.For mClosed

CurrentForm = Nothing
Me.Show()

End Sub
End Class
</example>

Regards,

Branco.
Sep 21 '08 #6
Hi Branco Mendeiros,

I thank you for you code but it operates in the same fashion that I'm
currently using.

My program starts with the OpenSplash screen on a background and the user,
by clicking a button moves forward to screen 2, and this automatically closes
screen 1. So far so good - this I can achieve. What bugs me is closing
screen 2 and returning to screen 1.

This is only the start. I have 4 Product groups which in turn have 5
Products which in turn etc, so as you can see there are a lot of separate
screens. At the moment I have a Single Solution with some 70 odd Forms,
Modules etc ,which works ok up till now. I cannot keep adding forms as this
is causing the program to play up.

I think that I've opened up a massive can of worms with this problem, a
problem that I don't think has come up before.

Thanks for your time.

Best Rgds
22Pom

"Branco Medeiros" wrote:
>
I'm not sure if I really understand your setup, but since it seems
Opensplash will be controlling the other forms' lifetime, you could
have a form variable *with events* in Opensplash, so it could know
when the current form closed.

<example>
Public Class OpenSplash

Private WithEvents CurrentForm As Form
Private Sub Button3_Click(B yVal sender As System.Object, _
ByVal e As System.EventArg s) Handles Button3.Click

Dim FormChild2 As New CommonForms.For m1
'***********
CurrentForm = FormChild2
'***********
FormChild2.MdiP arent = Background
FormChild2.Show ()
Me.Hide()
End Sub

Private Sub CurrentForm_For mClosed( _
ByVal sender As Object, _
ByVal e As FormClosedEvent Args _
) Handles CurrentForm.For mClosed

CurrentForm = Nothing
Me.Show()

End Sub
End Class
</example>

Regards,

Branco.
Sep 21 '08 #7
Hi, 22Pom!

When you say "What bugs me is closing screen 2 and returning to screen
1", what exactly do you mean? Do you want to show "screen 1" again
after closing "screen 2"?

Can you provide more information about what you are trying to
acomplish? Maybe if you clarify that we can find out how to achieve
it.

Regards,

Branco.
On Sep 21, 12:35*am, 22Pom <22...@discussi ons.microsoft.c omwrote:
Hi Branco Mendeiros,

I thank you for you code but it operates in the same fashion that I'm
currently using.

My program starts with the OpenSplash screen on a background and the user,
by clicking a button moves forward to screen 2, and this automatically closes
screen 1. *So far so good - this I can achieve. *What bugs me is closing
screen 2 and returning to screen 1.

This is only the start. *I have 4 Product groups which in turn have 5
Products which in turn etc, so as you can see there are a lot of separate
screens. *At the moment I have a Single Solution with some 70 odd Forms,
Modules etc ,which works ok up till now. *I cannot keep adding forms asthis
is causing the program to play up.

I think that I've opened up a massive can of worms with this problem, a
problem that I don't think has come up before.

Thanks for your time.

Best Rgds
22Pom
<snip>
Sep 21 '08 #8
Hi Branco Medeiros,

Yes that's it. My program starts off with the opening splash screen (1) the
user then moves forward to the next screeen (2) which is where they can
select a product range from a set of (4). Each of these sets has a further
(5) products, and so the process continues until they have reached the
product they want and the selection begins, hence the number of forms.
modules etc in the program, currently stands at 74 with at least another 25
to go.

What I need to be able to do is reverse out of an area reached. This is the
problem. I could attach a copy of what I have but I don't see how I can do
this in this forum. What I will do is post a link to another Forum so you
can see what I have.

Best Rgds,
22Pom

"Branco Medeiros" wrote:
Hi, 22Pom!

When you say "What bugs me is closing screen 2 and returning to screen
1", what exactly do you mean? Do you want to show "screen 1" again
after closing "screen 2"?

Can you provide more information about what you are trying to
acomplish? Maybe if you clarify that we can find out how to achieve
it.

Regards,

Branco.

Sep 22 '08 #9

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

Similar topics

1
2876
by: Chung Jiho | last post by:
Hello, We have been deploying our web application over win2k servers. It is written in Python and uses Active Scripting to meet our requirements that it must be ASP application. So far, it was O.K. But recently we discovered our application doesn't work on Windows 2003 server. Even simple page such as below results in 500 Server Error.
0
1849
by: Atul Kshirsagar | last post by:
I am embedding python in my C++ application. I am using Python *2.3.2* with a C++ extention DLL in multi-threaded environment. I am using SWIG-1.3.19 to generate C++ to Python interface. Now to explain it in details, 1. Python initialization and finalization is done in the *main* thread. 2. For each new thread I create a separate sub-interpreter . 3. Using PyRun_String("import myModule"...) before execution of python
0
3787
by: frankenberry | last post by:
I have multi-page tiff files. I need to extract individual frames from the multi-page tiffs and save them as single-page tiffs. 95% of the time I receive multi-page tiffs containing 1 or more black and white CCITT4 compressed files (frames) inside the tiff. Every now and then I receive a mixture of black and white CCITT4 and JPEG compressed files, and sometimes just multi-page tiffs with JPEG only. The code runs great when dealing with the...
2
4840
by: RipTide | last post by:
Background: Using an unsupported/abandoned multi-user multi-database program that uses Access 97 and Jet 3.5. Program itself appears to have been built with PowerBuilder 6.5. Databases reside on an NT 4 SP6 file server with opportunistic locking disabled. Workstations are Win98 SE with Access 97, Jet 3.5 SP3, and Network redirector file caching disabled (VREDIR/DiscardCacheOnOpen=1) Network: Local LAN using NETBUEI as Primary Protocol,...
2
3039
by: google | last post by:
Hello everyone, I am having an issue using the "Multi Select" option in a list box in MS Access 2003. I am making a form that users can fill out to add an issue to the database. Each issue can be associated with multiple categories. I have an "Issue," "IssueCategory," and "Category" in the database (among other tables). The form has a subform in it which is tied to the "IssueCategory" table. The main form is tied to the "Issue"...
2
9926
by: Chris Plowman | last post by:
Hi all, I was wondering if anyone can help me with a really annoying problem I have been having. I made a derived datagrid class that will select the row when a user clicks anywhere on a cell (multi-select without modifier keys). I got that working fine, but I also wanted to keep rows selected after a sort, which I do by storing the row's id in an arraylist. The idea was to do the sort and then go back and re-select the rows with that...
4
19113
by: snowweb | last post by:
I am trying to implement a CSS hierarchical unfolding menu on a site. The thing is, it needs to be dynamically populated from the results of a database query. I previously had the menu working but then it was ‘hard coded’ and not built on the fly. Menu description: 2 top level items “Company” and “Products” (we will ignore “Company” since it is still hard coded and not causing a problem. Below “Products” we have hard coded “By...
2
1434
by: Diz | last post by:
Can anyone please help with this? when i run the following query, using SELECT*, SELECT * FROM tbl_artwork, tbl_artworkmedium, tbl_medium WHERE tbl_artwork.artworkID = tbl_artworkmedium.artworkID AND tbl_artworkmedium.mediumID = tbl_medium.mediumID AND `dateCreated` =2002 I get more info than i need, (lots of IDs displaying) and type displays oil or watercolour etc. but when i try to get rid of the extra info by running a query...
0
3468
by: pvannie | last post by:
Hello there, I've been trying to install DBD::mysql on Mac OS X Server 10.3 for 2 days, but it still raises error. So I'm going to send this message to ask for help. Any help will be much appreciated. Here is what I've tried to install the DBD::mysql module: 1> Download DBD-mysql-2.9003 and un-zip it 2> cd to DBD-mysql-2.9003 directory
7
5959
by: Adam01 | last post by:
Im not perl expert with perl, and I am trying to run a server script (that I didnt write). And perl reports: Can't locate IO/Compress/Gzip.pm in @INC (@INC contains: /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.7/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.6/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.8...
0
9618
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10260
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10101
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10038
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8933
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7456
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5482
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3609
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2850
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 can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.