strange question Application: instance()

Hi all

I have this strange problem if the following code is executed as a slot:

void myapp::SomeSlot(QString result){        1. Label * pChild;
    2. pChild = bb::cascades::Application::instance()->findChild("testDialogLabelUser");
    3. pChild->setText(result);}

It works very well. But if I have another static member function invoke the above code, on the 2 nd line, pChild is 0 - and this is why the code does not work. This may be the cause of ideas? PS This is the static function:

void myapp::Wrapper_To_Call_Display(void* pt2Object, QString text)
{

    myapp* self = (myapp*) pt2Object;

      // call member
    self->SomeSlot(text);
}

Solved.

Apparently, the problem was that until the signal has been issued, I was showing the QML file that contained the testDialogLabelUser Label, this was however not the case more withth the static function...

Tags: BlackBerry Developers

Similar Questions

  • Strange question - width ListItem

    While developing applications, I noticed a strange question.

    When I draw list in qml item available, it's very nice on an excerpt:

    I put

    horizontalAlignment: HorizontalAlignment.Fill
    

    and the width of the list item fill all empty space, but when I check the list on Simulator it encapsulates the width of content?

    Does anyone know how to set the width of the listItem to fill all the space from left to right?

    To sum up,

    I want to have (and it looks like this on qml overview):

    but I get this (width of list point fits only the content):

    Thanks in advance.

    Hi, there may be simpler but for me it works using the spaceQuota:

    ListItemComponent {
        type: "item"
        Container {
    
            background: Color.Red
            Container {
                preferredHeight: 230     
    
                layout: StackLayout {
                    orientation: LayoutOrientation.LeftToRight
                }
    
                Container {
    
                    layoutProperties: StackLayoutProperties {
                        spaceQuota: 1
                    }
                 }
             }
         }
    }
    
  • Strange question - data double on table 12 c JDev

    Hello

    I have a strange question in my table. I use Oracle JDeveloper 12 c. In my page, I use 2 VO and a secondary has a problem with the display of data - it displays two times. Heard that I deleted the table and put it in my page and always the same problem.nodatatodisplay.png

    No matter if I have all the data to my record in the table primary or not, when there are data to display then it shows twice. I do not know it can help, but for more information table is located in the popup.

    Anyone have this problem?

    Kind regards

    WK

    You must specify exact jdev version (there are two versions of 12 c)

    I had this problem in 12.1.2(a il y a longtemps, et à cause de trop de bugs dans cette version je n'a pas pris la peine de trouver la raison), but it seems that this problem went to 12.1.3(at moins, pour mon application)

    Dario

  • This may seem like a strange question, but im trying to encode two buttons Flash Adobe, next and previous, however, when I put the thumb to the next scene and play on the next button and the previous scene and play on the previous button, it keeps switchi

    This may seem like a strange question, but im trying to encode two buttons Flash Adobe, next and previous, however, when I put the thumb to the next scene and play on the next button and the previous scene and play on the previous button, it keeps switching autour.

    If you have symbols of button on the stage to the next and previous, each of these symbols has an instance name with a listener event attached to it. The event listener is linked to a mandate. You can have a single event point to a function. So for example, if you have a next button and a click event that points to a function that says something like nextFrame(); and then you want to use the next button to point to a function that says something like nextScene(); you will need to use another instance of this next button and have this different instance to use a different event handler to point to a different function. Who help me?

  • Strange question USB CPU intense operations...

    So I was hitting this strange question lately with my R4 Aurora...

    During an intense application or game, the power of my keyboard & mouse will start go on and outside... fan start office turns up and down at the same time. The computer will continue to function, but as the USB power goes on and outside, I can't use the keyboard to stop. I can hit the power button on the computer and usually it stops just fine.

    Could be that your diet is more stressed.

    If you connect a USB2 Hub supplied with 50W power brick, what happens?

  • strange question use stop() to control a scenario after loadClip

    Hello, I have this strange question:

    I want to control the scenario of a swf file loaded with loadClip command.

    I wrote this code

    var loader: MovieClipLoader = new MovieClipLoader();

    loader.addListener (this);

    function onLoadComplete(_mc:MovieClip) {}

    _mc. Play()

    };

    loader.loadClip (swfname, _root.holder)

    function pause() {}

    _root.holder.stop)

    }

    function pause a button is used to stop playback of the loaded movieclip.

    strange thing is that stop() works when you test the movie by the flash application and plays from the projector. It DOES NOT WORK when he runs by embed code html in swf or swf directly.

    I checked a lot of time and the name of the 'container' is resolved, but the command does not work for his screenplay.

    thanx for help

    Daniele

    you wouldn't expect this stop() never work.  Once the loading starts, stop() no longer applies to the target of a loadClip (or loadMovie) method.

    to resolve, use the stop() on the first frame of the loaded swf file editing.

  • application instance will automatically unload?

    Hello

    I have an application on FMS. When a user connect to FMS, it will create an instance of the application. My question is that if all users that connect to him cut the instance will automatically unload?

    Yes - if all clients have disconnected from the application instance and 600 seconds have passed where he remained inactive - this instance of the application would be gc'ed leading to the application is unloaded. This is a configurable value - check MaxAppIdleTime application.xml or ApplicationGC in the Server.xml file

  • If the hard disk dies this affect router/WiFi?  I know that this seems to be a strange question.

    If the internal hard drive dies this affect router/WiFi?  I know that this seems to be a strange question.  Logically, they seems to be two independent functions.  However, since I do not understand how it works...

    I plan to spend my old airport extreme (about 7 years) at an airport new Time Capsule or Airport Extreme for better wi - fi range.

    Where the internal hard disk come into your Airport Extreme or Time Capsule dying airport upgrade?

    If the disc is dead, it will be not not to be replaced. This should be done first before to other devices.

  • Strange question, craps remaining after the system recovery on my windows xp desktop.

    Strange question, thank you for your comments!

    I just reinstalled windows xp on my old HP desktop HP Pavilion Media Center TV m7334n PC computer using the recovery on D partition. I expect that the installation would be a clean install. At the beginning of the recovery, I noticed the message on the screen saying that the backup was in process. After recovery, I could start my computer and realized that used disk space C was still as the space of C drive used before the restoration. I also noticed that there was a lot of pre-installed programs appears on the list of start - all programs. I never installed them after recovery. Many of them work. I expect a CLEAN installation. It is not clean at all.

    Furthur inspection on the system to reveal problems:

    1. I noticed that there are so many records under the program folder program files on the C drive (I have only one program fichiersDossier). I guess that the recovery process copied evething under my original forder of program files in this folder. I don't have anything I can use most of them because the links were scattered on a large number of them (I can't run the program of either start - all programs or folder directly). Is not at all a CLEAN installation.

    2. the recovery process also copy my document in the folder as well original user, see below to understand which is the original file of the user.

    3. originally, in my computer, I have two users (or 3 including comments), we came to HP-administrator with the computer, is another family.  On the computer I just recover, there are 3 users accompanying the recovery. They are administrator, hp-administrator and guest. I've renamed the family administrator. Now, under systems and settings, I see the user plus two records. They are administrator-YOUR-4DACD0EA75 and hp-administrator-YOUR-4DACD0EA75. YOUR 4DACD0EA75 sounds familiar. I can remember that I was lazy and that it has not changed the computer name during installation after recovery. YOUR 4DACD0EA75 is actually the default name given to me during the installation. I don't like this at all, so I changed the name of the computer and restarted the computer. The name of the computer was changed after the restartup, but ugly folder names remain the same and I can not even rename the ugly file name.

    I had done some restorations system on this computer before, I never noticed a problem like this before.

    1 have we seen this before?

    2 I forgot something?

    3. can I safely delete the original user profiles and records under the program folder program files?

    4. can I do a system recovery really CLEAN? I understand that the crapware will be installed during the system recovery. I'm ok with that, what I want is my pc to be recovered to the original state of the plant.

    5. I can read is no longer my 1st disc restore dvd. Is it possible to make another set of recovery disks?

    Thanks for reading my long message!

    1 have we seen this before? I saw something similar and other relief to be fixed.

    2 I forgot something? I don't think so. Just do an another hard drive recovery. Try again is all I can think about.

    3. can I safely delete the original user profiles and records under the program folder program files? I would'nt mess with her. Just do another hard drive recovery system.

    4. can I do a system recovery really CLEAN? I understand that the crapware will be installed during the system recovery. I'm ok with that, what I want is my pc to be recovered to the original state of the plant. Yes. Used hydrogen peroxide call destructive (or full) non-destructive vs. Make a full - restoration destructive to put things o back the way you bought it.

    http://support.HP.com/us-en/document/bph07145

    5. I can read is no longer my 1st disc restore dvd. Is it possible to make another set of recovery disks? By all means, out juice of repair disk and try to get it back. If you can repair the disk, make a copy or 2 whole and store them in a safe place. Otherwise, you will have to order them from somewhere on the Web... as a popular auction site.

    Thanks for reading my long message! You are welcome. Thanks for posting. I hope my answer helps.

  • Menus and application instance

    Hello

    I would like to know if someone can answer that:

    -If I want to add a menu item to the system, for example. My application should run in the background to handle events fired from my entry in the menu?

    -How to treat a single instance of my application if; the application has a graphic interface (a form) for configuration purposes and all the other features are dialog boxes?

    If you have any tips or articles explaining this, they would be welcome

    Thank you very much!

    Concerning

    Fab

    applicationmenuitems run in the context of the calling application instance. an in the address book menu item is executed by the application of address book.

    Take a look at the alternative entry points. You can launch multiple applications (such as the demons of the background) for a single project.

  • How to show the IOM application instance account password in the user interface

    Hello

    I would like to see IOM application instance account password.

    In OPAM, there is a "show password" button.

    Is it possible to do the same thing in IOM? If so, how?

    TIA

    Leo

    Customized using managed beans sound possible, you can try something similar to the example below:

    IOM Managed Bean example: password reset custom

    http://oraclestack.blogspot.in/2014/12/OIM-managed-bean-example-custom.html

    Or if its requirement quite normal for all users, it must be visible, then you can create a new field in your form to process and fill in the application form as pop prerequisite. But this is not recommended.

    ~ J

  • How to limit rights to an Application Instance per user?

    This excellent post, I learned that I we can assign a form field to the notion of the right of an Instance of the Application.

    Is it possible to restrict the list of rights to an Application Instance per user?

    I mean, is there a way to show for example all rights for a user and only one or two for user B when the user submitted a request for clearance of a specific Instance of the Application?

    If so, is it possible to model the business logic using only the IOM or should I write my own business logic module for that?

    TIA

    Leo

    Without custom code to set the users it will show for in the catalogue, the OOTB option is based on the membership of the organization.  In the Administration Console system, if you go to all instances of the application, you can see which organizations you have published the application.  The same goes for the rights of this forum, you can also see which organizations law is published on.  It is the only default way to do this.

    -Kevin

  • create the missing icon against the section of the form of the application instance

    Hi all

    I use OIM 11 g R2 PS2, and I see that create icon missing against the section of the form of the application instance. I am trying to create an instance of the application, and when I try to load the form, I don't see the icon 'create' at all.

    Is this a known problem. ?

    Thanks in advance.

    This changed in OIM 11 g R2 PS2 version. To create resources for the instance of the application, you must follow the steps below:

    1. connect the console to sysadmin

    2. create a sandbox

    3. go in Configuration--> Form Designer--> select the resource type--> click on the button create

    From there, you can create the form. Once the form is created, it will be visible in the Instance, application from which you can modify the same.

    HTH

  • Strange question: How do new dimensions go upwards, not downwards?

    Hey, I have a strange question. When I change the dimensions on a document and for example make it bigger, the bottom becomes higher in the direction down. But... How can I get, if you know what I mean? When I do the larger dimensions, why he cant increase upward?

    Does anyone know how to do this?

    The dimensioning of the scene is based on the top left corner, any change in the size will be push to the right or down.  You can't change what I know.

  • Failed to load application instance publishLive/live.

    Full registry error is (_defaultRoot_, _defaultVHost_): failed to load application instance publishLive/live...  Flash Admin Server and Flash Media Server running on the local computer.  During the test I get [NetConnection object]: NetConnection.Connect.Failed.  When I delete the main.asc file it works... What is happening out there?  I got this job at a time... my main.asc is below.

    var nc;
    var ns;
    NSR var;

    Called when a client connects
    application.onConnect = {function (customer)}

    accept the new connection to the client
    application.acceptConnection (client);

    Send a message
    trace (client.id + "is connected");
    }

    Called when a client disconnects
    application.onDisconnect = {function (customer)}
    trace (client.id + Date()) "disconnection at"+ new; "
    }


    Called when the client publishes
    application.onPublish = function (client, livestream) {}

    trace (livestream.name + "publishes on request" + application.name);

    This is an example of using the publishing feature multipoint to republish
    stream to another instance of the application on the local server.
    If (application.name == ' publishLive/live') {}

    trace ("republish the ustream stream");

    NC = new NetConnection();
    NC. Connect ("rtmp://1.616528.fme.ustream.tv/ustreamVideo/616528");

    NS = new NetStream (nc);

    called when the NetStream server has a status
    ns.onStatus = {function (info)}
    trace ("stream status:" + info.code)
    If (info.code == "NetStream.Publish.Start") {}
    trace ("publishes the stream");
    }
    }

    ns.setBufferTime (2);
    NS. Attach (livestream);
    NS. Publish (livestream.name, 'live');
    }
    }

    application.onUnpublish = function (client, livestream) {}
    trace ("cancellation of publication is" + livestream.name);
    }

    REGISTRATION
    application.onAppStart = function() {}
    This.NSR = Stream.get ("livestreamSS");  "<-this is the name of the instance of server-side"
    This.nsr.Play ("livestream",-1, -1);          "<-this is the name of the instance published"

    this.nsr.onStatus = {function (info)}
    If (info.code == "NetStream.Play.PublishNotify") {}
    application.startRecording ();
    }
    If (info.code == "NetStream.Play.UnPublishNotify") {}
    application.stopRecording ();
    }
    for (var I in info) {}
    trace ("i:" + i);
    trace ("info [i]:" + info [i]);
    }
    }
    }

    application.startRecording = function() {}

    infoObject var = Stream.getOnMetaData ("livestream");

    trace ("metadata for mavideo.flv :");

    for (i in infoObject) {}
    If infoObject [i] == {"record"
    trace ("start recording");
    This.NSR.record ();
    }
    }

    }

    application.stopRecording = function() {}
    trace ("stop recording");
    This.NSR.record (false);
    }

    In your FMS installation directory, look in the newspapers/_defaultVHost_/publishLive and see if there are errors in the files applicationXX. If there is a syntax error in your code, it will appear here.

Maybe you are looking for