?
Solved

Alignment in MDI (StatusBar and PictureBox)

Posted on 2001-07-03
9
Medium Priority
?
368 Views
Last Modified: 2012-06-21
I have some trouble with the alignment of a statusbar and a picturebox that I have in an mdiform. In Visual Basic I place the statusbar below the picturebox. The are both aligned 'bottom'. When I run the program and do

statusbar.visible = false
statusbar.visible = true

I get the statusbar above the picturebox. How can I get it back below the picturebox?
0
Comment
Question by:kpnkpn
9 Comments
 
LVL 3

Expert Comment

by:nigelrowe
ID: 6248469
Have you tried the ZOrder property?
0
 
LVL 3

Expert Comment

by:nigelrowe
ID: 6248495
Don't bother with that it doesn't work. Thats an interesting problem, I see what you mean. Still working on it.
0
 
LVL 54

Accepted Solution

by:
Ryan Chong earned 80 total points
ID: 6248503
Hi kpnkpn,

nigelrowe have the credit.

Here is the sample:

Private Sub status_Click(Index As Integer)
    If Index = 0 Then 'Show Status Bar
        StatusBar1.Visible = True
    Else 'Hide Status Bar
        StatusBar1.Visible = False
    End If
    StatusBar1.ZOrder 0
End Sub
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 
LVL 3

Expert Comment

by:nigelrowe
ID: 6248504
Bingo!!!!

Send the Picture Box to the back in design time...

.Format
..Order
...Send to Back
0
 
LVL 3

Expert Comment

by:nigelrowe
ID: 6248516
ryancys, thanks for your sportsmanship
Best regards, Nigel

P.S.
Oh yes, the reason it didn't work for me was because I used...
StatusBar1.ZOrder = 0

which threw an error. In any case either of the two solutions works.
0
 

Author Comment

by:kpnkpn
ID: 6248689
Hi!

Thankyou very much for the answers. Now I have another problem. Can I accept more than one comment as answer? It's because nigelrowe asked me if I had tried the zorder(). In fact I had. But I didn't get it to work. Then ryancys posted an example and that helped me. Hm... Which answer do you want me to accept?
0
 
LVL 3

Expert Comment

by:nigelrowe
ID: 6248770
It depends on you. Personally I would use...

.Format
..Order
...Send to Back
In design time, as this eliminates a line of code being run during runtime.

Yes there is a way to split the points, but I'm not sure how to do it, perhaps ryancys can shed some light on this.

Regards
0
 
LVL 43

Expert Comment

by:TimCottee
ID: 6248789
kpnkpn, to split the points, you need to post a zero point question in community support http://www.experts-exchange.com/jsp/qList.jsp?ta=commspt and give the url of this question and the distribution of points you require. Say 10 points each (or whatever you feel is appropriate).
0
 

Author Comment

by:kpnkpn
ID: 6249581
No way I split the points that silly way. A waste of time. I give the points to the comment that helped me.
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

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…
When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Suggested Courses

864 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