Forums
This topic is locked
Show/Hide
Posted 02 Dec 2001 09:54:11
1
has voted
02 Dec 2001 09:54:11 Frank Hierse posted:
Hello,I don't progress exactly. I try 2 small functions to get one function, but
it doesn't want so right.
First, I have:
<% IF (rs1.Fields.Item("OutOfStock".Value) = "True" Then %>
<b><font color=#FF0000>Out of Stock</font></b>
<% Else %>
<b><%= DoNumber((rs1.Fields.Item("Price".Value), 2, -2, -2, -2, -1) %>
EURO</b>
<%End IF %>
and once:
<% IF (rs1.Fields.Item("SoldOut".Value) = "True" Then %>
<b><font color=#FF0000>Sold Out</font></b>
<% Else %>
<b><%= DoNumber((rs1.Fields.Item("Price".Value), 2, -2, -2, -2, -1) %>
EURO</b>
<%End IF %>
The functions show the price or fade out him, in dependence of the
Yes/No-Fields in the DB.
Can I not summarize these two ones somehow? How this would have to look
approximate?
Greeting from Germany
Frank
Replies
Replied 02 Dec 2001 22:21:53
02 Dec 2001 22:21:53 Frank Hierse replied:
<BLOCKQUOTE id=quote><font size=1 face="Verdana, Arial, Helvetica" id=quote>quote:<hr height=1 noshade id=quote>
Hello,
I don't progress exactly. I try 2 small functions to get one function, but
it doesn't want so right.
First, I have:
<% IF (rs1.Fields.Item("OutOfStock".Value) = "True" Then %>
<b><font color=#FF0000>Out of Stock</font></b>
<% Else %>
<b><%= DoNumber((rs1.Fields.Item("Price".Value), 2, -2, -2, -2, -1) %>
EURO</b>
<%End IF %>
and once:
<% IF (rs1.Fields.Item("SoldOut".Value) = "True" Then %>
<b><font color=#FF0000>Sold Out</font></b>
<% Else %>
<b><%= DoNumber((rs1.Fields.Item("Price".Value), 2, -2, -2, -2, -1) %>
EURO</b>
<%End IF %>
The functions show the price or fade out him, in dependence of the
Yes/No-Fields in the DB.
Can I not summarize these two ones somehow? How this would have to look
approximate?
Greeting from Germany
Frank
<hr height=1 noshade id=quote></BLOCKQUOTE id=quote></font id=quote><font face="Verdana, Arial, Helvetica" size=2 id=quote>
Thanks for your help <img src=../images/dmxzone/forum/icon_smile_wink.gif border=0 align=middle>
This works fine:
<% IF (rs1.Fields.Item("OutOfStock".Value) = "True" Then %>
<b><font color=#FF0000>Out of Stock</font></b>
<%End if %>
<% IF (rs1.Fields.Item("SoldOut".Value) = "True" Then %>
<b><font color=#FF0000>Sold Out</font></b>
<% End if %>
<% if (rs1.Fields.Item("OutOfStock".Value) <> "True" AND (rs1.Fields.Item("SoldOut".Value) <> "True" Then %>
<b><%= DoNumber((rs1.Fields.Item("Price".Value), 2, -2, -2, -2, -1) %> Euro</b>
<%End IF %>
Frank
Hello,
I don't progress exactly. I try 2 small functions to get one function, but
it doesn't want so right.
First, I have:
<% IF (rs1.Fields.Item("OutOfStock".Value) = "True" Then %>
<b><font color=#FF0000>Out of Stock</font></b>
<% Else %>
<b><%= DoNumber((rs1.Fields.Item("Price".Value), 2, -2, -2, -2, -1) %>
EURO</b>
<%End IF %>
and once:
<% IF (rs1.Fields.Item("SoldOut".Value) = "True" Then %>
<b><font color=#FF0000>Sold Out</font></b>
<% Else %>
<b><%= DoNumber((rs1.Fields.Item("Price".Value), 2, -2, -2, -2, -1) %>
EURO</b>
<%End IF %>
The functions show the price or fade out him, in dependence of the
Yes/No-Fields in the DB.
Can I not summarize these two ones somehow? How this would have to look
approximate?
Greeting from Germany
Frank
<hr height=1 noshade id=quote></BLOCKQUOTE id=quote></font id=quote><font face="Verdana, Arial, Helvetica" size=2 id=quote>
Thanks for your help <img src=../images/dmxzone/forum/icon_smile_wink.gif border=0 align=middle>
This works fine:
<% IF (rs1.Fields.Item("OutOfStock".Value) = "True" Then %>
<b><font color=#FF0000>Out of Stock</font></b>
<%End if %>
<% IF (rs1.Fields.Item("SoldOut".Value) = "True" Then %>
<b><font color=#FF0000>Sold Out</font></b>
<% End if %>
<% if (rs1.Fields.Item("OutOfStock".Value) <> "True" AND (rs1.Fields.Item("SoldOut".Value) <> "True" Then %>
<b><%= DoNumber((rs1.Fields.Item("Price".Value), 2, -2, -2, -2, -1) %> Euro</b>
<%End IF %>
Frank