473,396 Members | 1,706 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,396 software developers and data experts.

xslt stylesheets as assembly resources?

I like the idea of doing transforms on XML data via stylesheet, but I don't
like having to manage lots of .xslt files.

Is there a standardized approach to storing xslt strings in a .net
application?
Nov 12 '05 #1
2 2815
Hi arvee

Good question - start by setting the Build Action on your .xsl files to
embedded resource. Then you can get access to the files using the following
code:

Dim a As System.Reflection.Assembly =
System.Reflection.Assembly.GetExecutingAssembly
Dim s As IO.Stream = a.GetManifestResourceStream("AssemblyName.test.xsl ")
Dim sr As New IO.StreamReader(s)
MessageBox.Show(sr.ReadToEnd()

HTH

Nigel Armstrong

"arvee" wrote:
I like the idea of doing transforms on XML data via stylesheet, but I don't
like having to manage lots of .xslt files.

Is there a standardized approach to storing xslt strings in a .net
application?

Nov 12 '05 #2
You could store them in an assembly resource file, accessing them by a key.

--
Regards,
Dennis JD Myrén
Oslo Kodebureau
"arvee" <no****@spam.not> wrote in message
news:9tLod.5529$VG.2879@trndny07...
I like the idea of doing transforms on XML data via stylesheet, but I don't
like having to manage lots of .xslt files.

Is there a standardized approach to storing xslt strings in a .net
application?

Nov 12 '05 #3

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

Similar topics

3
by: Andy Dingley | last post by:
I've just started on a new project and inherited a huge pile of XSLT (and I use the term "pile" advisedly !) It runs at glacial speed, and I need to fix this this. Platform is MSXML 4 / ASP ...
8
by: Paulo Pinto | last post by:
Hi, I have already several XSLT stylesheets that make use of <xslt:include> "command". Now I wanted to make them a bit more modular but I'm stuck. I want to take out the generated HTML code...
2
by: Claudio Jolowicz | last post by:
How can XSLT stylesheets be used to edit, remove and add nodes specified by their position in the document tree? The XML document stores development tasks in a hierarchical way, i.e. tasks can...
6
by: Jan Roland Eriksson | last post by:
Archive-name: www/stylesheets/newsgroup-faq Posting-Frequency: twice a week (mondays and thursdays) Last-modified: March 10, 2001 Version: 1.95 URL: http://css.nu/faq/ciwas-mFAQ.html Maintainer:...
6
by: David Walker | last post by:
Hi, I have an XML file created by a third party in which an element with a simple content model has a text value consisting of 2 parts separated by a colon, like this ...
3
by: Darren Davison | last post by:
Hi, I have a documentation tool based on Java and XSLT that I want to add i18n capability to. There are around 8 stylesheets that process a Source generated by the Java code and some of the...
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...
1
by: Sergey Dubinets | last post by:
In effort to prioritize our goals we composed the list of random features each of them may add value to set of XSLT tools offered from Microsoft. 1. XSLTc (Compiler for XSLT...
2
by: TAL651 | last post by:
Hello, I'd like to use XML + XSLT to create a sortable table. The XML stores the data, and two different XSL stylesheets display the table, sorted in two different ways. What I don't understand...
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: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
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...

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.