Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

  • How to implement inline editing for a Label

    Similar to how you can inline edit a value in a grid, we'd like to have a label that when clicked will change to a text box to allowing editing of the label contents. What is the proper way to implement this (if it isn't already offered out-of-the-box)? Is it be done by setting the Edit Proxy Constructor? Can you reference any code examples?


    Thanks

  • #2
    Take a look at the set of examples under Dashboards & Tools: this shows several variations of editable UI. The nutshell for a Label in particular is that Labels, Buttons, Tabs etc support an interaction to edit their titles, and this become active as soon as you provide an EditContext and put them into Edit Mode.

    However, Dashboards & Tools is a large, sophisticated API designed to make it possible to edit complex components like TabSets and ListGrids. If your dynamic UI goals involve *just* making a Label editable, it may not be worth learning and adopting this system, since you can achieve label editing with a double click handler and just floating a TextItem over the Label.

    Comment


    • #3
      Floating a TextItem over the Label should suffice. Unfortunately, I'm having trouble finding an example of how to do that from the Showcase or on Google. Can you describe how to do that or point me to an example?

      Thanks

      Comment


      • #4
        You just create a single-item DynamicForm and place it at the coordinates of the Label.

        Comment

        Working...
        X