dcsimg
A Flash Developer Resource Site

Results 1 to 5 of 5

Thread: Problems with Softkeys and Numeric Input

  1. #1
    Junior Member
    Join Date
    Sep 2009
    Posts
    3

    Problems with Softkeys and Numeric Input

    Hi, I know these are two completely different problems, but I will post them in one thread anyway!

    I am writing 2 small flash lite apps (using flash 1.1) for mobile phones, and I have the following problems.

    1) I have the softkeys set up to run some simple tasks, but the left softkey is still opening the flash menu (as well as doing what I want it to do).

    This is what I have in my KeyCatcher:
    Code:
    on (keyPress "<PageUp>") 
    {
    	gallon = Number(litres) * 0.219969157;
    	mpg = miles / gallon ;
    	totalcost = ppl * litres;
    	cpm = totalcost / miles;
    }
    
    on (keyPress "<PageDown>")
    {
    	fscommand2("Quit");
    }
    2) I have some input boxes that are for numeric values, but I still require the use of a full stop, but can't seem to work out how to get just numbers and "."

    Current code for this is:
    Code:
    fscommand2("SetInputTextType", "miles", "Numeric");
    fscommand2("SetInputTextType", "litres", "Numeric");
    fscommand2("SetInputTextType", "ppl", "Numeric");
    Any help is much appreciated.

    Regards
    Jim

  2. #2
    Senior Member
    Join Date
    Aug 2006
    Posts
    322
    fullscreen command will solve the 1st problem and embedding front to number and dot will solve the second.

    marlopax

  3. #3
    Junior Member
    Join Date
    Sep 2009
    Posts
    3
    Quote Originally Posted by marlopax View Post
    fullscreen command will solve the 1st problem and embedding front to number and dot will solve the second.

    marlopax
    Many thanks for your reply, I allready have fullscreen enabled using the following command
    Code:
    fscommand2("FullScreen", true);
    But its still showing both the flash menu and the intended use.

    I have done some googling with regards to the 'embedding font' suggestion, but I can't seem to find out how to get it to do what I want (I am a nube to flash & as).

    Cheers
    Jim

  4. #4
    Senior Member
    Join Date
    Aug 2006
    Posts
    322
    root timeline:
    fscommand2("SetSoftkeys",left,right);

    select the text field
    In the Property Panel Click Embed Button
    In the embed window select the numerals and click ok

    thats it


    marlopax
    Last edited by marlopax; 09-20-2009 at 02:49 AM.

  5. #5
    Junior Member
    Join Date
    Sep 2009
    Posts
    3
    Hi.

    I have now got the embedded font sort of working, it will type only numbers into the field, but I cant seem to get the full stop to work for the decimal place.

    Also the flash menu is still opening up (for some reason... I cant see why though)

    I have attached the project to this post so you can have a look and see if you can spot the errors in my ways :P

    Cheers
    Jim

    Edit: The phone it is being tested on is a Nokia N95 8GB (if that makes any difference)
    Attached Files Attached Files

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center