Forums
This topic is locked
Converting Yes/No True/False data from MS Access
Posted 20 Feb 2006 22:58:24
1
has voted
20 Feb 2006 22:58:24 Eric Brunt posted:
I need to convert Yes/No True/False data from MS Access to Complete/Pending data in Dreamweaver MX. I am using ASP/Javascript only. I have the dynamic text <%=(Recordset1.Fields.Item("Done".Value)%> Where "Done" is the True/False data.I have seen various versions of the VBScript but none for JavaScript.
Any help would be much appreciated.
Replies
Replied 24 Feb 2006 12:11:27
24 Feb 2006 12:11:27 Michael Behan replied:
Do you just want to show the words complete or pending rather than true or false?
If this is the case you can do something like
<pre id=code><font face=courier size=2 id=code>
<%
if (Recordset1.Fields.Item("Done".Value == "true"
{
document.write("complete"
}
else
{
document.write("pending"
}
%>
</font id=code></pre id=code>
If this is the case you can do something like
<pre id=code><font face=courier size=2 id=code>
<%
if (Recordset1.Fields.Item("Done".Value == "true"
{
document.write("complete"
}
else
{
document.write("pending"
}
%>
</font id=code></pre id=code>
Replied 24 Feb 2006 17:19:05
24 Feb 2006 17:19:05 Eric Brunt replied:
Michael -
Thanks ever so much! That's about what I was looking for. Forgot the slight nuances between vb and java.
Eric
Thanks ever so much! That's about what I was looking for. Forgot the slight nuances between vb and java.
Eric