473,473 Members | 1,480 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Processing an aspx xml-variable in xsl

Hi,

I want to build an aspx page with three combo box. Each combo
represents data from the database. I have three xml variables that I
build dynamically, let's say: var1, var2 and var3. I pass these
variables from my aspx program to my xsl program. If I put each
variable in a file: for example var1.xml, var2.xml and var3.xml. To
build my combo box from a file (for example var1.xml) like that

<xsl:variable name="combobox1"
select="document('../xml/var1.xml')"/>

this works very good. But I want to bind my variable var1 instead of
the corresponding file var1.xml.
Unfortunately I didn't know how to do it. (I know how to pass a
variable from aspx program to xsl program but I don't know how to open
this variable as an xml data structure.)

Can some one help me please?

Regards,

Djamila.

Oct 15 '06 #1
1 1216
<dj***********@gmail.comwrote in message
news:11*********************@i3g2000cwc.googlegrou ps.com...
Hi,

I want to build an aspx page with three combo box. Each combo
represents data from the database. I have three xml variables that I
build dynamically, let's say: var1, var2 and var3. I pass these
variables from my aspx program to my xsl program. If I put each
variable in a file: for example var1.xml, var2.xml and var3.xml. To
build my combo box from a file (for example var1.xml) like that

<xsl:variable name="combobox1"
select="document('../xml/var1.xml')"/>

this works very good. But I want to bind my variable var1 instead of
the corresponding file var1.xml.
Unfortunately I didn't know how to do it. (I know how to pass a
variable from aspx program to xsl program but I don't know how to open
this variable as an xml data structure.)

Can some one help me please?
Take a look at "XsltArgumentList for Stylesheet Parameters and Extension
Objects" in MSDN, at
http://msdn.microsoft.com/library/de...ionObjects.asp.

You can pass a node set or a fragment to the stylesheet. In particular, load
your XML variables into an XmlDocument (I presume that they are strings).
Then create an XPathNavigator on the XmlDocument and pass that as a
parameter to the stylesheet.

John
Oct 16 '06 #2

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

Similar topics

1
by: christof hoeke | last post by:
hi, i wrote a small application which extracts a javadoc similar documentation for xslt stylesheets using python, xslt and pyana. using non-ascii characters was a problem. so i set the...
1
by: webworldL | last post by:
Has anybody had any luck processing XHTML1.1 documents with xml.sax? Whenever I try it, python loads the W3C DTD from the top, then crashes saying that there's an error in the external DTD. All I...
9
by: Dominic Olivastro | last post by:
Hi all: I'm new to this newsgroup, and new to XML. We receive documents in XML, and I am trying to tear them apart to obtain information. I decided that, for my purposes, it would be fairly...
2
by: avishosh | last post by:
Hi, I'm getting the folowing error when tring to open xml file: -------------------------------------------------------------------------------- The system cannot locate the resource specified....
0
by: Oleg Paraschenko | last post by:
Hello, I'd like to introduce an article which might be of some interest: Reusing XML Processing Code in non-XML Applications HTML: http://uucode.com/texts/genxml/genxml.html PDF: ...
1
by: Chery | last post by:
I used dataset to merge 2 XML files having the same structure. I managed to merge these 2 XML files but how can I write a processing instruction to link the merged file to the existing XSL...
10
by: _(d)IEGO | last post by:
Hello everyone. I need help regarding the following: Given the following table: CREATE TABLE T1 (C1 nvarchar(10), C2 money) INSERT INTO T1 VALUES ('A',1) INSERT INTO T1 VALUES ('B',2) INSERT...
3
by: thomas.porschberg | last post by:
Hi, I want to read records from a database and export it in an arbitrary format. My idea was to feed a class with a String array fetched from the database and let this class fire SAX events as...
17
by: Luc Mercier | last post by:
Hi Folks, I'm new here, and I need some advice for what tool to use. I'm using XML for benchmarking purposes. I'm writing some scientific programs which I want to analyze. My program generates...
3
by: joelkeepup | last post by:
Hi, im trying to create a text email message using xslt template , the transforms work great, but the newlines and whitespace in the xslt doc are removed. Is there a setting somewhere I have...
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...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

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.