Showing posts with label xml. Show all posts
Showing posts with label xml. Show all posts

Monday, February 26, 2007

How To: Read Profile outside of ASP.NET

first of all thanks to daniel larson with his blog entry :-)

in case you're using your own classes and not just properties then here a small overview what you need to do:


namespace YourNameSpace.Profile.Extension
{
///


/// UserAddress contains the users address information,
/// this class is used in the profile .net 2.0 approach
///

[Serializable]
public class UserAddress
{
public UserAddress() { }

#region Property: Street
private string street;

///
/// Gets/sets the Street
///

public string Street
{
[System.Diagnostics.DebuggerStepThrough]
get { return this.street; }

[System.Diagnostics.DebuggerStepThrough]
set { this.street = value; }
}
#endregion


... all you other stuff ....

the web.config looks like this:


<profile>
<properties>
<add name="UserAddress" type="YourNameSpace.Profile.Extension.UserAddress" serializeAs="Xml"/>

and finally in your code you run the following code lines:

ProfileBase profile = ProfileBase.Create(data.Login);

string street = (profile.GetPropertyValue("UserAddress") as Profile.UserAddress).Street;

Thursday, November 17, 2005

XSLT Debugging in Visual Studio 2005

Last view day's I have concentrate myself on xml in new environment 2005

have a look at the follwing very intersting links i have found on MSDN:

XML Tools Introduction

This article is an introduction to the XML Editor and the XSLT Debugger in Visual Studio 2005 (formerly known by the codename "Whidbey").

and also this one:

Building an XPath Visualizer with Windows Forms:

Monday, July 18, 2005

XML Visualizer for Visual Studio .NET 2003: Workspace Home

XML Visualizer for Visual Studio .NET 2003: Workspace Home

Thursday, March 31, 2005

Wednesday, September 24, 2003

You should pass XmlResolver to Transform() method

protected override void Render(HtmlTextWriter writer)
{
XPathDocument xDoc = new XPathDocument(Context.Server.MapPath(sourceFilePath) );

XslTransform xslt = new XslTransform();
xslt.Load( Context.Server.MapPath(transformFilePath) );
xslt.Transform(xDoc,null,writer);

}

now i got on "xslt.Transform(xDoc,null,writer);" those informations:

E:\Extend\Controls\Navigator.cs(67):
'System.Xml.Xsl.XslTransform.Transform(System.Xml.XPath.IXPathNavigable,
System.Xml.Xsl.XsltArgumentList, System.IO.TextWriter)' is obsolete: 'You
should pass XmlResolver to Transform() method'


It seems you are using version 1.1 or higher of .Net Framework.

This way of calling Transform method of XslTransform class
is indeed obselete in the new versions.

Visit the following url for the latest info in this regard

http://msdn.microsoft.com/library/en-us/cpref/html/frlrfsystemxmlxslxsltransformclasstransformtopic17.asp?frame=true


and one more article:

http://www.xmlforasp.net/CodeSection.aspx?csID=103

Shared Cache - .Net Caching made easy

All information about Shared Cache is available here: http://www.sharedcache.com/. Its free and easy to use, we provide all sources at codeplex.

Facebook Badge