Solved

Why doesn't zorder work in VBA?

Posted on 2004-04-07
4
981 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 51

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

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
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…

761 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