Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C#
Hi
 
I want to create an XML from a XML using XSLT. The input xml would contain some tags that needs to be replaced or added in the output xml. I want write the XSL file for same can you please help me in this
 
e.g :
Input XML :
<add name="ABC" connectionstring="Data Source=abc;Initial Catalog=abc;Integrated Security=SSPI" />
 
Output XML generated using XSLT :-
<configuration>
  <connectionstrings>
    <add name="abc" connectionstring="Data Source=abc;Initial Catalog=abc;Integrated Security=SSPI" />
  </connectionstrings>
  <system.web>
    <membership defaultprovider="abc" userisonlinetimewindow="20">
      <providers>
        <clear />
        <add name="abc" type="aabc.BusinessObject.<?xml version=" 1.0="?><br mode=" hold=" /><configuration><br mode=" abc=" connectionString=" data="" source="abc;Initial" catalog="abc;Integrated" security="SSPI"/">
  
  <system.web>
    <membership defaultprovider="abc" userisonlinetimewindow="20">
      <providers>
        <clear />
        <add name="abc" type="aabc.BusinessObject.abc" passwordformat="Encrypted" connectionstringname="abc" enablepasswordretrieval="true" enablepasswordreset="false" requiresquestionandanswer="false" writeexceptionstoeventlog="true" minrequiredpasswordlength="5" minrequirednonalphanumericcharacters="0" requiresuniqueemail="false" />
      </providers>
    </membership>
  </system.web>
</configuration>
"passwordFormat="Encrypted" connectionStringName="abc" enablePasswordRetrieval="true" enablePasswordReset="false" requiresQuestionAndAnswer="false" writeExceptionsToEventLog="true" minRequiredPasswordLength="5" minRequiredNonalphanumericCharacters="0" requiresUniqueEmail="false"/>
 
Please help me in this. Waiting for your response.
 
Thanks.
 
[Edit]Pre tags added, but don't know how to format the last part, so kept it inside code blocks.[/Edit]
Posted 6-Dec-12 23:38pm
v2
Comments
Sergey Alexandrovich Kryukov at 7-Dec-12 15:25pm
   
Not a question. You would need to show your code, not just output. You would also need to describe your goal, and tell us: 1) what did you expect to get; 2) what did you observe, 3) why do you think your result is wrong; all of the above should come with appropriate samples.
--SA

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

A couple of tutorial sites to get you started.
 
http://www.w3schools.com/xsl/xsl_languages.asp
http://webdesign.about.com/od/xslt/a/xslt-tutorial-1.htm
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



Advertise | Privacy | Mobile
Web03 | 2.8.140814.1 | Last Updated 9 Dec 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100