<?xml version="1.0"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xsl:template match="/">	

<HTML>
<HEAD>
</HEAD>
<BODY background="datcard_bg.gif">

	<img src="PacsCube.gif" alt="PacsCube" border="0" WIDTH="155" HEIGHT="118"/>

	<table>

		<xsl:for-each select="PacsCube/Patient">
			<xsl:sort select="PatientsName"/>

			<tr>
				<td valign="center" nowrap="true"><font face="arial" size="1">
					<xsl:value-of select="PatientsName"/>
				</font></td>
				<td valign="center" nowrap="true"><font face="arial" size="1">
					  <strong>MR #</strong><xsl:value-of select="PatientID"/>
				</font></td>
			</tr>

			<xsl:for-each select="Study">
				<xsl:sort select="StudyDate" order="descending"/>
				<tr>
					<td align="left" colspan="2" valign="center" nowrap="true"><font face="arial" size="1">
					      
					<a>
						<xsl:attribute name="href"><xsl:value-of select="ResultsFile"/></xsl:attribute>
						<xsl:attribute name="target">frame_results</xsl:attribute> 
							<xsl:value-of select="StudyDate"/> --    
							<xsl:value-of select="Modality"/> --
							<xsl:value-of select="StudyDescription"/> 
					</a>
					</font></td>
					<br/>
				</tr>
			</xsl:for-each>
			<tr>
				<td colspan="2" >    </td>
			</tr>
		</xsl:for-each>
		
	</table>

</BODY>
</HTML>

</xsl:template>
</xsl:stylesheet>
