changing value of text with the cursor

Hi you all

I need a help from your side

I have created a slider and change the size of the listview text with the cursor

Here is my code

 Slider {
                       id: slider
                        fromValue: 8.0
                        toValue: 16.0
                        value: 8.0
                        layoutProperties: StackLayoutProperties {
                            spaceQuota: 0.1
                        }
                        preferredWidth: 200.0
                        maxWidth: 250.0
                        preferredHeight: 20.0
                        visible: true
                        enabled: false
                        horizontalAlignment: HorizontalAlignment.Center
               onImmediateValueChanged: {

// descriptionText is the id of label
          descriptionText.textStyle.fontSize = FontSize.PointValue
           descriptionText.textStyle.fontSizeValue = immediateValue
                        }

                    }

/***********************************************************************//
i am adding data to listview using remote source

  Container {
            id: listviewContainer

            layout: StackLayout {

            }
            ListView {
                id: myListView1
                dataModel: dataModel1
                //{
                //  source: "asset:///models/xmldata.xml"
                //      }

                // Use a ListItemComponent to determine which property in the
                // data model is displayed for each list item
                listItemComponents: [
                    ListItemComponent {
                        type: "item"
                        Container {
                            rightPadding: 20
                            leftPadding: 20
                            horizontalAlignment: HorizontalAlignment.Center
                            verticalAlignment: VerticalAlignment.Center
                            layout: StackLayout {
                                orientation: LayoutOrientation.TopToBottom

                            }

                            Container {
                                topPadding: 40

                                horizontalAlignment: HorizontalAlignment.Fill

                                layout: DockLayout {

                                }
                                // The Item content container
                                Container {

                                    verticalAlignment: VerticalAlignment.Top
                                    horizontalAlignment: HorizontalAlignment.Right
                                    layout: StackLayout {
                                        orientation: LayoutOrientation.RightToLeft

                                    }

                                }

                            }

                            // Description text label
                            Label {
                                id: descriptionText
                             //
                           //     objectName: descriptionText
                                //  leftMargin: 20
                                horizontalAlignment: HorizontalAlignment.Right
                                verticalAlignment: VerticalAlignment.Top
                                text : ListItemData.des
                                textStyle.color: Color.create("#868686")
                                textStyle.textAlign: TextAlign.Justify
                                multiline: true
                                textFormat: TextFormat.Plain
                                textStyle.fontSizeValue: 8.0
                            }

                    }

                }
        ]

    }

    attachedObjects: [
        GroupDataModel {
            id: dataModel1

            // Sort the data in the data model by the "pubDate" field, in
            // descending order, without any automatic grouping
            sortingKeys: [ "date" ] //[ "pubDate" ]
            sortedAscending: false
            grouping: ItemGrouping.None
        },
        DataSource {
            id: dataSource1
            objectName: ""
            // Load the XML data from a remote data source, specifying that the
            // "item" data items should be loaded
            source:"http://10.121.10.139/simplehtmldom/getdescnews.php?newsid="+dataSource1.objectName

            query: "/news/property/"
            type: DataSourceType.Xml

            onDataLoaded: {
                // After the data is loaded, clear any existing items in the data
                // model and populate it with the new data
                dataModel1.clear();
                dataModel1.insert(data)
                myIndicator12321.setRunning(false);
                myIndicator12321.setVisible(false);
                //      dataModel.insert(data)

            }

                }
    ]
}

// in the end i am calling on creating complete

onCreationCompleted: {
        // When the top-level Page is created, direct the data source to start
        // loading data
        dataSource1.load();
    }

problem I am facing is, it does not find the descriptionText variable, which is the id of the label

can someone help?

OK, the problem is that listItemComponents attached to a control, such as ListView have their own context. ListItemComponent documentation refers to what I think. If you must do the following:

1. do you have a property that is defined as an attribute of the ListView

2 bind your fontSizeValue to listItemComponent tag to the ListView. Note, however, to do this, you need to get a reference to the ListView using your label ListItem.view is found in the container. Not obvious, I know.

3. do you have your cursor to update the property you have defined for the ListView.

Cursor---> p_font_size ListView property<---------->

Like this:

{To ListView
ID: myListView1
property real p_font_size: 10

 

listItemComponents:]
{ListItemComponent}
type: 'point '.
ID: sample

{Of container
ID: mainListViewContainer

{Label
ID: descriptionText

..........
textStyle.fontSize: FontSize.PointValue
textStyle.fontSizeValue: mainListViewContainer.ListItem.view.p_font_size

}

and elsewhere on your page

Slider {}
ID: slider

fromValue: 8.0
toValue: 16.0
value: 8.0
layoutProperties: {StackLayoutProperties}
spaceQuota: 0.1
}
preferredWidth: 200.0
maxWidth: 250,0
preferredHeight: 20.0
visible: true
enabled: true
horizontalAlignment: P

onImmediateValueChanged: {}
myListView1.p_font_size = immediateValue
}
}

I test it and it works. Please make this response as the solution if it works for you too :-)

Tags: BlackBerry Developers

Similar Questions

  • Text changes when you click with the text tool before editing

    I have a big file and think that there not saved properly or something. I tried quiting and relaunch Photoshop, but this does not help. Editing the text of other Photoshop files normally works.

    As soon as I click on any text with the text tool, as if I'm going to change or style of the text, the text changes instantly. The content and style of the text shall be replaced as soon as the cursor is placed anywhere in the string.

    The really weird thing is the updated text is text that appears elsewhere on the page. If I click on another text that she is now to who will also get automatically replaced by another text on the page. And it goes on and on. It is impossible to edit or any text style unless I have create a new text.

    I think that the file has arranged miss references to items that becomes apparent that I am editing.

    A way to fix this?

    Out of curiosity, do you have a Mac or a PC, Dan?

    And no, there is no known solution for the corruption in the PSD.

    -Christmas

  • Siri in him sending text with the value 'NULL '.

    When I say, "Siri, text my wife, 'X', ' Siri responds correctly,"here is your message to Jill: 'X'. "" "  "Ready to send it?"  I say 'Yes' and sends the message.  As soon as I get a text from my carrier saying the recipient of the message was invalid.  100% of the time, I see that Siri has sent a text with the value NULL.

    I tried to restart my phone.  I tried to remove and re-add my contacts.  Anyone else having this problem?  Someone knows how to solve?

    If it's by the carrier, you should contact them and see what they receive in return for their side. Ive had Siri send messages for me and I have never seen this one IOS.

  • try to change the text in a saved file, but it will not allow isolate me the text, place the cursor in the text box or simply go back to remove.

    try to change the text in a saved file, but it will not allow isolate me the text, place the cursor in the text box or simply go back to remove.

    Hello

    in what format save you your file? If it's a jpg file, then the text is compressed and unfortunately PS is telling things as they are. Even if you could change the text before you save, after having been saved in jpg format, the text is merged and is no longer editable.

    A good solution is to save the files as PSD files, photoshop files. In this case, all layers are saved uncompressed and so your text will appear in its own layer in photoshop. All you need to do in this case to change it is the result of a three-step procedure

    (1) select the right layer

    (2) take the text tool in the tools bar

    (3) mark and change your text

    So the crucial question is: in what format you save your file?

  • When I create a rectangle, I can not not change the shape of a rectangle with the cursor in illustrator CC 2014 for what?

    When I create a rectangle, I can not not change the shape of a rectangle with the cursor in illustrator CC 2014 for what?

    Xavigarcia,

    I'm afraid that have met you the Rectangle Live bug that is limited to the MAC versions from 10.7 and 10.8, but not of 10.9 (Mavericks) or 10.10 (Yosemite). If all goes well, the bug will be fixed soon.

    Thus, a switch for the Mavericks or Yosemite with a reinstall might be the way to solve it here and now.

    To get around it, in each case, it is possible to develop direct Rectangles to get the normal old shaped rectangles or Pathfinder > unit, or use the scale tool or the free transform tool.

    A more permanent way round that is to create normal old shaped rectangles, after running the free script created by Pawel, see this thread with download link:

    https://forums.Adobe.com/thread/1587587

  • I want to be able to move freely photos on a Windows Word page, but the photos keep snapping it back in place on the margins. Is it an alignment etc. function that I can disable so I can move photos with the cursor?

    I want to be able to move freely photos on a Windows Word page, but the photos keep snapping it back in place on the margins. Is it an alignment etc. function that I can disable so I can move photos with the cursor?

    I want to be able to move freely photos on a Windows Word page, but the photos keep snapping it back in place on the margins. Is it an alignment etc. function that I can disable so I can move photos with the cursor?

    =================================
    Change the text wrapping...

    In Word 2007... I'm going to... Format / dressing / thanks to...

    Then I can use the arrow 4 positions to drag photos anywhere
    I chose.

    If you want to drag the photos on the page...
    I don't know how to do this. John Inzer - MS - MVP - Digital Media Experience - Notice_This is not tech support_I'm volunteer - Solutions that work for me may not work for you - to proceed at your own risk

  • How to open the page with the cursor in a location set

    We have a page for a connection, and I want the page opens with the cursor positioned at this place.  Here's the code we which seems like it should work, but it doesn't.  It's a page someone else created, and as a new user of DreamWeaver, I don't know how it was created to begin with, so don't know how to fix (or start again).  Any advice?  Thank you

    <!--

    int position_cursor()

       {

    document. Login.txtUserName.focus ();

       }

    //-->

    < td height = "47" valign = "bottom" width = "187" > < input type = "text" name = 'txtUserName' / > < table >

    Above all, change it.

    <>

    on this subject.

    <>

    Then, the code that you have demonstrated should work.  However, to change this-

    document.getElementById('txtUserName').focus ();

    and this

    on this subject.

    And it will work.

    (Note: If this does not work, then please post the whole page code in a response.)

  • How to compare, present value: block.text_item with the value of data

    Hello
    Could you please tell me
    How to compare the current value: block.text_item with the corresponding database column value.
    I use form 10g

    It has block and there is a text element in this block.
    When I run the form and query the block (in a table), the: block.text_item show me any value it in the database.
    Now I add value in the: block.text_item to the existing value.

    now
    the: block.text_item contains the old + new added value
    While
    the database table contains the value 'old '.

    Now, with a click of button, I want to know what value I added

    Please can you me, is it possible without writing a select query?

    Hello

    Now, with a click of button, I want to know what value I added

    So you're saying always user will bring added value to the existing value. Because it will fail in a case. Let's say that
    Database value is = ABCD
    The user opens the form and he took the D and write E and now value is ABCE and length is always the same 4. There is therefore no need to add.

    In any case, you can know that the value of database at run time, there is a property for the element called DATABASE_VALUE. She gives the value that is in the database while you run the form before save. and you can use it like that...

    Trigger = WHEN-MOUSE-DOUBLE-CLICK on item level
    DECLARE
      vItemValue DATATYPE; -- Set the data type according to your desired field.
      vValueAdded DATATYPE; -- Set the data type according to your desired field.
    BEGIN
      vItemValue:=GET_ITEM_PROPERTY('ITEM_NAME',DATABASE_VALUE);  -- It will return you the database value in vItemValue variable.
      IF LENGTH(vItemValue)>LENGTH(:FORM_ITEM_NAME) THEN  -- It mean something change or added
        vValueAdded:=SUBSTR(:FORM_ITEM_NAME,LENGTH(vItemValue)+1);
        MESSAGE('Added value is : '||vValueAdded);  -- It will show you the added value.
      END IF;
      -- now suppose you want to show the old and new value in message not the added one
      -- Then no need of IF condition. You can just use message like this
      -- And i would prefer to use like this way
      MESSAGE('Old Value : '||vItemValue||'  New Value - '||:FORM_ITEM_NAME);
      MESSAGE('Old Value : '||vItemValue||'  New Value - '||:FORM_ITEM_NAME);
    END;
    

    Hope that's clear.

    -Clément

  • Windows xp black screen with the cursor

    Windows xp black screen with the cursor

    Hello

    You did it changes on the computer before the problem started?
    You are able to start the computer in safe mode?

    If you cannot start the computer in safe mode , and then follow the steps in the article mentioned below.

    Computer stops responding with a black screen when you start Windows XP:
    http://support.Microsoft.com/kb/314503

    Kind regards
    Afzal Taher - Microsoft technical support.
    Visit our
    Microsoft answers Feedback Forum and tell us what you think.

  • How to display very large text with the font size?

    I'm using html and css to display large text with the font size.

    Label {
        text: "Acit"
    }
    

    In the image below, it is the largest size, although I try to increase the value of the size of the font. Do you know how to display the largest font size?

    Thanhks

    You should be able to amplify it upward with scaleX/scaleY properties, although no doubt quality will suffer somewhat (but probably not significantly, for most people).

  • Why Windows 7 setting would deliver a black screen with the cursor visible before you load the Office?

    I had a very unusual event this morning.  I am running Windows 7 on a desktop computer.  On startup, I reached the login screen and proceeded to connect to my name.  Prior to loading the desktop computer, however, I was in a black screen with the cursor visible.

    1. I am able to load successfully under another user ID.
    2. I am able to boot in safe mode (with networking) using my own code.
    3. I did a system restore with no luck.  The problem persists.
    4. I don't think it's a driver issue because it would affect the two IDS and who does not.
    5. I have a touch screen and the white slider moves even in the place where I touch.  (what works)

    Issues related to the:

    1. what "custom" setting would result in a shift of the display of this type?

    2. If I go to Windows 8, will I have the opportunity to 'reset' my display options?  Or it will automatically upgrade to the wrong setting?

    Thank you.  Any guidance would be greatly appreciated.

    Thank you for your solution.

    The problem turned out to be the result of a combination of events.

    1. I did a change of media display a week ago but never restarted.
    2 MS did the periodic security update that rebooted the machine overnight.
    3. the update may have actually been in the middle of the installation when I got to my machine in the morning.
    4. when the screen has not responded, I restarted manually by pressing the power button.

    Ultimately, I was able to access Task Manager and found several instances of several components running.  When I "force stop" several of them, the office completed and I was in business.

    I still have the wide black border around my 'Live TV' screen in Windows Media Center, but that's another question for another time.

    Once again, thank you for the time spent to help me.

    Best regards

    Steve

  • How to set the size of text with the report generator

    Hello.

    I'm trying to set the size of the text with the report generator, but I find that I can't do this. Here is an example of the code that I use. Can someone tell me what I'm doing wrong please?

    Thank you, Alec

    I was generation from a word template.

    I hacked my version of the Toolbox to give me maunal indicator control "model? He had obtained his permenatly self stuck on "T". I exposed this flag outside the API, so I can control under certain weather conditions I may or may not use the model police.

    Does anyone know how to use this toolkit, or I did the right thing?

    Cheers, Alec

  • disable the box around cursor; box moves with the cursor

    suddenly, a transparent box appears around the cursor and moves with him.  Cannot delete the box that moves with the cursor... tried to personalize, mouse pointers, etc.  The default tab has been grayed out, so would not activate.

    Hello

    Looks like you have turned on the magnifying glass.

    Open Control Panel / ease of access Center.

    Click the make the computer easier to see.

    Scroll to the bottom and Remove the check mark from the option turn on Magnifier .

    Let us know the results.

    Concerning

  • Everytime I try to log in its just goes to a black screen with the cursor on my laptop Windows 8.

    * Original title: Admin Login

    On my laptop Windows 8, I can't connect to my admin user or even use my administrative password. Whenever I try to open a session in his will just a black screen with the cursor, and when I try to use my password it dims the screen and I can't do anything. Is there anyway that I can fix this?

    I solved the problem by resetting my laptop using the recovery mode.

  • Can change us static text to the interactive course?

    Hi Experts,

    Is it still to change static text to the interactive course?. During the execution of my lot my display is as follows,

    From.jpg

    I want to change that during the lanterns as follows,

    To.jpg

    Can this be possible to change/add static text to the interactive courses, if so please suggest me the approach to achieve this.


    Note: I want to change the static contents of the static form.

    Thank you

    Raman C.

    Hello

    Exit 12.1, the 'Interactive edition' parameter has been added to text box objects.

    When this option is enabled, you can change the text in interactive or data entry failure Studio box

Maybe you are looking for

  • Satellite Pro A30 - mode in Windows 98 and BACK suspension

    Everything works fine in Windows XP. Computer do not leave the suspend mode in Windows 98 or the DOS operating system. (Black screen after waking up)There is not any bios settings related to the control of food. The version of the bios is the most re

  • How to remove the password of BIOS on Satellite P300D 10v

    I put a password on the bios and I forgot it (stupid me!)... now I can't get into the bios... it tells me to type the password but I don't know.I tried to remove it with different programs to remove it but no one was successful, also I tried backdoor

  • Multitouch on the cliq/dext

    Hi, the video was taken from a nokia 5230 so quality is compromised. The video shows my dext using multi-touch. Pinch to zoon in the 3d Gallery froyo works and titles that require multi touch works as well. So much for motorola saying that Multitouch

  • "File permission error" during deleting files on Windows 7

    Hello I'm running Labview 2011 and have an application that has been developed to run on Windows XP. The part of the application deletes a file from the System32 folder, and then replaces it with another version of the same file (based on a specific

  • 17-e067cl Pavilion: Pavilion 17-e067cl RAM question

    Hello As stated, I have a Pavilion 17-e067cl, AMD A8 - 5550M Radeon HD 8550 G 8 GB DDR3L SDRAM (1 DIMM). Is there a performance advantage to activate the memory dual channel on this laptop? If so, how could achieve that? Correct me if I'm wrong, but