How JustAnswer Works:
  • Ask an Expert
    Experts are full of valuable knowledge and are ready to help with any question. Credentials confirmed by a Fortune 500 verification firm.
  • Get a Professional Answer
    Via email, text message, or notification as you wait on our site. Ask follow up questions if you need to.
  • 100% Satisfaction Guarantee
    Rate the answer you receive.
Ask Pete Your Own Question
Pete, Computer Expert
Category: Software
Satisfied Customers: 18133
Experience:  CISCO certified computer and networking expert
Type Your Software Question Here...
Pete is online now
A new question is answered every 9 seconds

I have a very large graphic that I need to zoom into a

Customer Question

I have a very large graphic that I need to zoom into a specific point, select and activate a button and zoom out again. I have tried all the suggestions given in the post "Zoom to and from point" from 4 years ago but I am getting "Statement must appear within on handler" error. I am new to Action Script 3 for my company and would really appreciate any help I can get. I am a one man band here and all my instruments are sounding out of tune.
Submitted: 1 year ago.
Category: Software
Expert:  Pete replied 1 year ago.

Hi George,

Expert:  Pete replied 1 year ago.

I cannot see the script you are using however you will likely need to remove the problem code from your object, and while it is still selected enter an instance name in the properties panel, eg btn.
then click on the frame and in the actions panel, use:

Customer: replied 1 year ago.
Scene=Scene 1, layer=1485, frame=1, Line 1 Operator '=' must be followed by an operand
Customer: replied 1 year ago.
Posted by JustAnswer at customer's request) Hello. I would like to request the following Expert Service(s) from you: Secure Remote Assistance. Let me know if you need more information, or send me the service offer(s) so we can proceed.
Customer: replied 1 year ago.
It is 1933 here now. I have to go run an errand in the morning and I have to go to work around 1300 hours tomorrow. I will be off Wednesday and Thursday.
Customer: replied 1 year ago.
What service offers do I need? It is 4:30 AM here now and I am up.
Expert:  Pete replied 1 year ago.

Sorry, I am still not seeing the entire script or how it is being used.

I will opt out and check if another expert can assist with this.

Customer: replied 1 year ago.
I have been away at work, I will be home today and tomorrow. If you want to link up with my PC and look at the Fla file let me know otherwise please hook me up with another expert soon. I need this by Friday afternoon.
Customer: replied 1 year ago.
This is the script I have on the Actions Layer:gambar.addEventListener(TransformGestureEvent.GESTURE_ZOOM , onZoom);
function onZoom(event:TransformGestureEvent):void {This is the script I have on the Zoom Button:gambar.scaleY=prevScaleY;}if(event.scaleY>1 && gambar.scaleY>6){gambar.scaleX=prevScaleX;gambar.scaleY=prevScaleY;}if(event.scaleX<1 && gambar.scaleX<0.8){gambar.scaleX=prevScaleX;gambar.scaleY=prevScaleY;}if(event.scaleY<1 && gambar.scaleY<0.8){gambar.scaleX=prevScaleX;gambar.scaleY=prevScaleY;}mat=gambar.transform.matrix.clone();MatrixTransformer.matchInternalPointWithExternal(mat,internalPoint,externalPoint);gambar.transform.matrix=mat;}And this is the / are the Error messages I get:Scene=Scene 1, layer=Actions, frame=1, Line 2 '{' expected
Scene=Scene 1, layer=1485, frame=1, Line 1 Statement must appear within on handler
Scene=Scene 1, layer=1485, frame=1, Line 3 Unexpected '}' encountered