Solved

display hbox in center of datagrid

Posted on 2011-09-06
7
211 Views
Last Modified: 2012-05-12
Hi guys

I have a editable datagrid with one editable column. On KEY_UP event on that editable column i am displaying a HBox. I want to display the HBox on the center of the screen(on top of datgrid). any idea how i can do that?

Is there an attribute on HBox i can use?

thanks
0
Comment
Question by:royjayd
[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
  • 3
7 Comments
 
LVL 29

Expert Comment

by:dgofman
ID: 36492443
How about if you will use

PopupManager API's

http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/mx/managers/PopUpManager.html

PopUpManager.createPopUp(), and PopUpManager.centerPopUp() methods


0
 
LVL 29

Expert Comment

by:dgofman
ID: 36492448
0
 

Author Comment

by:royjayd
ID: 36492975
Ok .Also can I put x and y coordinates in popupmanager . If I want to put the popup at x=10 y=10
is it possible?
Thanks
0
Free eBook: Backup on AWS

Everything you need to know about backup and disaster recovery with AWS, for FREE!

 
LVL 29

Expert Comment

by:dgofman
ID: 36492981
wait , you asking how to put on the center if you want to control yourself do not use centerPopUp API.
Just sen manually x and y
0
 

Author Comment

by:royjayd
ID: 36496260
can you show me an example with setting X and Y for popupmanager?

when i try like this it works
PopUpManager.centerPopUp(dataGrid);  

i want to set x and y coordinates to popupmanager.

thanks
0
 
LVL 29

Accepted Solution

by:
dgofman earned 500 total points
ID: 36499499
Did you try to write a code before asking me?

<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009" 
			   xmlns:s="library://ns.adobe.com/flex/spark" 
			   xmlns:mx="library://ns.adobe.com/flex/mx"
			   width="100%" height="100%" creationComplete="onComplete()">
		<fx:Script>
			<![CDATA[
                import mx.containers.Panel;
                import mx.managers.PopUpManager;
			    

                protected function onComplete():void
                {
                    var panel:Panel = PopUpManager.createPopUp(this, Panel) as Panel;
                    panel.width = 500;
                    panel.height = 400;
                    panel.x = (width - panel.width) / 2;
                    panel.y = (height - panel.height) / 2;
                }

			]]>
		</fx:Script>
</s:Application>

Open in new window

0
 

Author Comment

by:royjayd
ID: 36601937
0

Featured Post

Defend Your Organization from The Greatest Threats

Looking to fill the gaps in your security? Bring together information from the network, endpoint and threat intelligence feeds to really see what's happening in your organization. Join the WatchGuardians in their adventures fighting cyber crime!

Question has a verified solution.

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

Suggested Solutions

First things first - Preparation We need all the part for this install and it's much nicer to have them all on hand when you need them so here's what's required. Download Eclipse 3.5 32 bit (I like the Classic flavour) from here. (http://www.e…
Deploying our service is a grudge match between customer benefits and customer pain. In one corner, rolling out fixes (yay!) and delivering new features (double yay!). In the other corner, training on new features (boo – sounds like work), and chan…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …
This video shows how to use Hyena, from SystemTools Software, to update 100 user accounts from an external text file. View in 1080p for best video quality.
Suggested Courses

734 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