Accessing the stage variable problems in AS 3.0

Hi. Quick question...I'm trying to access the stage variable
which I believe is supposed to be global and I should be able to
access it from any class. Is this true? The compiler is complaining
that it doesn't recognize this variable? Note that these objects
have not been added to the stage yet but still, these are compile
time errors, so why is that I'm getting these errors?
Thanks,
Sam

Sam,
> Actually, this doesn't have to do with that question.
> Basically, the compiler is complaining that it doesn't
> recognize the stage variable.
It complains about the DisplayObject.stage property? Are you
referencing it in conjunction with a DisplayObject instance?
> This is weird because in my AS 3.0 book, I see that
> the stage variable is being accessed without
instantiating
> it or retrieving it.
What book is that? I might have it, then I can see what
you're seeing.
> I am extending Sprite in all my classes.
Yeah, Sprite extends DisplayObject, by of InteractiveObject,
then
DisplayObjectContainer, so it certainly is entitled to the
stage property.
Let me know what book you're looking at, and if I don't have
it (and if
you're still interested), I'll try to recreate a simplified
proof of concept
on this end.
David Stiller
Adobe Community Expert
Dev blog,
http://www.quip.net/blog/
"Luck is the residue of good design."

Similar Messages

  • How do I access the DCJMS* variables in my response SOAP:Header ?

    Hi all,
    I have set up a sync / async Integration Process in XI
    This is initiated by a SAP R/3 transaction that calls a synchronous function to enter XI
    Once in the Bridge, a JMS receiver adapter sends out an asynchronous request message from XI to MQ
    A correlation allows the JMS sender adapter to return an asynchronous response message from MQ to XI back into my the Integration Process
    I have set up the JMS sender adapter configuration to return the DC (dynamic configuration) variables in the <SOAP:Header> of the XI response message along with the payload
    You can see that the DCJMS* variables are returned below
    <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    - <!--
    Response
      -->
    - <SOAP:Envelope xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SAP="http://sap.com/xi/XI/Message/30">
    - <SOAP:Header>
    + <SAP:Main xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" xmlns:wsu="http://www.docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" versionMajor="003" versionMinor="000" SOAP:mustUnderstand="1" wsu:Id="wsuid-main-92ABE13F5C59AB7FE10000000A1551F7">
    + <SAP:ReliableMessaging xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="1">
    + <SAP:HopList xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="1">
    + <SAP:RunTime xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">
    + <SAP:PerformanceHeader xmlns:SAP="http://sap.com/xi/XI/Message/30">
    - <SAP:DynamicConfiguration xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="1">
      <SAP:Record namespace="http://sap.com/xi/XI/System/JMS" name="DCJMSCorreleationID">40D982A0-B19D-11DB-9508-0002A5D5916B</SAP:Record>
      <SAP:Record namespace="http://sap.com/xi/XI/System/JMS" name="DCJMSTimestamp">1170297456940</SAP:Record>
      <SAP:Record namespace="http://sap.com/xi/XI/System/JMS" name="DCJMSMessageID">ID:414d5120514d4430312020202020202045c12b962001dd02</SAP:Record>
      </SAP:DynamicConfiguration>
    - <SAP:Diagnostic xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="1">
      <SAP:TraceLevel>Information
    <b>Question</b>
    I want to access the DCJMS* variables but am not sure how to go about it as the
    variables exist in the <SOAP:Header>?
    I followed the SAP documentation to access adapter-specific attributes (refer to link http://help.sap.com/saphelp_nw04/helpdata/en/14/80243b4a66ae0ce10000000a11402f/frameset.htm )
    I have used the following code to create a user-defined function for the accessing adapter specific attributes (similar to the link)
    public String Get_Msgid(Container container){
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get
    (StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey key = DynamicConfigurationKey.create
    ("http://sap.com/xi/XI/System/JMS","DCJMSMessageID");
    String jmsMsgID = conf.get(key);
    return jmsMsgID;
    <b>Question</b>
    Do I use message mapping to extract the DCJMS* variables?
    <b>Question</b>
    If so then which message is used for the source message so that I can access the <SOAP:Header>?  Eg do I use the response message type or is there a trick to accessing the SOAP:Header?
    <b>Question</b>
    Do I use the user-defined function (like above)?
    I performed the following steps
    •     Opened the message mapping in edit mode
    •     Created the user-defined function using the graphical editor
    •     Saved the message mapping
    •     I have not connected the user-defined function to any of the xml tags in either the source or target messages
    When I go to test the message mapping I am getting the following error
    Compilation process error : CreateProcess: null\bin\javac -J-Xmx256m @E:/usr/sap/XID/DVEBMGS00/j2ee/cluster/server0/./temp/classpath_resolver/Mapd79a7bf0b65611dbaf390002a5d5916b/O1170817003886.txt @E:/usr/sap/XID/DVEBMGS00/j2ee/cluster/server0/./temp/classpath_resolver/Mapd79a7bf0b65611dbaf390002a5d5916b/S1170817003886.txt error=2
    STACKTRACE:
    com.sap.aii.ib.core.mapping.exec.ExecuteException: Compilation process error : CreateProcess: null\bin\javac -J-Xmx256m @E:/usr/sap/XID/DVEBMGS00/j2ee/cluster/server0/./temp/classpath_resolver/Mapd79a7bf0b65611dbaf390002a5d5916b/O1170817003886.txt @E:/usr/sap/XID/DVEBMGS00/j2ee/cluster/server0/./temp/classpath_resolver/Mapd79a7bf0b65611dbaf390002a5d5916b/S1170817003886.txt error=2
    at  com.sap.aii.ib.server.mapping.exec.ServiceUtil.compileSourceCode(ServiceUtil.java:207)
    at com.sap.aii.ib.server.mapping.exec.ServiceUtil.compile(ServiceUtil.java:156)
    at com.sap.aii.ibrep.server.mapping.ServerMapService.compileSourceCode(ServerMapService.java:361)
    at com.sap.aii.ibrep.server.mapping.ServerMapService.compileSourceCodeWithoutAndWithArchives(ServerMapService.java:301)
    at com.sap.aii.ibrep.server.mapping.ServerMapService.execute(ServerMapService.java:153)
    at com.sap.aii.ibrep.sbeans.mapping.MapServiceBean.execute(MapServiceBean.java:52)
    at com.sap.aii.ibrep.sbeans.mapping.MapServiceRemoteObjectImpl0.execute(MapServiceRemoteObjectImpl0.java:259)
    at com.sap.aii.ibrep.sbeans.mapping.MapServiceRemoteObjectImpl0p4_Skel.dispatch(MapServiceRemoteObjectImpl0p4_Skel.java:146)
    at com.sap.engine.services.rmi_p4.DispatchImpl._runInternal(DispatchImpl.java:304)
    at com.sap.engine.services.rmi_p4.DispatchImpl._run(DispatchImpl.java:193)
    at com.sap.engine.services.rmi_p4.server.P4SessionProcessor.request(P4SessionProcessor.java:122)
    at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33)
    at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41)
    at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
    at java.security.AccessController.doPrivileged(Native Method)
    at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100)
    at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170)
    A thread in the SDN (Error while Activating Message Mapping, Posted: Jan 9, 2007 3:32 PM) suggests checking the java path on the XI machine
    This is JAVA_HOME=C:\j2sdk1.4.2_08 and seems ok
    <b>Question</b>
    Do you know why I would get the compilation error?
    Any assistance would be appreciated
    Regards,
    Mike

    Jin,
    My compilation issue has gone via a SAP recommendation to specify the JDK home directory in the instance profile
    Back to the mapping - I can now run my scenario
    <b>Source message</b>
    The response message has the following <SOAP:Header> from which I want to extract the DCJMSCorreleationID (note that it's misspelt)
      <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    - <!--  Response
      -->
    - <SAP:DynamicConfiguration xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="1">
      <SAP:Record namespace="http://sap.com/xi/XI/System/JMS" name="DCJMSCorreleationID">40D982A0-B19D-11DB-9508-0002A5D5916B</SAP:Record>
      <SAP:Record namespace="http://sap.com/xi/XI/System/JMS" name="DCJMSTimestamp">1170297456940</SAP:Record>
      <SAP:Record namespace="http://sap.com/xi/XI/System/JMS" name="DCJMSMessageID">ID:414d5120514d4430312020202020202045c12b962001dd02</SAP:Record>
      </SAP:DynamicConfiguration>
    <b>Grahpical mapping</b>
    LHS - Response message with occurrance 0..1 so it is not connected to my UDF
    UDF Get_Corrid with no inputs
    RHS - The UDF output is connected to the Acknowledgement msg tag <ACK>
    <b>UDF</b>
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get
    (StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey key = DynamicConfigurationKey.create
    ("http://sap.com/xi/XI/System/JMS","DCJMSCorreleationID");
    String Corrid = conf.get(key);
    return Corrid;
    <b>Target message</b>
    The idea is to copy the correlation id of the response message into the acknowledgement message.  But as you can see the result is NULL
      <?xml version="1.0" encoding="utf-8" ?>
    - <ns2:AWB0020_MARKET_DATA_RESPONSE_ACK xmlns:ns2="http://awb.com.au/mq/tx/MarketData">
      <ACK>null</ACK>
      </ns2:AWB0020_MARKET_DATA_RESPONSE_ACK>
    Please advise
    Thanks Mike

  • How to access the int variable in the inner class

    hi all,
    i can't access the int variable in the inner class. can any one help me
    int count = 0;
    MouseMoveListener mouseMove = new MouseMoveListener() {
         public void mouseMove(MouseEvent e) {
              count1++;
              System.out.println(count);
    };how to access count variable
    thanks

    for this how can i access the countIf the count variable is a local variable you can't access it from within the
    inner class. Make it a member variable of the outer class instead:public class Outer {
       private int count;
       MouseMoveListener mouseMove= new MouseMoveListener() {
          public void mouseMove(MouseEvent me) {
             count++;
             System.out.println(count);
    }Alternatively, if you don't need that count variable anywhere else, you
    could simply make it a member variable of the inner class itself:public class Outer {
       MouseMoveListener mouseMove= new MouseMoveListener() {
          private int count;
          public void mouseMove(MouseEvent me) {
             count++;
             System.out.println(count);
    }kind regards,
    Jos

  • Accessing the binding variables

    Hi,
    i have the following attribute entry in the page definition file.
    <attributeValues IterBinding="RenewalPolicyTermVOIterator" id="PolicyNum">
    <AttrNames>
    <Item Value="PolicyNum"/>
    </AttrNames>
    </attributeValues>
    I am getting Null Pointer exception at the 2nd line if I access the binding variable in the managed bean.
    1. AttributeBinding policyNumBinding = (AttributeBinding)(getBindings().getCtrlBinding("PolicyNum"));
    2. Number policyNum = (Number)policyNumBinding.getInputValue();
    3. System.out.println("PolicyNum from bindings" + policyNum);
    But the following code is getting the actual value of the binding attribute. But in the import stements I am getting a message JUCtrlAttrsBinding is an internal API and cannot be used.
    JUCtrlAttrsBinding policyNumBinding2 = (JUCtrlAttrsBinding)getBindings().get("PolicyNum");
    Number policyNum2 = (Number)policyNumBinding2.getInputValue();
    System.out.println("PolicyNum from bindings" + policyNum2);
    Why is the above code failing to get the binding attribute. What is the best way to refer the attribute in the managed bean code

    Why do you need all AttributeBinding class ... when you bind the input text in UI
    In Backingbean class a private variable is created
    private RichInputText rowOPsIT;
    and
    public void setRowOPsIT(RichInputText rowOPsIT) {
    this.rowOPsIT = rowOPsIT;
    public RichInputText getRowOPsIT() {
    return rowOPsIT;
    You can use the variable or functions to get the value and value properties

  • How to access the hidden variable in jsp

    hi all,
    i need help to know how to access the hidden variable in the same jsp.
    Following is the code snippet just have a look at that.
    ArrayList arrRankingSummary = (java.util.ArrayList)session.getAttribute("arrRankingSummary");
    <logic:iterate id="rankingSummary" name="arrRankingSummary">
    <input type="hidden" name="allApplicantID" value='<bean:write name="rankingSummary" property="APPLICANTID"/>' />
    <input type="hidden" name="allAdmissionRank" value='<bean:write name="rankingSummary" property="ADMISSIONRANK"/>' />
    </logic:iterate>
    <input type="hidden" name="applicantID" value='<bean:write name="rankingSummary" property="APPLICANTID"/>' />
    <TD align=center><Input type=Text name="admissionRank" class=Textverysmall size=2 value='<bean:write name="rankingSummary" property="ADMISSIONRANK"/>' maxlength="10" /> </TD>
    I want to remove the element from arraylist on these condition
    if(allApplicantID.value ==applicantID.value){
    arrRankingSummary .remove("admissionRank");
    Now the pbm is i m not getting how to access the hidden variable in jsp or how to use the values of hidden variable for the condition.
    Pls help me out.
    Thanks in adv.
    Regards,
    Ritu

    hi ram,
    as i mentioned i m creating hidden variables & i m doing some validation on form submit.
    The following is js code snippet for validation.
    for (var i = 0; i < document.forms[0].admissionRank.length; i++)
    admissionRank = document.forms[0].admissionRank.value;
    for(var j = 0; j < document.forms[0].allAdmissionRank.length; j++)
    //alert ("admissionRank : " + admissionRank + " document.forms[0].allAdmissionRank[" + j + "].value : " + document.forms[0].allAdmissionRank[j].value + "\ndocument.forms[0].allApplicantID[" + j + "].value : " + document.forms[0].allApplicantID[j].value + " document.forms[0].applicantID[" + i + "].value : " + document.forms[0].applicantID[i].value);
    if(admissionRank == document.forms[0].allAdmissionRank[j].value && document.forms[0].allApplicantID[j].value != document.forms[0].applicantID[i].value && admissionRank != "" && document.forms[0].allAdmissionRank[j].value != "")
    flag = false;
    document.forms[0].admissionRank[i].focus();
    document.forms[0].admissionRank[i].select();
    break;
    if (flag == false)
    break;
    In this validation i want admissionRank to be removed from the original arraylist if following condition gets satisfied
    "(document.forms[0].allApplicantID[j].value == document.forms[0].applicantID[i].value )"
    Thanks in adv
    Ritu

  • Why can't I access the received variables??

    Hello,
    I created a new partner link which has an operation which transmits a complex variable type (3 strings, 2 ints). If I add a RECEIVE to my bpel process, I can create an input variable. The problem is, that I want to access the data (of the datatype) via an ASSIGN, but I can't reach the data. The variable name is visible but not the underlying elements. I would be glad if anyone can help me.
    Patrick W.

    Patrick,
    Probably better asked on the BPEL forum.
    John

  • Thread cannot access the class variables.

    Hi
    I have below code snippet : (Only section of which I have copied below)
    public class ProcessAppendAction extends HttpServlet implements Runnable{
         public ProcessAppendAction ()
    MI_OS_APPEND port ;
    protected void doGet(
              HttpServletRequest request,
              HttpServletResponse response)
              throws ServletException, IOException {
              //TODO : Implement
    port =
                        (MI_OS_APPEND) obj.getLogicalPort(
                             "MI_OS_APPENDPort",
                             MI_OS_APPEND.class);
    Thread[] threads = new Thread[noOfThreads];
    ProcessAppendAction run = new ProcessAppendAction(req);
                                            Thread th = new Thread(run);
                                            threads[no] = th;          
                                  threads[no].start();
                                  threads[no].join();
    public ProcessAppendAction(DT_REQUEST_APPEND req) {
              this.requestObj = req;
              // TODO Auto-generated constructor stub
    public void run()
              try
                   DT_RESPONSE res = this.port.MI_OS_APPEND(requestObj);
                                  catch(Exception e)
                                       int ch=0;
                                       ch++;
              }     In above code I am successfully creating an object in line :
    port =
                        (MI_OS_APPEND) obj.getLogicalPort(
                             "MI_OS_APPENDPort",
                             MI_OS_APPEND.class);But when I am trying to access this port variable in run method it is giving null.
    Port in my code is a class variable.
    Is it the case that thread cannot access class variable !!

    money321 wrote:
    ok, I have removed join() from just after start().So that now the Servlet can return before the new Thread has finished. Is this what you want?
    First I did invoked all threads and then in second loop i invoked Join on all threads.I don't understand. Why do you need to join() all the threads since you only start one thread in this request. What am I missing?
    >
    Now, my problem.
    It was solved when I substituted the line
    ProcessAppendAction run = new ProcessAppendAction(req)
    with
    ProcessAppendAction run = new ProcessAppendAction(req,port);Of course. Instance variables in Servlet instances are a no-no so passing the 'port' though an instance variable is just wrong.
    >
    That is passes port alongwith req while creating thread object.
    But still if class variables are not thread safe, then it means if I pass object 1 to thread 1.
    And then try to pass object 2 to thread 2, it might be possibility that object 1 of thread 1 might be replaced by object 2.
    So, thread 1 will get an updated value object 2.Yep - that is why you should not use instance variables in Servlets and why they are not thread safe.
    >
    Which is not what I intend to do...:-)

  • No mapping at the fault address error while accessing the string variable

    Hi
    we have a application which runs fine on AIX and HP but is throwing error on SOLARIS.
    the application runs well (and use of string variables are also working fine ) till it hits Zone.cpp file
    where the string variable is not getting initialized and throws no mapping at the fault address
    the code snippet is as follows
    #include <string>
    #include <vector>
    const string ZONE_ATTR_TYPE_ZN("ZN");
    const string ZONE_ATTR_TYPE_FC("FC");
    const string ZONE_ATTR_TYPE_ST("ST");
    void Zone::AddAttributeValueAndCountryCode(const string &attributeValue,
                                                      Int attribSeq,
                                                      const string &countryCode,
                                                      ZoneSearchLocMap& zoneSearchLocMap)
         string key = "";
         if ((_attributeType == ZONE_ATTR_TYPE_FC) ||
              (_attributeType == ZONE_ATTR_TYPE_CT))
              key = _attributeType+DELIM+attributeValue;
    we are running it on
    CC: Sun C++ 5.9 SunOS_sparc Patch 124863-04 2008/04/16
    compiled with these option
    -g0 -xspace -KPIC -D_XPG5 -m32 -xarch=sparcvis -mt -DNCURSES -DEXC_HANDLING -DRW_NO_BOOL
    and the created the execuatble with these option
    -i -z rescan -g0 -xspace -mt -D_XPG5 -m32 -xarch=sparcvis -mt -DNCURSES -DEXC_HANDLING -DRW_NO_BOOL -lpthread -lsocket -lnsl -ldl -lposix4 -lCrun -lCstd -lc -lm -lnsl -lsocket
    the dbx output
    t@1 (l@1) program terminated by signal SEGV (no mapping at the fault address)
    where -h
    Current function is Zone::AddAttributeValueAndCountryCode
    56 if ((_attributeType == ZONE_ATTR_TYPE_FC) ||
    (dbx) where -h
    current thread: t@1
    =>[1] Zone::AddAttributeValueAndCountryCode(this = 0x194c088, attributeValue = CLASS, attribSeq = 1, countryCode = CLASS, zoneSearchLocMap = CLASS), line 56 in "Zone.cpp"
    [2] ZoneLoader::Load(trans = CLASS, zoneList = CLASS, prZoneList = CLASS, zoneSearchLocMap = STRUCT, planningCompany = 0x1890f20), line 90 in "ZoneLoader.cpp"
    [3] ZoneManager::ZoneManager(this = 0x1933e28, shipperId = 1000, consDBConnection = CLASS), line 24 in "ZoneManager.cpp"

    I see you are compiling with -KPIC. Is the code going into a shared library?
    Run "ldd" on all the C++ shared libraries you create, and on the main program. You should see a dependency on /usr/lib/libCrun.so.1 and /usr/lib/libCstd.so.1, and no dependency on any other libCrun or libCstd.
    Do you have a particular reason for using -D_XPG5? Changing the Unix version presented by the system headers in /usr/include can sometimes create incompatibilities with the C++ headers and runtime libraries that are intended for the default Unix version.
    Are all of the object files created with the same options, especially the -mt option?
    If none of the above considerations raise any red flags, you might have run into a bug in the compiler or the C++ runtime libraries, or you might have a bug in your code that by accident does not show up in other environments.
    There is no way to evaluate whether you have a compiler or runtime library bug without a test case that demonstrates the problem.
    You might have heap or other data corruption in your program due to invalid pointer use, use of an uninitialized variable, reading or writing outside the bounds of an object, double deletion of an object, use of an object after it has been deleted. You might also have an MT programming error where a critical region is not properly guarded, or where a shared variable is not declared volatile.
    By accident, data can be read or written incorrectly, or a data-race condition can exist, but without causing program failure. A program containing these errors can appear to run successfully on one platform and fail on another, or on the same platform under other conditions.
    Running the program under dbx with Run-Time Checking enabled will show many of these errors.
    The Thread Analyzer can find data race conditions.
    If you think you have found a problem with the compiler or libraries, please file a bug report at
    [http://bugs.sun.com]
    with a test case that can be compiled and run to show the problem.

  • Concurrent Thread accessing the shared variable

    Hi All,
    I need help on following issue
    I am working on java program that will have about ~500 threads reading per minute List<Object> and ONE task thread which will reset the List<Object> every 4 hours.
    Let imagine this following class,
    public class Cache {
    private static  List< Object> m_cacheList = null;
    privates static final Cache instance = new Cache(new AraryList<Object>());
    public getInstance(return instance );
    private  Cache (Listc){
         m_cacheList = List< Object>;
    public List<Object>  getCacheList(){
         return m_cacheList;
    public List<Object>  refreshCacheList(List<Object>  newData){
    m_cacheList = m_cacheList;
    500 Read Tread
    List<Object> list = Cache. getInstance().getCacheList();
    // this will iterate
    for(Object obj ; list ){
       //do something
    1 Write Tharead  every 4 hr
    List<Object> newData = ��..
    Cache. getInstance().refreshCacheList (newData);Since the read rate is so high, I am thinking about using work �volatile� rather then full synchronization.

    This looks fine to me, volatile should work fine. The assignment of a new cache is atomic so should not interfere with the threads accessing the cache object.
    As good practice however I would recommend that you should not let the cache object out of the class (make it private and do not provide a method that returns it) so that you can control the access to it. If you return the cache object then it is possible that another class that accesses it may try to perform an operation that is not thread safe. For example if two threads get a reference to the same list and one is using the iterator while another thread modifies it (i know this is not the intention now, but you should code with future use in mind), then you will get a ConcurrentModificationException. The options here are either let the Cache class perform the function on the list and never return it, or return a copy of the list in the "getCacheData()" function.
    This way you are keeping the state of the class safely encapsulated inside the class and can control all modifications to it.
    Hope that helps
    Paul

  • A problem with accessing the public variable inside the function

    Hi,
    I have got this package and I get error 1120: 1120: Access of undefined property aa
    Could you explain why I get this error?
    package somepackage {
        import flash.display.DisplayObject;
        import mx.containers.Canvas;
        public class SoundPictureSigns extends Canvas {
            public var aa:int = 12;
            public function SoundPictureSigns():void {
            public static function setUpSignSizes():void {
                trace("aa="+aa); /// ERROR here: 1120: Access of undefined property aa
    Can you help?
    Regards

    When you write
    class C
        var v;
    you are defining a variable that lives inside each instance of C. In other words, you can write code like
    var c:C = new C();
    c.v = 1;
    If you don't have an instance, you can't access v.
    When you write
    class C
        static var v;
    you are defining a variable that lives inside the class itself, and you can access it without having an instance.
    Gordon Smith
    Adobe Flex SDK Team

  • Not able to access the Date variable in Bex report after SP upgrade

    Hell Experts,
    We have upgraded the support pack to 27 and after that we are not able to access date variable in Bex report.
    We are not able to restrict the Posting date on variable, we are getting the message "Operation failed! No detailed error information from backend available".
    Thanks
    Chetan

    Hi,
    carry out basic checks like RSRV for the field,query ,Infoprovider on which this query is based..
    Check whether there is any in consistent value in the posting date..
    check whether objects are active correctly..
    else serach for SAP note or raise OSS to SAP..
    Thanks and regards
    Kiran

  • How to access the JoinColumn variable directly in a Entity.

    I have the below two entities with @OneToMany relationship between them,
    Employee*
    @Entity
    @Table(name="EMPLOYEE")
    public class Employee {
         @Id
         int employee_id;
         String employee_name;
    Can I uncomment this ???
         //int emp_department_id;
         @ManyToOne
         @JoinColumn(name="emp_department_id")
         Department department;
    Department*
    @Entity
    @Table(name="DEPARTMENT")
    public class Department {
         @Id
         int department_id;
         String department_name;
         @OneToMany(mappedBy="department")
         Set<Employee> employeesSet;
    I only want to persist the Employee since I already have the Department data in Db,
    *1.But, if i uncomment emp_department_id and try to do this,*
                   Employee e1= new Employee();
                   e1.employee_id=1;
                   e1.employee_name="employee1";
                   e1.emp_department_id=1;
    I get,
    Internal Exception: java.sql.SQLException: ORA-00957: duplicate column name
    Error Code: 957
    Call: INSERT INTO EMPLOYEE3 (EMPLOYEE_ID, EMP_DEPARTMENT_ID, EMPLOYEE_NAME, emp_department_id) VALUES (?, ?, ?, ?)
         bind => [4 parameters bound]
    *2. Instead I have to do something like this,*
                   Department d= new Department();
                   d.department_id=1;
                   d.department_name="Engineering";
                   Employee e1= new Employee();
                   e1.employee_id=1;
                   e1.employee_name="employee1";
                   e1.department=d;
    Is there a way to uncomment Employee.emp_department_id and insert employee data using pt. 1 ???

    Hello,
    Yes you can uncomment out that line if you want the fk column value without having to travers the relationship. The problem you are hitting when you do is because you then have the "emp_department_id" field defined twice. The error you are getting is because EclipseLink is currently case sensitive by default, so the JPA defined column name default for the emp_department_id attribute of "EMP_DEPARTMENT_ID" isn't matching the @JoinColumn(name="emp_department_id") since they are different cases - you should change the @JoinColumn so it uses an upper case field name to be consistent, ie
    @JoinColumn(name="EMP_DEPARTMENT_ID") or set the EclipseLink eclipselink.jpa.uppercase-column-names property to true. This will then have the two fields match and will give you a more appropriate exception, that the field has two writable mappings.
    Then you need make one of them read-only by adding the insertable=false, updateable=false to the annotation. You probably want to change the relationship, and so I'd make the int as read-only.
    Best Regards,
    Chris

  • I need to access the quiz variable in Captivate 6

    Is there any way to set the final quiz score in CP6 using either an advanced action or by using AS3 in Flash?
    We use a lot of custom interactions that are created in Flash and we need to use the scores from those interactions as quiz scores. So far i haven't found a Captivate variable that I can set from Flash, to record a quiz score that can be reported to our LMS.
    Thanks,
    Jeff

    My suggestion would be that you look into coding your Flash interactions as Captivate Interactive Widgets.  That way you can assign the score in Captivate and just set the interaction up to either register Success or Failure to achieve the score.
    The WdigetFactory API is the most popular way to achieve this:
    http://www.infosemantics.com.au/widgetfactory/info

  • How can I run two different vi's in same project which are accessing same global variable with out effecting the speed of the execution of both the vi's

    Hi
    I have build an Labview project with FPGA target .  I have configured an FPGA VI and an host Vi to acquire data and logged the data to a file and stored the latest data in a global variable simultanously. I have configured one more VI in the same project  to access the global variable.  I have build a dll to access both the VI as functions in LabWindows/CVI code.  My task in CVI is to update configured GUI with latest data periodically and run the  host VI continously for a long time and log the data to a file. GUI should update for every one second with latest data for this I am using the second VI in which I am accessing the global varibale in which the latest data has been stored in host VI.

    Duplicate Post (go here)

  • Access object on the stage using an as3 widget

    I am trying to use a FlashPro as3 widget and Captivate 6, to toggle an image on the Captivate stage (hide/show) and can't find enough information on how to access the stage objects.
    I can use 
    var numKids:int = parent.parent.parent.numChildren() 
    to see the number of children (of the stage object?) , but can't seem to figure out how to hide or show the child objects (image, button or anything).
    My image names in my Captivate Project are Img_Einstein1 and Img_Einstein2.  They reside on a blank slide along with two buttons and another widget.
    I have looked at Tristen's web site and found a lot of useful information, but I guess I am just not putting it all together.  Because I am a contractor I can't use the Widget Factory or purchase outside widgets.
    Any help will be greatly appreciated!

    On 6 you don't have shared actions yet. I don't understand the explanation with 20 and 10. There are several examples of toggle buttons on my blog. For showing/hiding here a simple one:
    http://blog.lilybiri.com/blog-after-posterous-clickclick

Maybe you are looking for

  • How can I use fonts found in iDVD 08 in other programs?

    I created a DVD using 6.0 Themes, Pass Through in particular, by exporting a slideshow movie from iMovie 06 and it looks great. Thank you's to forum members for the help I needed to resolve issues. Deleting the plist files and burning at 2 times spee

  • How can I cancel a view from a specific material?

    hi all I need to delete a specific view from a specifil material (not the whole type). how can I proceed?

  • Iphone wont exit recovery

    So basically my iphone 4 was updated to ios 6 and worked fine but somehow now its in recovery mode... This iphone is/was not jailbroken. i tried clicking on restore with itunes but it says "The iphone could not be restored. This device is not eligibl

  • Dowloading Music onto iPod from different computers

    I have a PC & a laptop, each having different music on them...my question is, I had downloaded songs to my iPod mini & then later on plugged it into the laptop to download different songs & it erased all my music that was downloaded from the pc! Is i

  • Where is Modbus.cbx in the latest Lookout 6.0.2 fixes?

    I got an email from NI saying that there was a new set of fixes for 602, including a "fixed" Modbus.cbx... The files that un-zip are: hyper.cbx ipascii.cbx lkworks.cbx sqlexec.cbx Am I missing something here?