Hello,
Sure you can.
Cite from MSDN:
<xsl:if> - allows simple conditional template fragments.
<xsl:choose>
<xsl:when test=""> ...</xsl:when>
<xsl:when test=""> ...</xsl:when>
<xsl

therwise> ...</xsl

therwise>
</xsl:choose>
- provides multiple conditional testing in conjunction with the <xsl

therwise> and <xsl:when> elements.
The <xsl:when> children of the <xsl:choose> element are tested in order from top to bottom until a test attribute on one of these elements accurately describes conditions present in the source data or an <xsl

therwise> element is reached. Once an <xsl:when> or <xsl

therwise> element is chosen, the <xsl:choose> block is exited. No explicit break or exit statement is required.
In your case a little modification in xml file:
<FRAMES>
<DIMENSION>
<Height>200</Height>
<Width>400</Width>
</DIMENSION>
<FRAME>
<NAME>First Frame</NAME>
<SRC>first.html</SRC>
</FRAME>
<FRAME>
<NAME>Second Frame</NAME>
<SRC>second.html</SRC>
</FRAME>
</FRAMES>
and XSL file:
<xsl:stylesheet version="1.0" xmlns:xsl="
<xsl:template match="/">
<html>
<xsl:choose>
<xsl:when test="//DIMENSION/Width < 300 and //DIMENSION/Height < 300">
<body>This is not suitabale for frames.</body>
</xsl:when>
<xsl:when test="//DIMENSION/Width < 300">
<frameset>
<xsl:attribute name="cols"><xsl:value-of select="//DIMENSION/Height"/>,*</xsl:attribute>
<xsl:for-each select="//FRAME/SRC">
<frame>
<xsl:attribute name="src"><xsl:value-of select="."/></xsl:attribute>
</frame>
</xsl:for-each>
</frameset>
</xsl:when>
<xsl:when test="//DIMENSION/Height < 300">
<frameset>
<xsl:attribute name="rows"><xsl:value-of select="//DIMENSION/Width"/>,*</xsl:attribute>
<xsl:for-each select="//FRAME/SRC">
<frame>
<xsl:attribute name="src"><xsl:value-of select="."/></xsl:attribute>
</frame>
</xsl:for-each>
</frameset>
</xsl:when>
<xsl

therwise><body>Choose appropriate width or height.</body></xsl

therwise>
</xsl:choose>
</html>
</xsl:template>
</xsl:stylesheet>
I've tested with
Width 100, Height 200
Width 200, Height 400
Width 400, Height 200
Width 400, Height 400
The conditional operators are usual or, and, =, !=, <, <=, >, >=.
And any < and <= operators must be quoted according to XML 1.0 rules by using < and <=.
You have to have also first.html and second.html.
If you have any further questions please ask.