473,325 Members | 2,608 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,325 software developers and data experts.

Create dynamic control C# ASP.NET

Hi,

I am trying to create a webapplication which reads a Xml Document and
dynamically creates tables containing the values. The Xml Document is
created by a windows service I programmed. So if I need to change the
content, I can.

The format for the Xml document is as followed

<ROOT>
<SERVER Name = servername>
<STORAGEGROUP Name = SGname>
<STORE Name = Storename>
<USERS Count = intcount>
</USERS>
</STORE>
</STORAGEGROUP>
</SERVER>
<SERVER Name = severname>
......
........
.....
etc
</ROOT>
I want to create a table for Every Servernode and add
Storagegroup,Store,Users attributes.
Which control do I use and can someone provide some logic which can get
me started?
Thanks in advance!

Regards,

Mark

Nov 19 '05 #1
2 6390
You have two options as I see it ( maybe there are more )

1.) Manually Construct the table using the classes in the XML namespace and
build the HTML by opening the XML file and looping through the elements and
attributes and creating the HTML strings as you go.

Or. . .

2.) Use XMLT ( Transforms ) to transform the XML data into an HTML output.

I would recommend 2.) although both methods will really need you to do some
reading up, suggest you use the Help and Google to do some background
reading. Again there are classes in the system.Xml.Xsl namespace for this as
well.

Both approaches can be a little tricky, so experiment first with some very
simple XML files and then go from there.

--
Best Regards

The Inimitable Mr Newbie º¿º
"mpriem" <sp**@mpriem.com> wrote in message
news:11*********************@o13g2000cwo.googlegro ups.com...
Hi,

I am trying to create a webapplication which reads a Xml Document and
dynamically creates tables containing the values. The Xml Document is
created by a windows service I programmed. So if I need to change the
content, I can.

The format for the Xml document is as followed

<ROOT>
<SERVER Name = servername>
<STORAGEGROUP Name = SGname>
<STORE Name = Storename>
<USERS Count = intcount>
</USERS>
</STORE>
</STORAGEGROUP>
</SERVER>
<SERVER Name = severname>
......
.......
....
etc
</ROOT>
I want to create a table for Every Servernode and add
Storagegroup,Store,Users attributes.
Which control do I use and can someone provide some logic which can get
me started?
Thanks in advance!

Regards,

Mark

Nov 19 '05 #2
2.) Use XMLT ( Transforms ) to transform the XML data into an HTML output.

Should have read

2.) Use *XSLT* ( Transforms ) to transform the XML data into an HTML output.

--
Best Regards

The Inimitable Mr Newbie º¿º
"Mr Newbie" <he**@now.com> wrote in message
news:Oi**************@TK2MSFTNGP12.phx.gbl...
You have two options as I see it ( maybe there are more )

1.) Manually Construct the table using the classes in the XML namespace
and build the HTML by opening the XML file and looping through the
elements and attributes and creating the HTML strings as you go.

Or. . .

2.) Use XMLT ( Transforms ) to transform the XML data into an HTML output.

I would recommend 2.) although both methods will really need you to do
some reading up, suggest you use the Help and Google to do some background
reading. Again there are classes in the system.Xml.Xsl namespace for this
as well.

Both approaches can be a little tricky, so experiment first with some very
simple XML files and then go from there.

--
Best Regards

The Inimitable Mr Newbie º¿º
"mpriem" <sp**@mpriem.com> wrote in message
news:11*********************@o13g2000cwo.googlegro ups.com...
Hi,

I am trying to create a webapplication which reads a Xml Document and
dynamically creates tables containing the values. The Xml Document is
created by a windows service I programmed. So if I need to change the
content, I can.

The format for the Xml document is as followed

<ROOT>
<SERVER Name = servername>
<STORAGEGROUP Name = SGname>
<STORE Name = Storename>
<USERS Count = intcount>
</USERS>
</STORE>
</STORAGEGROUP>
</SERVER>
<SERVER Name = severname>
......
.......
....
etc
</ROOT>
I want to create a table for Every Servernode and add
Storagegroup,Store,Users attributes.
Which control do I use and can someone provide some logic which can get
me started?
Thanks in advance!

Regards,

Mark


Nov 19 '05 #3

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

Similar topics

7
by: Bil Muh | last post by:
Esteemede Developers, I would like to Thank All of You in advance for your sincere guidances. I am developing a software using Visual C++ .NET Standard Edition with Windows Form (.NET)...
3
by: MikeY | last post by:
Hi Everyone, I am working in C#, windows forms.My question is this. All my button dynamic controls properties are present and accounted for except for the"FlatStyle" properties. I can't seem to...
0
by: Andrea | last post by:
Hallo, i create controls dynamically on my webproject. most of the controls i create in the oninit-event and all worked wunderfull, but in the event-handling, e.g. the click-event of a button, i...
3
by: RSB | last post by:
Hi Every one Having tuff time creating web controls Dynamically. All i am trying to do is read a table and generate a list of ASP TEXT Box. So how do i create this Control dynamically and where...
3
by: Grey | last post by:
I know i can use placeholder control for dynamic create controls. but my requirement is i need to create multiple controls. when the user click the button, one textbox will be created. If user...
3
by: sck10 | last post by:
Hello, When a person subits my web page, I do a simple check (validation) and if there are any errors, I create a variable (strValidateText) and set that value to a label on the form. What I...
15
by: Amit D.Shinde | last post by:
I am adding a new picturebox control at runtime on the form How can i create click event handler for this control Amit Shinde
1
by: MaryamSh | last post by:
Hi, I am creating a Dynamic Search in my application. I create a user control and in Page_load event I create a dynamic dropdownlist and 2 dynamic button (Add,Remove) By pressing Add button...
0
by: MaryamSh | last post by:
Create Dynamic Dropdownlist Controls and related event -------------------------------------------------------------------------------- Hi, I am creating a Dynamic Search in my application. I...
15
by: lxyone | last post by:
Using a flat file containing table names, fields, values whats the best way of creating html pages? I want control over the html pages ie 1. layout 2. what data to show 3. what controls to...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
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...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

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.