flash keyboard access html form

How can I set a bridge between my flash key pressing function to a html form?
Angha110Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

petiexCommented:
Assuming your html form and swf file are on the same html page, you can put a javascript function on that page to do the form interaction, and use the ExternalInterface call() method to invoke that function.

 http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/external/ExternalInterface.html
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Angha110Author Commented:
Thank you for responding. But my flash is not on the same html page (unfortunately). I have an AIR application (my keyboard is there) which can call html pages in it. I want to be able to use my keyboard (the flash keyboard) to fill up the form. Sorry, I should have been more clear on my question.
0
petiexCommented:
It turns out I was wrong about the swf needing to be on the same page as the javascript . . .
From the ExternalInterface docs:
Note for AIR applications: In Adobe AIR, the ExternalInterface class can be used to communicate between JavaScript in an HTML page loaded in the HTMLLoader control and ActionScript in SWF content embedded in that HTML page.
I'm not sure that solves your problem, unless what you mean by "call html pages in it" is by using HTMLLoader, which, actually, I'll bet that's what you mean. Is it?
0
Big Business Goals? Which KPIs Will Help You

The most successful MSPs rely on metrics – known as key performance indicators (KPIs) – for making informed decisions that help their businesses thrive, rather than just survive. This eBook provides an overview of the most important KPIs used by top MSPs.

petiexCommented:
Shoot, never mind. They're talking about the swf in the html in the html loader communicating with javascript, not the AIR application communicating with the javascript in the loaded html. I'm dizzy now.

The only other idea that presents itself is passing the characters that you enter using the AIR keyboard to the html page in a query string, reloading the html with every keystroke. Is that feasible?
0
Angha110Author Commented:
Please note that I don't have any control on the html page where the form is. I am loading that html page to my program. So, just to be clear, that html page with the form could be any body webpage. SO I can not put any code on it. The flash part is mine and I do have control on the keyboard...
0
CyanBlueCommented:
I want to say that it is not possible for your AIR app to fill up a form in some other site.

CyanBlue
0
Angha110Author Commented:
Thank you for your opinion.
But, I believe everything is possible if you know the right way to do it.
0
CyanBlueCommented:
Don't we all dream about that?  But the reality can be different than what we hope for because sometimes it is hard to define what is right way or not.

Love to be proven wrong at any case.  :)

CyanBlue
0
Angha110Author Commented:
I agree, but I would like to do more research before giving up just based on your opinion.
0
CyanBlueCommented:
Oh, I hear you.  I am only answering based on my knowledge and there always are more information that I am not aware of.  Just make it in a reasonable time and we are all good.

CyanBlue
0
Angha110Author Commented:
As far as the Expert Exchange policy goes,  What should do with this question?
Closing it? accept your answer as a solution?

Please advice!
0
CyanBlueCommented:
I believe we have two weeks to determine the faith of the topic.  If the topic does not get resolved in that time period, it goes into the cleanup queue where cleanup volunteers will decide what is appropriate closure of the topic.

So, why not take a week and see if you can find anything other than what petiex and I have said.  You can decide what this topic should be after your research.

Generally speaking, if you find the topic useful to you one way or another, you'd want to split the points.  If you find the answers not helping you at all, you'd want to close it without awarding points.  If you decide not to take any action, you are leaving the cleanup volunteers to take care of it.  It's all up to you. (Mind you that I happened to be the cleanup volunteer for this topic area.)

Well, good luck with your research.

CyanBlue
0
Angha110Author Commented:
Thank you for taking the time giving me these information.
Your help/tips are always appreciated.

Best Regards
0
CyanBlueCommented:
I think that's wrong.  I've spent some time to see if this is possible and I am sure you've done the same.  
I know that it is possible to do what you are asking if you have an access to the target site and have power to update it with JS, but you do not have an access to those, so my answer is that it is not possible.

Now, you are saying that it there might be a solution to this so you are just closing this.  That sounds like this question: Does the tooth fairy exist?
I know it does not exist because I have not found a single dime under my pillow. But you are saying that I might be wrong because it might just be the case where I've been a bad boy.  

Well, you can keep your hope as high as you can, but the record should say that your answer is that it is not possible until you provide the actual fact not just hope.  That's my 2 cents.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Adobe Flash

From novice to tech pro — start learning today.