Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4551910
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 21, 20262026-05-21T16:42:07+00:00 2026-05-21T16:42:07+00:00

I want to create an xml editor UI in flex.Basically I want to present

  • 0

I want to create an xml editor UI in flex.Basically I want to present the xml in a textarea.Users can then edit the xml and save it in database.Also,based on logged in user’s privilege,the level of editing allowed varies.A normal user can edit the attribute values as well as node values,but not attribute names and node names.

For eg: consider this XML

<users>
    <user id="1" country="aaaa">XASD</user>
    <user id="2" country="aaaa6">XASQWED</user>
    <user id="3" country="aaaa4">XASDRQQ</user>
</users>

Normal user can only edit id values(‘1′,’2′,’3’),country values(‘aaaa’,’aaaa6′,’aaaa4′) and user names(‘XASD’,’XASQWED’,’XASDRQQ’).But not node names(‘users’,’user’) and attribute names(‘id’,’country’).

I prefer to present the XML to the user as in an editor like interface and restrict editing there,rather than using a grid interface in which attribute names and values are listed in separate columns and enable editing for value column only.

Any idea how to achieve this selective editing(in a textarea?)?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-21T16:42:07+00:00Added an answer on May 21, 2026 at 4:42 pm

    This probably will be too complex to do in TextArea:

    • Subclass TextArea to access protected IUITextField
    • Parse XML yourself to find at which positions text is editable and at which is not
    • Pass CHANGE events from textfield if selection in editable area and prevent them otherwise
    • Reparse XML/update positions after each change

    Working with text positions this way might be very error-prone. Consider another approach:
    Present your XML in custom layout, where non-editable parts are Labels or Texts and editable are TextFields. Single tag might be HBox filled with these controls of FlowLayout in Flex4. TextFields must validate their content to keep XML valid.
    To create editor, iterate tags/attributes, create controls. To get XML back, iterate controls, looking at their type and create tags/attributes. The only thing you lose is text selection on multiple tags/lines.
    Update:
    Actually, it should be quite trivial to do:

                         <VBox>
    <tag>                  Label (<tag>)
        <subtag id="1"/>   HBox [ Label (<subtag ) Label(id=") TextInput(1) Label("/>) ]
    </tag>                 Label (</tag>)
                         </VBox>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to create a 2D array inside arrays.xml in android.Can someone point it
i want create XML file here is my following code String fileName = jasstech.xml;
I want to create an XML document from object list. How to handle Null
I want to create a XML file according to a given XSD schema file.
in my asp.net page i have register page. i want to create a xml
I need to create a PHP script that receives XML input via an HTTP
i have a following scenario that i have a products, categories and subcategories in
Is there a standard way that the tools used to generate the API documents
I have a table in SQL Server 2005 SP4; in which one of the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.