Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Forms, and group boxes laying

Posted on 2009-04-17
4
Medium Priority
?
270 Views
Last Modified: 2013-12-26
Hi,

I have one form with four group boxes on, each group box has its own set of controls. The group boxes are layered over each other and by default when the form is displayed the first group box is visable and the rest are hidden...

When the user clicks on a "next" button the first group box is visible = false and the second group box is visable= true....

My issue is that when the group boxes are overlapped and I click on "next" to display the seond group box it never gets displayed I am not sure why....

Any thoughts...?




Private Sub btn_next_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btn_next.Click
 
        Me.btn_start.Enabled = False
 
        If (Me.grp_screen1_startdate.Visible = True) Then
 
            Me.grp_screen1_startdate.Visible = False
            Me.grp_screen2_funds.BringToFront()
            Me.btn_back.Enabled = True
 
        ElseIf (Me.grp_screen2_funds.Visible = True) Then
 
            Me.grp_screen2_funds.Visible = False
            Me.grp_screen3_curr.Visible = True
 
        ElseIf (Me.grp_screen3_curr.Visible = True) Then
 
            Me.grp_screen3_curr.Visible = False
            Me.btn_next.Enabled = False
            Me.grp_screen4_process.Visible = True
            Me.btn_start.Enabled = True
 
        End If
 
    End Sub

Open in new window

0
Comment
Question by:ISC
  • 3
4 Comments
 
LVL 1

Author Comment

by:ISC
ID: 24167391
Sorry a correction to the code...

Private Sub btn_next_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btn_next.Click

        Me.btn_start.Enabled = False

        If (Me.grp_screen1_startdate.Visible = True) Then

            Me.grp_screen1_startdate.Visible = False
            Me.grp_screen2_funds.Visible = True
            Me.btn_back.Enabled = True

        ElseIf (Me.grp_screen2_funds.Visible = True) Then

            Me.grp_screen2_funds.Visible = False
            Me.grp_screen3_curr.Visible = True

        ElseIf (Me.grp_screen3_curr.Visible = True) Then

            Me.grp_screen3_curr.Visible = False
            Me.btn_next.Enabled = False
            Me.grp_screen4_process.Visible = True
            Me.btn_start.Enabled = True

        End If

    End Sub
0
 
LVL 1

Author Comment

by:ISC
ID: 24167414
I think it is something to do with the layering of group boxes over each other...
0
 
LVL 1

Author Comment

by:ISC
ID: 24167691
I have sorted it, when I layered the groups boxes over each other they became a group box whithin a group box....

I have resolved by View=>Other Winodws=>Dcoument Outline and ensuing there is no groupbox within another groupbox...

Issue solved..
0
 

Accepted Solution

by:
EE_AutoDeleter earned 0 total points
ID: 24462067
ISC,
Because you have presented a solution to your own problem which may be helpful to future searches, this question is now PAQed and your points have been refunded.

EE_AutoDeleter
0

Featured Post

[Webinar] Cloud and Mobile-First Strategy

Maybe you’ve fully adopted the cloud since the beginning. Or maybe you started with on-prem resources but are pursuing a “cloud and mobile first” strategy. Getting to that end state has its challenges. Discover how to build out a 100% cloud and mobile IT strategy in this webinar.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
This article describes how to use a set of graphical playing cards to create a Draw Poker game in Excel or VB6.
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…
Suggested Courses
Course of the Month20 days, 22 hours left to enroll

810 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question