.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

How do I use xsl:choose?

Posted By:      Posted Date: September 25, 2010    Points: 0   Category :ASP.Net

In my XML document I have:

    <brandName registered="generic">RossValve</brandName>
    <category>heart valve</category>

    <brandName registered="McNeil">Tylenol</brandName>
    <category>pain relief</category>

This is my XSL document so far:

<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    xmlns:msxsl="urn:schemas-microsoft-com:xslt" exclude-result-prefixes="msxsl"
  <xsl:template match="/">


View Complete Post

More Related Resource Links

Cannot find ASP.NET tab on IIS6+2003,how to choose .NET framework 4.0?


Hi all,

I just wanna setup a .net framework 4.0 on my VPS for a new site. While I could not find the ASP.NET tab on properties. I did some research find some similar problems but haven't fixed it yet.

Any suggestion would helpful.



[C#] Database ".mdf" already exists. Choose a different database name.

Hi all, it's all day long that i'm fighting with this problem. And i'm getting quite upset! SHORT VERSION Why when i call DataContex.CreateDatabase() does SQLExpress 2008 say that the file already exist even if the file is completly wiped form the DISK!?!   LONG VERSION So, what i'm trying to do is damn simple. I'm developing a simple web application. To do that i've built a DBML file to use with LINQ. For development purpose i'd like to create a local DB. So here my code: string connectionString = ConfigurationManager.ConnectionStrings["PermissionsDatabase"].ConnectionString; Response.Write(connectionString); using (PermissionDataContext dataContext = new PermissionDataContext(connectionString)) { if (!dataContext.DatabaseExists()) { dataContext.CreateDatabase(); } }   And in the web.config the connection strin is: Data Source=.\SQLEXPRESS;AttachDbFilename=C:\Projects\AccessControl\WebSite\App_Data\permissions.mdf;Integrated Security=True;User Instance=True When the CreateDatabase() is called i get that Exception. Where the ____ do SQLServer keeps track of that file?! Why if the database already exists the DatabaseExists() return false?!   Moreover if i use this connection string: Data Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\permissions.mdf;Integrated Security=True;User Instance=True

Choose the right set with IIF

Hi all, I have created an web interface exposing the metadata of a cube to the user. The user can drag the Time dimension to the xaxis, 1 dimension to the y axis. I need to implement a YTD function so that i can see the data YTD. if the user drags in the month, then it will display the YTD up to that month. if the user drags in a year, then it will display the YTD up to December. That means that I need to implement a logic inside MDX to recognize what the user has put in as the time dimension, if it finds out that the depth of the time dimension is 1, i.e. [DateTime].[Calendar 2009] , then it automatically uses [DateTime].[Calender 2009].[December 2009], otherwise it will just use what ever supplied. I am not too good at MDX, I tried the following but it did not work, where {userinput} will be replaced by whatever the user has dragged into the xaxis: With Member TimeSet As IIF({userinput}.Level = 3, {userinput}.LASTCHILD, {userinput}) MEMBER MEASURES.YTDSUM AS SUM(YTD(TimeSet),[Measures].[Total Hours Of Work]) SELECT (YTD(TimeSet), {MEASURES.YTDSUM}) ON 0, (DESCENDANTS([Company Structure].[Structure].&[2002219],1)) on 1 FROM GX2; Thx alot

preferred method to choose where to place if condition for query

I have a design problem I could use some help determining how to code this problem.   I have a table with 3 fields, catCode, startDate and endDate. I am having trouble deciding how to query my DB based on the following...   By default a gridview will return all records that match the catCode selected from a dropdown list.   If the user checks a check box, only records are returned where.... startDate <= today AND endDate >= today   How can I apply the If condition to compare when the check box is selected? I used the wizard to build the select statment for the gridview, but I can switch that to a SP if that makes life easier.   Thanks for any and all help and suggestions.  

Choose Item from dropdown list and display in a separate URL ASP.NET

Hi, I've a dropdown list for departments (engineering, bio, chemistry,physics etc.) when somebody choose the departments from the dropdown list, it displays the opening closing time(hours) in a detailsview controls. I have separate homepage for these departments ( these are the static html pages and no way to send querystring value) and I want to link the hours for each department from the departmental homepage. When I choose the department from the DDL, everytime it's the same URL. How can I solve the problem  So that I can point the respective hours from the respective departments ?   Thanks in advance.    

how to choose between Shared Memory, Named Pipes, TCP/IP, VIA?

What protocol to choose? Or, Why are they so many? I am mostly interested in contexts: 1)  development on local machine 2) development from remote machine (having SQL Server on another machine)  3) Production 4) what else should I bother/know about? I am developer, mostly using Developer Ed. mostly locally on Windows XP Pro SP3, and really had never bothered which protocol was used as far as connection was being successful. And I had never had any troubles to bother looking and choosing between protocols Why and when should I bother to choose between protocols for development?

Sharepoint 2010: Editing My Profile:Choose Picture gives errors

Hi, I've got the User Profile Service Application up and running.  When I try to add my picture to my Profile by clicking on the Choose Picture button, it gives an error.  Any ideas?   Thanks.

Cannot choose language of word exporting document with Reporting

I am creating report (in word) with Reporting Services 2008. I can't find a way to specify the language of the document. It is always in english.

VS 2008 - Choose Items(Toolbox) - Missing Items

I am using Microsoft Visual Studio 2008 Professional Edition on Windows Vista Home Basic SP2 and when I am editing Visual Basic and want to add an item to the toolbox I click on Choose Items... and from that point I can't find important controls (items) like Windows Media Player or Adobe PDF Viewer. I have tried to reinstall and reset the toolbox and program. I can't find this problem anywhere in the web, please help.Regards!Rafal Chmiel, 12yrs

Nice way to ask user to choose a document and then list of recipients for a mail merge?


I'm building what could be described as a mail merger. A user chooses an email template, chooses a list of recipients, and the application performs a mail merge.

I could attach the workflow to contact lists, in which case I only need to ask the user for the email template to use.
I could attach the workflow to document lists, in which case I only need to ask the user for the recipients to sent to.

I decided though that I'd bring them to a starting page and let them choose both. But I've a horrid and barren looking aspx form.
Is there any nice way of letting them browse for the documents and contacts? At present I'm using a couple of dropdown lists listing all documents on the site, and all contact lists on the site, but it's a bit butt-ugly :D

I wrote a book :) http://www.amazon.com/Microsoft-Visual-Studio-2008-Programming/dp/0071604081

How to choose default install language? Setup start in english and comes in french on the next wizar


I have downloaded the SharePointServer in english. (I do this in RDP for a Windows 2008 R2- 64bit) via a Windows7 64bit machine

When I launch the package for installation I can see the first screen, which contains the default links, (readin... Pre Requisites, etc..)

but when I launch Sharepoint Installation it come in FRENCH.

Our regional settings are in french but the OS is in english and there is no language pack installed.

How to proceed to get a prompt for a language prompt at Installation?



Report parameter values must be specified before the report can be displayed. Choose parameter value


Helllo...I am getting error "Report parameter values must be specified before the report can be displayed. Choose parameter values in the parameters area and click the Apply button." when I deploy the report in the SharePoint. The report works fine in the when I run in BIDS. we have two parameter in this report...Parameter #1 is tied filterd based on the user who is accessing the report and Parameter #2 is dependent on the value selected in Parameter #1.

Please let me know what I am doing wrong here? Is there any workaround to get past this message?

Thanks for help.


What to choose for upcoming project



As i have one upcoming project, i need to which is best

1) Asp.net MVC or asp.net 3.5 to develop let me know which is best and why its best..?

2) Is Asp.net MVC is available in Visual Studio 2005 and Asp.net MVC support sql server 2008 R2 ...?

3) Is Asp.net MVC framework is installed in hosting to run my web app..?

Xml Serialization: choose tag name for class instances in a generic ObservableCollection / List



I've creating a class called Graphics, deriving from a generic ObservableCollection where T is a custom class called Graphic :

public class Graphics : ObservableCollection<Graphic>
public Graphics()

Another class has a Graphics field. When I serialize to XML this class, this works fine :

  <Graphic id="1">
  <Graphic id="2">
  <Graphic id="3">

But I would like to have the following:

  <Gr id="1">
  <Gr id="2">
  <Gr id="3">

How can I process, I can't find a solution.

Please help.


When I Choose that file(ExcelFile),Immediatly It should be display in gridview


Dear Members,
     I have used fileUploadControl,
     I chooses one excel file,
     It contains Name,Age,Sex
     That details I already stored in DataSet

Choose a Data Source Type Wizard is blank


For some reason, I cannot choose a data source type. I tried rebooting the computer and same issue.

Any help is appreciated.


Choose right Collation. This doesn't work.




i'm using SQL Server 2008 R2 Latin1_General_CS_AS collation on database.

I need to load data from Latvia and Estonia. When i select data from loaded table i can see correct results. But when i am using WHERE condition to search record then it can't be found. For example:


select 'Value: ÕÜä'

Value: ÕÜä

These are Estonia symbols. And in Management Studio i can see what i have selected. But with Latvian is different


select 'Value: IRIELŠ'

Management Studio returns    Value: IRIELŠ

As you can see result is not the same. Maybe anyone know what Collation i should use, that everything would work fine?


EDIT: Tried use WHERE column = N'IRIELŠ' and then found.

But it is not good use N symbol between each string..


ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend