Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Suite Pro
  New Posts New Posts RSS Feed - blank popup window
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

blank popup window

 Post Reply Post Reply
Author
Message
iftekhar View Drop Down
Groupie
Groupie


Joined: 25 June 2007
Location: United Kingdom
Status: Offline
Points: 10
Post Options Post Options   Thanks (0) Thanks(0)   Quote iftekhar Quote  Post ReplyReply Direct Link To This Post Topic: blank popup window
    Posted: 23 February 2010 at 11:26am
Hi,
 
Whenever a popup is displayed with no controls in it a square shaped button like item (a guess the default popup window with no item) pops up. I would expect it to show nothing if there is no item in the popup bar. CAn anybody tell me is there any way to disable this behavior so that no popup is displayed when there is no controls in the popup bar.
 
The image with the most might show the problem.
 
Thanks in advence
 
IAT
Back to Top
moe188 View Drop Down
Senior Member
Senior Member


Joined: 27 March 2006
Status: Offline
Points: 220
Post Options Post Options   Thanks (0) Thanks(0)   Quote moe188 Quote  Post ReplyReply Direct Link To This Post Posted: 26 February 2010 at 10:00am
Hi,
check your code. You are using something similar to:
Set control = .Add(xtpControlPopup, 0, "Icons")
you may want to change xtpControlPopup to xtpControlButton
good luck

Visual Baisc 6 SP6

Windows XP Pro Sp3, Windows 7
Codejock Xtreme SuitePro ActiveX 15.1.3
Back to Top
jpbro View Drop Down
Senior Member
Senior Member
Avatar

Joined: 12 January 2007
Status: Offline
Points: 1355
Post Options Post Options   Thanks (0) Thanks(0)   Quote jpbro Quote  Post ReplyReply Direct Link To This Post Posted: 26 February 2010 at 12:46pm
Or if you want it to be a popup that is only populate with items sometimes, you should set the Enabled property for the Popup Control to FALSE before you have added items to it, and set it to TRUE after you have added items to it.

You could even check the status in the InitCommandsPopup event by testing for the ID of your View control, and then set the Enabled status of your Icons control accordingly.
Product: Xtreme SuitePro (ActiveX) version 16.2.6
Platform: Windows XP - SP3

Language: Visual Basic 6.0 SP6

Back to Top
Aaron View Drop Down
Senior Member
Senior Member
Avatar

Joined: 29 January 2008
Status: Offline
Points: 2192
Post Options Post Options   Thanks (0) Thanks(0)   Quote Aaron Quote  Post ReplyReply Direct Link To This Post Posted: 26 February 2010 at 2:01pm
Hi,
 
I'm not that familiar with Commandbars but I would expect that .AutoHideUnusedPopups = True would hide these kind of popups but it didn't. I looked in HELP file and found:
 
Remarks

When AutoHideUnusedPopups is TRUE, the popup menus behave similar to the Windows Start menu.  If all controls in a popup control are hidden, then the entire popup control will be hidden as well.

 
 
So I was close... but not satisfied... So I tried something else:
 
Dim popupCommandbar As CommandBar
Dim commandBarControl As CommandBarControl
                
Me.CommandBars.OPTIONS.AutoHideUnusedPopups = True
                
Set popupCommandbar = CommandBars.Add("PopupTest", xtpBarPopup)
Set commandBarControl = popupCommandbar.Controls.Add(xtpControlButtonPopup, 1, "Control Item")
       commandBarControl.CommandBar.Controls.Add xtpControlButton, 2, "Popup Item"
       commandBarControl.HideFlags = xtpHideWrap
 

If you comment commandBarControl.HideFlags = xtpHideWrap popup will show empty popupitem but with it, it doesn't. As I said before I'm not that familiar with Commandbars so there's definitely a solution without "workarounds"
 
Maybe there's a Commandbars GURU in this forum who actually knows how to solve this...
 
 
 
 
 
 
               
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2
Language: Visual Basic 6.0

Zero replies is not an option....
Back to Top
jpbro View Drop Down
Senior Member
Senior Member
Avatar

Joined: 12 January 2007
Status: Offline
Points: 1355
Post Options Post Options   Thanks (0) Thanks(0)   Quote jpbro Quote  Post ReplyReply Direct Link To This Post Posted: 26 February 2010 at 5:10pm
I still think changing the enabled status based on whether or not there are children is the way to go - why trick the user into thinking there are some nice icons to see when there aren't? They will point to the menu item, nothing will appear and they will think the app is broken.

I supposed an AutoDisableEmptyPopups option would be nice to automate the process.
Product: Xtreme SuitePro (ActiveX) version 16.2.6
Platform: Windows XP - SP3

Language: Visual Basic 6.0 SP6

Back to Top
Aaron View Drop Down
Senior Member
Senior Member
Avatar

Joined: 29 January 2008
Status: Offline
Points: 2192
Post Options Post Options   Thanks (0) Thanks(0)   Quote Aaron Quote  Post ReplyReply Direct Link To This Post Posted: 27 February 2010 at 3:33am
Hi Jason,
 
You are right about that, would be nice option to have and @iftekhar forget what I replied, I was totally wrong about this
 
 
 
 
 
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2
Language: Visual Basic 6.0

Zero replies is not an option....
Back to Top
jpbro View Drop Down
Senior Member
Senior Member
Avatar

Joined: 12 January 2007
Status: Offline
Points: 1355
Post Options Post Options   Thanks (0) Thanks(0)   Quote jpbro Quote  Post ReplyReply Direct Link To This Post Posted: 27 February 2010 at 12:46pm
Here's a small demo of what I was suggesting:

uploads/20100227_124629_CmdBarDynamicEn.zip
Product: Xtreme SuitePro (ActiveX) version 16.2.6
Platform: Windows XP - SP3

Language: Visual Basic 6.0 SP6

Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.141 seconds.