473,385 Members | 1,647 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

how to parse deeper nested tags in custom control

SEB
can any one please redirect me to how to use control builder class to parse
the following case (or any other method)
<mycustomcontroltag>
<item attribute1="x" attribute2="y" ......>
<subitems>
<item attribute1="xx" attribute2="yy" ......>
<subitems>
more deeper nested tags can be here
</subitems>
</item>
</subitems>
</item>
more item tags with deeper nested sub tags can be here
</ycustomcontroltag>
Nov 25 '05 #1
2 2112
I'd suggest looking into the various attributes that control the paraser
such as ParseChildren and PersistenceMode. With those 2 I think you can get
the nesting you're looking for there. Also, I'd suggest checking out "Developing
Microsoft ASP.NET Server Controls and Components", Nikhil Kothari, Vandana
Datye:

http://www.amazon.com/gp/product/073...books&v=glance

-Brock
DevelopMentor
http://staff.develop.com/ballen
can any one please redirect me to how to use control builder class to
parse
the following case (or any other method)
<mycustomcontroltag>
<item attribute1="x" attribute2="y" ......>
<subitems>
<item attribute1="xx" attribute2="yy" ......>
<subitems>
more deeper nested tags can be here
</subitems>
</item>
</subitems>
</item>
more item tags with deeper nested sub tags can be here
</ycustomcontroltag>

Nov 26 '05 #2
SEB
Brock,
You are totalement right.
I just added [ParseChildren(true)] [PersistChildren(false)] to both classes
and
[PersistenceMode(PersistenceMode.InnerProperty)] to the properties and it
worked

Thanks a lot.

by the way i could not registered in your blog, is it possible or not?

"Brock Allen" wrote:
I'd suggest looking into the various attributes that control the paraser
such as ParseChildren and PersistenceMode. With those 2 I think you can get
the nesting you're looking for there. Also, I'd suggest checking out "Developing
Microsoft ASP.NET Server Controls and Components", Nikhil Kothari, Vandana
Datye:

http://www.amazon.com/gp/product/073...books&v=glance

-Brock
DevelopMentor
http://staff.develop.com/ballen
can any one please redirect me to how to use control builder class to
parse
the following case (or any other method)
<mycustomcontroltag>
<item attribute1="x" attribute2="y" ......>
<subitems>
<item attribute1="xx" attribute2="yy" ......>
<subitems>
more deeper nested tags can be here
</subitems>
</item>
</subitems>
</item>
more item tags with deeper nested sub tags can be here
</ycustomcontroltag>


Nov 26 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

23
by: Charles Law | last post by:
Does anyone have a regex pattern to parse HTML from a stream? I have a well structured file, where each line is of the form <sometag someattribute='attr'>text</sometag> for example <SPAN...
1
by: mlv2312 | last post by:
Hi, I have experienced problems when dealing with nested anchors. I implemented some code to perform highlighting and specific anchors are used for the searched words. The problem is when the...
2
by: EDOnLine | last post by:
Is it possible to create Custom Tags in HTML and have ASP.NET replace these custom tags with info from my database before the page is returned to the client? For example.... In an aspx file I...
5
by: ~~~ .NET Ed ~~~ | last post by:
Hi, As you all know when an ASP.NET web form is created that will include web controls and such, it contains a FORM that that identifies the web form and its containing controls. Well, I have a...
3
by: Ward Bekker | last post by:
Hi, I need a regular expression that will match only the tags that have nested tags inside them: Input: <control id=1><control id=2></control></control><control id=3></control> Goal:
4
by: ThunderMusic | last post by:
Hi I want to do just like in the subject ... to have some text and tags between the start and end tags of my user-control. Is there a simple way of doing that? for instance, between the tags,...
0
by: waspfish | last post by:
Hi all, I am having problem parsing out a custom configuration that has nested tags, in much the same way appSettings or configSettings does. How do I get a hold of the collections of info nested...
1
by: Pupkin | last post by:
Hi, I was excited to use Microsoft Index Server, built into IIS, to set-up a site-search function, but it doesn't, by default, parse the ASP code of the pages it indexes. This makes it sort of a...
11
by: Stef Mientki | last post by:
hello, I need to translate the following string a = '(0, 0, 0, 255), (192, 192, 192, 255), True, 8' into the following list or tuple b = Is there a simple way to to this. (Not needed...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.