Welcome to the CrackBerry Forums Create Your Account or Ask a Question Answers in 5 minutes - no registration required!
Results 1 to 6 of 6
  1. Ninjatogo's Avatar
    CrackBerry Abuser

    Posts
    142 Posts
    Global Posts
    179 Global Posts
    Thread AuthorThread Author   #1  

    Question Cascades Object Absolute Referencing?

    Hi guys and girls,
    I'm building another test app using Cascades and ran into a wall.
    Basically I've got a multi tab interface, and each tab has a few text areas in it.
    I want to make reference to the text areas so that when a button on one tab is pushed it will copy+paste the text from another text area on another tab. Is this possible using Cascades? If so, can someone please explain how to do it?
  2. developit's Avatar
    CrackBerry Abuser

    Posts
    174 Posts
    Global Posts
    175 Global Posts
    #2  

    Default

    There is probably a reference to the cascades DOM (or whatever they are calling it) hanging off the global object. If you can't figure out how to access the global object, perhaps this classic "Hack" will work for you:

    http://supportforums.blackberry.com/...L/td-p/1906669

    Posted via CB10
    f forte.fm: An Rdio client for BB10
    Vist http://forte.fm/ in your BB10 web browser.
    Release thread: http://forums.crackberry.com/blackbe...ml#post8274508
    Thanked by:
    Ninjatogo (02-27-2013) 
  3. Guignards's Avatar
    CrackBerry Abuser

    Posts
    198 Posts
    #3  

    Default

    Hey, how is this going?
    did you get any further using developit's tip?

    what text are you wanting to copy?
    like a multi page submission form?
    tab1.textbox = name, DoB, etc..
    tab2. lable = name and DoB from tab 1
    is my understanding correct?
  4. superdirt's Avatar
    Banned

    Posts
    70 Posts
    #4  

    Default

    Yes it is possible as long as you aren't deleting your Tab objects after you move to another tab (I don't know why you would do that). Perhaps the easiest way is to connect a signal from some object to your qml holding the text fields and pass around the text.

    Posted via CB10
  5. Ninjatogo's Avatar
    CrackBerry Abuser

    Posts
    142 Posts
    Global Posts
    179 Global Posts
    Thread AuthorThread Author   #5  

    Default

    Sorry for the extremely late reply everyone (a bit busy with school),
    I have returned to my app to continue development, but I'm taking a slightly different approach. This time I'm using multiple sheets instead of tabs. I'm also trying to use signals to push the content of my textboxes around the multiple pages. After studying the cascades cookbook from Blackberry, I'm able to use signals to save strings to my first page from my second or third page, but that is after hitting the save button.

    My problem is trying to get a signal emitted when the app is started, emitting the current contents of the textboxes. My method is
    Code:
    signal open(string testtext, string testtext2)
    onCreationCompleted: { main.open(inn.text, outt.text) }
    on page 2 I had a reference to the signal, so if there is text in signal testtext, on creation that would be copied to a textbox on page 2. However, typing that would give me an unknown symbol error in the SDK, and the app refused to load at all in the simulator.
  6. Ninjatogo's Avatar
    CrackBerry Abuser

    Posts
    142 Posts
    Global Posts
    179 Global Posts
    Thread AuthorThread Author   #6  

    Default

    Quick update,
    since my last post I've completely rewrote the app, sorted the problem and much more.
    All thanks to caffeine and dedication (and superdirt and developit's posts ).

Similar Threads

  1. 8130 Object Push
    By BostLabs in forum BlackBerry Pearl 81xx
    Replies: 9
    Last Post: 02-20-2010, 10:43 AM
  2. do you guys absolutely love your 8700?
    By zoi in forum BlackBerry 87xx Series
    Replies: 19
    Last Post: 10-04-2008, 06:41 PM
  3. Uncaught exception: object already exists
    By rjpa in forum General BlackBerry Discussion
    Replies: 2
    Last Post: 07-05-2008, 04:56 PM
  4. javascript options object
    By ribayah in forum Developers Lounge
    Replies: 1
    Last Post: 04-14-2008, 08:21 AM
  5. Object Push Profile
    By jscheier in forum BlackBerry 87xx Series
    Replies: 0
    Last Post: 03-13-2008, 02:53 PM

Posting Permissions