Compiler Error: 1120 / 1067. please help!

I've been stuck on this error for a whole day now, trying to find out whats wrong. im new to AS3, but i have been following the tutorials with lynda.com
i've been trying to make a scrollbar and everything works fine, until i have to connect it with the text. theres an image and a title that i want to scroll with the (static) text so i created a movie clip (instance name cafe_txt), and when i wrote the script and tested the movie, i come up with the 1120 error that cafe_txt is not defined.
So i changed the clip(thinking that the problem was the scrollbar had to be in the same instance as the text) so that the scrollbar was inside, and i come up with error 1067(1067: Implicit coercion of a value of type flash.display:MovieClip to an unrelated type flash.text:TextField.)
I've tried changing names, double checking that instance names are correct, moving things, changing the text so that its dynamic not static(if the scrollbar is connected to just the dynamic text it works, it just doesnt scroll the full length of the text)
here's the code in my stage:
scrollbar_mc.textField = cafe_txt
and my code from the scrollbar.as file:
package com.lynda.ui
    import flash.display.*;
    import flash.events.*;
    import flash.geom.Rectangle;
    import flash.text.TextField;
    public class Scrollbar extends Sprite
        public var value:Number;
        public var padding:Number = 5;
        private var _textField:TextField;
        private var max:Number;
        private var min:Number;
        public function Scrollbar()
            min = bar_mc.y;
            max = bar_mc.height - drag_mc.height;
            drag_mc.addEventListener(MouseEvent.MOUSE_DOWN, dragHandle);
        private function dragHandle(event:MouseEvent):void
            drag_mc.startDrag(false, new Rectangle(0,min,0,max));
            stage.addEventListener(MouseEvent.MOUSE_UP, stopDragging);
            stage.addEventListener(MouseEvent.MOUSE_MOVE, updateValue);
        private function stopDragging(event:MouseEvent):void
            drag_mc.stopDrag();
            stage.removeEventListener(MouseEvent.MOUSE_UP, stopDragging);
            stage.removeEventListener(MouseEvent.MOUSE_MOVE, updateValue);
        private function updateValue(event:MouseEvent=null):void
            value = (drag_mc.y - min) / max;
            if(_textField && event)
                _textField.scrollV = Math.ceil(value * _textField.maxScrollV);
            dispatchEvent(new Event(Event.CHANGE));
        public function set textField(tf:TextField):void
            _textField = tf;
        public function get textField():TextField
            return _textField;
thanks for the help...

click file/publish settings/flash and tick "permit debugging".  retest.  the problematic line of code will be listed in the error message.
copy and paste the error message and highlight the problematic line of code.

Similar Messages

  • OCCI Compile Error.. Please Help me....

    I'm Developing on the Compaq Tru64 Unix Version 5.1b
    I'm attempting to compile/link Oracle OCCI demo using Tru64 cxx with no success
    Compile error:
    cxx: Warning: /pdms_appl/oracle/product/rdbms/demo/occiObjects.h, line 119:
    function "oracle::occi::PObject::operator new(std::size_t, void *)"
    has no corresponding operator delete (to be called if an exception
    is thrown during initialization of an allocated object)
    void operator new(size_t size, void adctx);
    --------------^
    cxx: Warning: /pdms_appl/oracle/product/rdbms/demo/occiObjects.h, line 116:
    function "oracle::occi::PObject::operator new(std::size_t, const
    oracle::occi::Connection *, const std::string &, const char *)" has
    no corresponding operator delete (to be called if an exception is
    thrown during initialization of an allocated object)
    void operator new(size_t size, const Connection x,
    --------------^
    Runtime Error:
    PDMS_pdms.bitekic.co.kr:/pdms_appl/oracle/product/rdbms/demo> occipool
    resolve_symbols: loader error: dlopen: libocci.so.9.0: symbol "OCIPSetObjectPtrNull" unresolved

    I think you can ignore the compilation warnings.
    For the unresolved symbol error while running the OCCI app, can you try static linking of the application with libocci9.a & libclntst.a ? e.g :-
    make -f demo_rdbms.mk buildocci_static EXE=occipool OBJS=occipool.o
    Regards,
    Shankar

  • WLS compiling error: BEA-160187 - please help

    Hi all,
    hoping I am posting in the right spot. I am migrating a 10g app to 11g and afward the wizard, I tried to compile the ViewController project and in the "compiler" tab, it gives this warning:
    Warning: <Apr 27, 2012 11:14:21 AM MDT> <Error> <J2EE> <BEA-160187> <weblogic.appc failed to compile your application. Recompile with the -verbose option for more details. Please see the error message(s) below.>
    I did some search in google and got no luck to figure this out. Can someone here help me with this warning? I tried to check the box for "-verbose" in JDEV and re-build the project, same information, no details?
    Thanks in advance!
    Shawn

    Shawn,
    Your problem & solution exist in Oracle Support, note 864735.1
    Arik

  • I can't control a symbol's instance, error 1120! Please help T_T

    Hello everyone. I'm a student & I don't have a good experience I learned some codes from the tutorials... .
    This is my last project & I have to deliver it as soon as possible, so I need some help please.
    My project is to drag small boxes & drag it to a BIG BOX.
    I have two frames represents two levels.
    Level1: Big Green box & small green boxes on the stage.
    I have one big box on the stage it's instance name "green_pot", I have a small boxes below of the BIG BOX on the stage it's instance name is "green".
    Level2: 3 Big Boxes: RED, Black, and BLUE, below of them small boxes: red, black, and blue, their instance name are "red,blue,black".
    I made a four classes in a folder "ingame" :
    black_class.as
    green_class.as
    red_class.as
    blue_class.as
    all of them have the same codes, the diffirence between them is the instance name only.
    ==> The Problem is when I use the instance name whether in if statement or at the beggining of a Listener....
    an error is shown:
    E:\FL\ActionScript\Quick Add Drag&Drop\ingame\black_class.as, Line 13
    1120: Access of undefined property black.
    here is the ingame.black_class.as:
    package  ingame {
              import flash.events.MouseEvent;
              import flash.display.MovieClip;
              import flash.geom.Point;
              public class black_class extends MovieClip{
                         var OriginalXY:Point = new Point (x,y);
                        public function black_class() {
                                  buttonMode = true;
                                  black.addEventListener (MouseEvent.MOUSE_DOWN, down);
                        protected function down (event:MouseEvent):void {
                                  startDrag();
                                  parent.addChild(black);
                                  black.addEventListener (MouseEvent.MOUSE_UP, stageUp);
                                   function stageUp(event:MouseEvent):void {
                                            black.removeEventListener (MouseEvent.MOUSE_UP, stageUp);
                                            stopDrag();
                                  if (dropTarget) {
                                            if(dropTarget.parent.name == 'black_pot'){
                                                      buttonMode = false;
                                                      black.removeEventListener (MouseEvent.MOUSE_DOWN, down);
                                                      black.alpha = 0.8;
                                                      scaleX = scaleY = 0.2;
                                                      y = stage.stageHeight - height - 10;
                                                      x = stage.stageWidth - width - 50;}
                                            else OriginalPlace();
                                  else OriginalPlace()
                                  protected function OriginalPlace():void {
                                            x = OriginalXY.x;
                                            y = OriginalXY.y;
              }//public class
    }//package

    1. black isn't defined in your class.
    2. if there's a displayobject with instance name "black", use getChildByName() (applied to black's parent) to reference it.

  • Cannot Compile....please help

    I am trying to compile the program below. I have set my class path, but this is the first time I have tried to import files. The attached program is in a folder called C:\csci3753
    My import files are in subdirectories of C:\jdk1.3.1_02
    I get the following error:
    C:\csci3753>javac -sourcepath . MultipleSelection.java
    error: cannot read: MultipleSelection.java
    1 error
    I attached the code, I think it is the way I am setting up my compile line...please help.
    // Multiple-Selection Lists
    // Copying items from one list to another.
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    public static void main(String[] args)
              MultipleSelection ms = new MultipleSelection();
              ms.addWindowListener(
                   new WindowAdapter() {
                        public void windowClosing(WindowEvent e)
                             System.exit(0);
    public class MultipleSelection extends JFrame
         private JList colorList, copyList;
         private JButton copy;
         private String colorName[] = {"Black", "Blue", "Cyan","Dark Gray","Gray",
         "Green","Light Gray","Magenta","Orange",
                        "Pink","Red","White","Yello","White"};
    public MultipleSelection()
              super("Multiple Selection List");
              Container c = getContentPane();
              c.setLayout(new FlowLayout());
              colorList = new JList(colorName);
              colorList.setVisibleRowCount(5);
              colorList.setFixedCellHeight(15);
                        colorList.setSelectionMode(ListSelectionModel.MULTIPLE_INTERVAL_SELECTION);
              c.add(new JScrollPane(colorList));
              copy = new JButton("Copy >>>");
              copy.addActionListener(
                   new ActionListener() {
                        public void actionPerformed(ActionEvent e)
                             copyList.setListData(colorList.getSelectedValues());
              c.add(copy);
              copyList = new JList();
              copyList.setVisibleRowCount(5);
              copyList.setFixedCellWidth(100);
              copyList.setFixedCellHeight(15);
              copyList.setSelectionMode(ListSelectionModel.SINGLE_INTERVAL_SELECTION);
              c.add(new JScrollPane(copyList));
              setSize(300, 120);
              show();

    If you are compiling from the same directory as the source file, then you don't need a sourcepath. Just type:
    javac MultipleSelection.javaThe import files will be found as long as you have the C:\jdk1.3.1_02\bin directory in your command path.
    By the way, you will need to move the 'main' method into the MultipleSelection class to compile correctly.
    Hope this helps.
    Jeff Hurt

  • TS3694 How can I fix this type of error in iphone 4?"The iphone could not be restored. An unknown error occurred (3194) "please help me.

    Hi everybody !
    AT&T company is unlocked (factory)my iphone4 before 3 days ago so i want to restore to unlock iphone 4 with itunes but it is not restore.
    How can I fix this type of error in iphone 4?- "The iphone could not be restored. An unknown error occurred (3194) "
    please help me in nepali language(if posible) or english. thank you.

    http://support.apple.com/kb/TS3694#error3194
    This means that either your firewall/antivirus is blocking access to Apple's servers, or you have used your computer to jailbreak an iDevice in the past. The link above tells you how to resolve this issue.

  • Photoshop CS6 could not update successfully.  Error codes Adobe Photoshop 13.0.1.3 Installation failed. Error Code: U44M1P7  Extension Manager 6.0.8 Update Installation failed. Error Code: U44M1P7  Please help me figure out how to call customer service. 

    Photoshop CS6 could not update successfully.  Error codes Adobe Photoshop 13.0.1.3 Installation failed. Error Code: U44M1P7  Extension Manager 6.0.8 Update Installation failed. Error Code: U44M1P7  Please help me figure out how to call customer service.  I would prefer to talk to someone directly.

    Are you using any disk cleaner or optimization tools like CleanMymac or Mackeeper?
    Regards,
    Ashutosh

  • TS2865 when i export movie from final cut pro to quicktime , something happened. it says error quicktime -50. please help.

    when i export movie from final cut pro to quicktime , something happened. it says error quicktime -50. please help.
    i need to submit this movie for uni project tomorrow.
    any help/advice will help . thanks.

    According to Crash Analyzer
    -50 (QuickTime)
    This error occurs when there is corrupt or invalid media in your timeline. Check that the codec used by the file is recommended for use in your editing application.
    good luck

  • TS3694 hi, I was trying to update my iPhone 3gS but when I turn it on again iTunes send me a message that says error 3194 occurs, please help me!!

    hi, I was trying to update my iPhone 3gS but when I turn it on again iTunes send me a message that says error 3194 occurs, please help me!!

    If the screen shows a plug going to itunes, then you have no choice,  It's in recovery mode.  You'll be given the chance to restore from a backup either from itunes or icloud.
    I assume when you got the message to update (was this for the ios or update some apps?), that was before the device when dead.  At any rate, doing a restore does not change the ios.

  • HT201413 Whenever i try to sync my ipod a message keeps coming up saying "1 or more items could not be synced", apparently its error -69. Please help, i've tried rebooting my laptop, installing the latest itunes and turning off the wifi but nothing seems

    Whenever i try to sync my ipod a message keeps coming up saying "1 or more items could not be synced", apparently its error -69. Please help, i've tried rebooting my laptop, installing the latest itunes and turning off the wifi but nothing seems to work.

    Are you using security software on your PC? If yes, try to disable the software or check the settings. More info here: http://support.apple.com/kb/TS3125

  • My ipad mini 2 is not turning on. I tried to reset with the power/home buttons but it didnt work. I tried to restore it in DFU mode but it didnt work, i get error 4004. Please help me!

    My ipad mini 2 is not turning on. I tried to reset with the power/home buttons but it didnt work. I tried to restore it in DFU mode but it didnt work, i get error 4004. Please help me!

    I also tried the ol' whacking 3 times trick...Didn't work to my surprise

  • I backed up my movies and rebuild my computer, and after making sure i'm using the latest version of itunes and quicktime and and making sure i still had spare computer authorizations, i still get error 23132.  Please help.

    I backed up my movies and rebuild my computer, and after making sure i'm using the latest version of itunes and quicktime and and making sure i still had spare computer authorizations, i still get error 23132.  Please help.

    I had this exact issue.  Spent over an hour on the phone with apple support, they couldn't resolve.  Here is what I ended up doing, that worked.
    1.  Turned iTunes match off on all my iOS devices
    2.  Deleted the offending playlists from the iOS device they originated on
    3.  Started iTunes, let it run (literally) for an hour before it became responsive.  First thing I did, before clicking anywere else was disable iTunes match.  If I clicked anywhere, it would clock for another hour.
    4.  Let iTunes run overnight, by morning it had cleaned out the repeating play lists.  This got my Mac/iTunes back to an operable state.
    5.  Restore iPhones from backup in iTunes.
    What was causing my issue was a single playlist that was created on an iPhone, then suddenly showed up with several thousand duplicates on my other iPhone.  The culprit playlist did not, for some reason, duplicate itself on my two iPads.  Apple support seemed to think it was because the problem iPhone tried to sync the playlist to iCloud over and over again unsuccessfully, then it finally went through and populated the thousands of blank/failed playlists which then tried to propigate to iTunes and my other iOS devices.  Seems like a reasonable theory.
    I have not yet re-enabled iTunes match.  So, no idea what will happen if I decide to go back down that rabbit hole.

  • Cannot restore my brand new iphone 4s ,got stuck in DFU mode and itunes shows error code (-1) please help?

    Cannot restore my brand new iphone 4s ,got stuck in DFU mode and itunes shows error code (-1) please help?
    repeatedly tried from diffierent computers and the same error code pops up (error -1)

    That's a hardware problem which will require a trip to the Apple store for evaluation, unless your phone has been jailbroken, then it's a corrupt hosts file (and we can't help you with that here as it is against the forum's terms of use).

  • I cannot restore my Iphone 4, I keep getting the error code 1611, please help and the Iphone keeps displaying the "Plug-In Itunes Symbol!??

    I cannot restore my Iphone 4, I keep getting the error code 1611, please help and the Iphone keeps displaying the "Plug-In Itunes Symbol!??

    http://tinyurl.com/nyj36v

  • ýesterday  my iphone 5c screen  suddendly  shows connect to itune and i try to restore it using itune but halfway i got a message error occured (14). please help me in solving this problem.

    ýesterday  my iphone 5c screen  suddendly  shows connect to itune and i try to restore it using itune but halfway i got a message error occured (14). please help me in solving this problem.

    what did you learn when you search the internet for iPhone error 14?

Maybe you are looking for