How to code enforcement for Playbook
Hello
I am new to action script Adobe AIR.
I wanted to create an application in the following flow
--> login screen (if correct)--> screen--> details for the item selected in the option list
|
---> (so bad) user alerts the reconnection
I am able to get the login screen by using the Connect dialog box, but cannot go further than I can not retrieve any data or detect an event. I don't know how to go further.
Any help is very appreciated.
Thank you
Afonso
Here's the code so far
package { import flash.display.Sprite; import flash.events.Event; import flash.events.MouseEvent; import qnx.dialog.*; import qnx.display.IowWindow; import qnx.ui.buttons.LabelButton; import qnx.ui.text.*; public class Details extends Sprite { public function Details() { super(); // support autoOrients //stage.align = StageAlign.TOP_LEFT; //stage.scaleMode = StageScaleMode.NO_SCALE; var login:LoginDialog = new LoginDialog(); login.title = "Device is locked"; login.message = "Please enter your username and password:"; login.addButton("Login"); login.addButton("Cancel"); login.passwordPrompt = "password"; login.rememberMeLabel = 'Remember me'; login.rememberMe = true; login.dialogSize= DialogSize.SIZE_LARGE; login.addEventListener(Event.SELECT, loginButtonClicked); login.show(IowWindow.getAirWindow().group); } public function loginButtonClicked(event:Object):void { /*NO IDEA WHAT TO DO HERE*/ } } }
With the following change, your code works very well here. (Where did you get the idea that you should receive an object instead of the event?)
public function loginButtonClicked(event:Event):void { trace("login", event.target.username); trace("password", event.target.password); trace("remember?", event.target.rememberMe); }
Output trace looks like this:
login peter password foobar remember? true
Tags: BlackBerry Developers
Similar Questions
-
How the code orientation for flash pro mobile app?
Hello
I would like to know how to do coding for orientation and text slides up/down of mobile app created with flash professional.
Thank you
AFM
Flash for Mobile orientation is in the descriptor XML apps. It has always been relatively the same since the beginning. This is a simple article about it:
http://www.Adobe.com/devnet/flash/articles/screen_orientation_apis.html
In what concerns the text by dragging upwards or downwards, in Flash it will always be the same. Position x / y and move it along the same x / y, the same things you've always done. Nothing is different from the original Flash about the scene as much as goes mobile.
-
How thumb code scroller for images, set its different widths and heights uniformed?
I am pile trying to organize the images of variable width to be evently spacer of xml file in the thumb wheel.
I probably miss something in this code sigment:
function resizeMe(mc:DisplayObject,_maxH:Number,_maxW:Number=0,_constrainProportions:Boolean=true,_centerHor:Boolean=true,_centerVert:Boolean=true):void {}
maxH = maxH == 0? maxW: maxH;
MC. Width = maxW;
MC. Height = maxH;
If {(constrainProportions)
mc.scaleX < mc.scaleY? mc.scaleY = mc.scaleX: mc.scaleX = mc.scaleY;
}
If {(centerHor)
MC.x = (maxW - mc.width) / 2;
}
If {(centerVert)
MC.y = (maxH - mc.height) / 2;
}
}
Currently, my images appear to be resolved on a uniform width with any height would be proportional to the width defined in uniform. I also have equal distance between images.
How to make my images have an equal distance, in uniform in height and regardless of the width would be proportional to the height defined in uniform.
Here's the code in its entirety:
import com.greensock;
com.greensock.easing import. *;
//////////////////////////////////////
Load the xml
var xmlLoader:URLLoader = new URLLoader();
Parse XML
var xmlData:XML = new XML();
var xmlPath:String = "app_thmbs_imgs.xml";
xmlLoader.load (new URLRequest (xmlPath));
trace ("loading xml from:" + xmlPath);
xmlLoader.addEventListener (Event.COMPLETE, LoadXML);
function LoadXML(e:Event):void {}
trace ("loading xml complete");
xmlData = new XML (e.target.data);
trace (XMLDATA.image); Let's see each xml element of picture in Panel output with this xmlList
buildScroller (xmlData.image); rather than trace the xmlList, send it to our buildScroller function
}
Build a Scroller MovieClip to hold each Image
var scroller: MovieClip = new MovieClip();
this.addChild (scroller);
scroller.y = 30;
/////
Parse XML
build the scrolling of a xml file
function buildScroller(imageList:XMLList):void {}
trace ("' generation Scroller '");
for (var point: uint = 0; point < imageList.length (); ++ item) {}
var thisOne:MovieClip = new MovieClip();
thisOne.x = (140 + 20) * point;
thisOne.x = currentX; modified line to adjust variable inch widths
thisOne.itemNum = item;
thisOne.title is imageList [item] .attribute ("title");.
thisOne.link is imageList [item] .attribute ('url');.
thisOne.src is imageList [item] .attribute ("src");.
thisOne.alpha = 0;
trace (thisOne.itemNum, thisOne.title, thisOne.link, thisOne.src);
Loading and adding Images
container image
var thisThumb:MovieClip = new MovieClip();
Add images
var ldr:Loader = new Loader();
var url: String = imageList [item] .attribute ("src");
var urlReq:URLRequest = new URLRequest (url);
trace ("thumbnail loading" + item + "in Scroller:" + url);
assign events to charger headphones
ldr.contentLoaderInfo.addEventListener (Event.COMPLETE, completeHandler);
ldr.contentLoaderInfo.addEventListener (IOErrorEvent.IO_ERROR, errorHandler);
LDR. Load (urlReq);
thisThumb.addChild (ldr);
thisOne.addChild (thisThumb);
create listeners for that inch
thisOne.buttonMode = true;
thisOne.addEventListener (MouseEvent.CLICK, clickScrollerItem);
thisOne.addEventListener (MouseEvent.MOUSE_OVER, overScrollerItem);
thisOne.addEventListener (MouseEvent.MOUSE_OUT, outScrollerItem);
Add article
scroller.addChild (thisOne);
}
trace ("termination of construction scroller");
}
function clickScrollerItem(e:MouseEvent):void {}
trace ("item clicked" + e.currentTarget.itemNum + "-visit url:" + e.currentTarget.link);
}
function overScrollerItem(e:MouseEvent):void {}
trace ("Over" + e.currentTarget.title);
}
function outScrollerItem(e:MouseEvent):void {}
trace ("out" + e.currentTarget.title);
}
function completeHandler(e:Event):void {}
trace ("thumbnail full" + e.target.loader.parent.parent.title)
TweenMax.to (e.target.loader.parent.parent,.5, {alpha: 1});
image size to scroll
resizeMe (e.target.loader.parent, 140, 105, true, true, false);
}
function errorHandler(e:IOErrorEvent):void {}
trace ("thumbnail error =" + e);
}
The resizing function
parameters
required: mc = the movieClip to resize
required: maxW = the size of the box to resize, or just the desired maximum width
Optional: maxH = if you want to resize area is not a square, the maximum height. by default must match maxW (so if you want to resize to 200 x 200, just send resizeMe (image, 200) or once 200 ;)
Optional: constrainProportions = boolean to determine if you want to limit the proportions or tilt the image. set to true by default.
Optional: centerHor = centers the displayObject in maxW region. set to true by default.
Optional: centerVert = centers the displayObject in maxH region. set to true by default.
function resizeMe(mc:DisplayObject,_maxH:Number,_maxW:Number=0,_constrainProportions:Boolean=true,_centerHor:Boolean=true,_centerVert:Boolean=true):void {}
maxH = maxH == 0? maxW: maxH;
MC. Width = maxW;
MC. Height = maxH;
If {(constrainProportions)
mc.scaleX < mc.scaleY? mc.scaleY = mc.scaleX: mc.scaleX = mc.scaleY;
}
If {(centerHor)
MC.x = (maxW - mc.width) / 2;
}
If {(centerVert)
MC.y = (maxH - mc.height) / 2;
}
}
You want to set the height of a specific value... it should be as simple as
MC. Height = a specific value
mc.scaleX = mc.scaleY; This will make the width proportional to the new height adjustment
but it must be done after the image is finished loading
as regards the addition with a uniform spacing goes, you must determine where the right edge of the last image and add the space betwwen to set the location of the one currently being added. If you add that these s mc to a container movieclip, then the width of the container must be data very useful to determine where is the right edge of the last mc.
-
OK, so the App World just opened memory, app for playbook. It of great, but didn't I need to sign my build before I submit? How do I get signing keys? Also, did anyone out there jamming? If so, what tools do you use.
Thank you
Hey,.
agreed. My fear of the terms for the playbook if there are too many applications for a single category, they start to ignore the rest. but I guess time will tell.
@streak81: what about code signing. According to the following forum post they currently accept UNSIGNED AIR applications:
that the bid starts!
-
ICloud Keychain how can I change the phone number needed to verify the code text for me? The number it was sent is an old phone number of my friends that I do not have access to the.
Try this from another thread I saw.
On iOS, go to settings > iCloud > keychain and tap button to disable iCloud keychain. (you will be asked to delete or keep the passwords on device) I chose to delete...
Then turn it back on, and pop - up chose reset iCloud trousseau, on a chosen pop-up confirmation reset
In the new window pop up use iPhone password like iCloud cryptogram? has chosen the use code
Enter your secret code (4 digits) then choose country and your new phone number
Although, to "Restore the iCloud Keychain," I took to erase the data and essentially set up a new keychain. Not the case. Strangely, after essentially bypassing the security system, setting a new password and verification number, I see my cards, passwords and other data have been restored. Maybe it's all the iCloud account and this master password. Or maybe it's a bug. With Apple, we'll never know.
Also have a look here: get help using iCloud Keychain - Apple Support
-
Pavilion a6230n: How can I get the product code (UPC) for an HP computer?
Hello, I'm selling an old HP desktop that I hang out on Amazon.
But in order for me to post on Amazon, I need to create a new list, since nobody else is for sale. To create a new list, I need a product code unique for the desktop computer. I'm looking for the Universal Product Code (UPC). A UPC code is the bar code that would be tested at the point of sale when someone buys something.
I have a few other computers, I'm trying to sell, and on the site Web of Toshiba, the first manual I opened a laptop shows me the UPC. HP manuals don't.
I tried to call customer service. And both times I'm hung up or disconnected. It's very frustrating because I have a very basic question, and does not have I gotten a response yet.
If someone can find the UPC for HP Pavilion a6230n and tell me how to get the Cup for HP products in the future, I would be very happy. Thank you!
Hello @RYoder15,
There is not much else I can suggest. I tried at length to see if I could find anything in what concerns this information without success. Maybe if you are able to find the product packed in the store? I was able to find the product on Amazon here: HP Pavilion a6230n desktop PC
I hope this helps.
Kind regards!
-
How to get the code produced for my Windows XP disc if I have the drive?
Acquisition of Product Code Windows XP
How to get the code produced for my Windows XP disc if I have the drive? I signed the BONE when I bought it all first, but have no way of knowing if this is the way to receive a copy of the product key.Here are some utilities, which will display your product keys:
Belarc Advisor: http://www.belarc.com/free_download.html
(He did a good job of providing a wealth of information.
However may not detect a key to office, then try one of the other two below)Also: http://www.nirsoft.net/utils/product_cd_key_viewer.html
and: http://www.magicaljellybean.com/keyfinder.shtmlPaid (free demo is available): Recover Keys: http://recover-keys.com/
"quickly scans your system for more than 3000 + software '.
and produces a list of software activation keys.13 keyfinder programs:
http://pcsupport.about.com/od/productkeysactivation/TP/topkeyfinder.htmJ W Stuart: http://www.pagestart.com
-
How to find parts for my wifi code
How to find parts for my wifi code? I bought an external usb wifi. I don't know how to find the area code for it.i have these options in its settings.
Hello
Please let us know which external USB Wifi are you referring to?
I suggest you to contact the manufacturer or look at the manual for assistance on the issue.
Let us know if you need help on the issue. We will be happy to help you.
-
How to fix code 39 for cd/dvd-rom readers
How to fix code 39 for cd/dvd-rom readers
Here the answer -
How can I know what my redemption code is for photoshop elements?
How can I know what my redemption code is for photoshop elements?
Using redemption code
http://helpx.Adobe.com/x-productkb/global/redemption-code-help.html
-
How can I request a code offline for a new serial number?
I buy Adobe Muse but I can't activate it
How can I request a code offline for a new serial number?
To the link below, click on the still need help? the option in the blue box below and choose the option to chat...
Serial number and activation support (non - CC) chat
http://helpx.Adobe.com/x-productkb/global/Service1.html ( http://adobe.ly/1aYjbSC ) -
create the code lock for computer book note
How to create the code lock for computer book notices
Enter the BIOS, select the Security tab and set the power on password.
I strongly recommend that you write the power on password and put somewhere safe. If you have forgotten the password turned on, you will find that you will need to send your laptop to be repaired by HP. This is not free of cost. Once a button inside the laptop password reset are over.
I can't be more precise, as you have not identified your laptop with its full product name or product number.
-
How to code a batch file to put in the form of z: drive?
I would like to drive Z: quick format and xcopy in D: drive in the Z: drive for backup.
I would like to pass on any message entry also.
Anyone have any suggestions on how to code a batch file for this?
Thanks for all the suggestions
Hi oem7110,
Your question of Windows is more complex than what is generally answered in the Microsoft Answers forums. It is best suited for on TechNet. Please post your question in the TechNet forum. Link: http://social.technet.microsoft.com/Forums/en-US/ITCG/threads
With regard to:
Samhrutha G S - Microsoft technical support.
Visit our Microsoft answers feedback Forum and let us know what you think.
-
Error Code C800044E for Windows updates.
I get this error code c800044e for Windows updates. I tried the support center to the bottom of the load and fix, but it does not resolve this error. Help, please.
Hello
1. all the troubleshooting steps have followed so far?
2. the updates could not be installed?
3. what fixit did you run?
4 have have there been recent changes made on the computer before the show?
I suggest you to follow the steps mentioned below and check if it helps.
Method 1: Put the computer in a clean boot state and try to install the updates.
http://support.Microsoft.com/kb/929135
Note: After installing the updates, follow step 7 in the link provided to return the computer to a Normal startupmode.
Try to download the update and install.
Download Center.
http://www.Microsoft.com/download/en/default.aspx
Method 2: If the problem persists with Windows updates, the problems with the installation of the updates.
http://Windows.Microsoft.com/en-us/Windows-Vista/troubleshoot-problems-with-installing-updates
Method 3: How to reset the Windows Update components?
http://support.Microsoft.com/kb/971058
Then try to reinstall updates.
I hope the information is useful!
-
error code 646 for the updates of Microsoft office
error code 646 for Microsoft office updates KB949710, KB951550, KB973593, KB950130, KB951944, KB973704, KB974561. Help, please
Try this for your error Code 646 and read ALL the messages/solutions to your problem on the link below:
http://social.answers.Microsoft.com/forums/en-us/vistawu/thread/f3390e74-9961-4AAE-8a05-554c1a9cf1a2
Read the info on the above link to error Code 646.
With the compliments of: David_O - Support Engineer
This problem occurs when the agent Windows Update Wups2.dll file is incorrectly registered in the registry. Because registry files that correspond to the Wups2.dll file are missing, update facilities have failed. There are two methods to resolve this issue, use method 1 first, and if it did not resolve your issue, go to method 2
Method 1: Save the Windows Update files
1. click Start and type notepad in the box start the search .
2. click on Notepad in the programs list.
3. copy the following commands, and then paste them into the opened Notepad window:
REGSVR32 WUPS2. DLL/S
REGSVR32 STINKS. DLL/S
REGSVR32 WUAUENG. DLL/S
REGSVR32 WUAPI. DLL/S
REGSVR32 WUCLTUX. DLL/S
REGSVR32 WUWEBV. DLL/S
REGSVR32 JSCRIPT. DLL/S
REGSVR32 MSXML3. DLL/S1. in Notepad, on the file menu, click on record under.
2. in the list record under , click all files.
3. in the file name box, type register.bat.
4. save the Register.bat file to your desktop.
5 right-click the Register.bat file, and then click run as administrator. Reduce this includes this imageIf you are prompted for an administrator password or a confirmation, type the password or click continue.
6. try to install the updates again.
Method 2: Download and install Windows Update agent
For more information about how to download and install the latest Windows Update agent, click on the number below to view the article in the Microsoft Knowledge Base:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
If the above does not help:
You will get the best help for any problem of Update/Service Pack update Vista Forum; the link below:
http://social.answers.Microsoft.com/forums/en-us/vistawu/threads
When you repost here, kindly include this error Code, and exactly what is happening when you try to update.
In this way, you will receive the best help.
See you soon
Mick Murphy - Microsoft partner
Maybe you are looking for
-
How to reinstall Windows without ODD on my NB250?
Dear people,I have a NB250 (PLL2PE) which gives a code of FAJDH 0xc00000e9 laptop. I want to reinstall windows in the hope that this will help, but the phone doesn't have a cd-rom drive, or received no installation CD. (probably because of the absenc
-
I used my tv as a second monitor and still could not find it. I know that halo works because I played it before on this computer. Is there a way to indicate to the program to open to some a monitor? Should I reinstall halo?
-
-
Spooler Subsystem App has encountered a problem and needs to close
We cannot print anything on my computer. the message is that the Print Spooler Subsystem App has encountered a problem and needs to close. How to get the print spooler to run and work my printer start?
-
New wireless network does not appear on any computer
Thanks in advance for any help. OK, so I have a HP office connected to the internet through a router WRT54GS. I had 2 laptops connected to the NICU my wireless router. A (HP) laptop has built in wireless modem/adapter. The other laptop Dell was NIC