Solved

Why doesn't zorder work in VBA?

Posted on 2004-04-07
4
984 Views
Last Modified: 2012-08-13
Hi,
    I am trying to write a small vba app in Outlook. I want to use an MSH Flexgrid control and a standard combo box. Weird thing is that when i try to draw the combo box onto my form it always disappears behind the MSH  Flexgrid and I need it to appear on top? I've tried bringing the combo forwards/ sending the flexgrid backwards and also setting the zorder of both controls at run-time but still no luck. Am I missing something obvious? Any help is most welcome.

Cheers,
           Dust.
0
Comment
Question by:dustybryn
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 52

Expert Comment

by:Ryan Chong
ID: 10774147
Maybe can try draw a PictureBox Control, and then put your combo box inside the PictureBox ? Just guess it will works..
0
 
LVL 9

Accepted Solution

by:
p_sie earned 150 total points
ID: 10774283
0
 

Author Comment

by:dustybryn
ID: 10774437
Basically what p_sie has said is that it can't be done which although it doesn't help me it has saved me from spending hours chasing red herrings. The conclusion I draw from it is that VBA is a bit naff I'll probably write my app in VB instead.
0
 

Expert Comment

by:GTejeda
ID: 10894152
I know this is a little late, but I just read this and had the same problem.
I fixed it by adding a frame to the form, then adding the combo into the
frame and then displaying the frame. For reasons I do not understand
the frame will show up in front of the grid, not behind.
If the frame is set to have no border and to be the same size as the combo,
you won't see it. Positioning of course then is done by moving the frame,
the combo will always have top=0 left=0.
Hope someone else will find this useful.
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
Introduction While answering a recent question about filtering a custom class collection, I realized that this could be accomplished with very little code by using the ScriptControl (SC) library.  This article will introduce you to the SC library a…
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 process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…

739 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