Displaying Numbers

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,
I am a new Frontpage user who is trying to do something about as basic as
you can get, yet can't seem to figure out how to do it.

Have a standard Frontpage 2003 web table retriving data from an SQL 2000 db
server table. All I want to do is get the numbers to display cooma separators
when people view the web page. For example instead of 100000 I would like
100,000 displayed. Can anyone tell me how to do this simple task or direct me
somewhere where I might learn how to do it? It seems so basic yet I cannot
seem to find out how it's done.

Thanks,
Pat
 
Is this an ASP page with ASP coding? If so then you would use

FormatNumber(yourvariable,numberofdigits) Ex:

FormatNumber(1000,2)
 
Hi Dave,

Yes it is an ASP page. Where would I insert that string. Is it in a cell
property field or do I need to go into the raw code and put it somewhere.

Thanx,
Pat
 
Hi Dave,

God I feel so inept at this. I built a whole website feeding 2500 people
running for a year now and I can't figure this out. It feels so rediculous.
Have you got a code snip of a simple table that would show me where to insert
that so that all the numbers format like that. I can't beleive I can't get
this right.

Thanx
Pat
 
Switch to Code View and SELECT ALL then copy and paste all the code into
your next reply so I can see where it goes (you can type GOES HERE where you
want it). Remember to delete any user names or passwords for your database
connection before you post the code.

--
David Berry
FrontPage Support: http://www.frontpagemvps.com/



Pat_Hughes_Com said:
Hi Dave,

God I feel so inept at this. I built a whole website feeding 2500 people
running for a year now and I can't figure this out. It feels so
rediculous.
Have you got a code snip of a simple table that would show me where to
insert
that so that all the numbers format like that. I can't beleive I can't get
this right.

Thanx
Pat
 
Hi Dave,
It seems like you would insert the format statement in the 'webots section'
like you do when you are trying to do a select distinct statement but it
doesn't take it there.

Anyway it was too big so I created a simple one cell query returning a count
value to a table in a cell cell.

Thanks
Pat

<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<title>CacTotal</title>
</head>

<body>

<table border="1" width="100%" id="table1">
<tr>
<td> </td>
<td>
<table width="100%" border="1">
<thead>
<tr>
<th ALIGN="LEFT"><b>CacTotal</b></th>
</tr>
</thead>
<tbody>
<!--webbot bot="DatabaseRegionStart"
s-columnnames="CacTotal,CACActive,CACSuspended,PSTotalActive,ACSTotalSites,ActiveACSSitesNotInCAC,ActiveCACSitesNotInACS,ACSSitesNotInPS"
s-columntypes="131,131,131,131,131,131,131,131" s-dataconnection="Onestop"
b-tableformat="TRUE" b-menuformat="FALSE" s-menuchoice s-menuvalue
b-tableborder="TRUE" b-tableexpand="TRUE" b-tableheader="TRUE"
b-listlabels="TRUE" b-listseparator="TRUE" i-listformat="0"
b-makeform="FALSE" s-recordsource="NADSummary_Master_Counts"
s-displaycolumns="CacTotal" s-criteria s-order s-sql="SELECT * FROM
NADSummary_Master_Counts" b-procedure="FALSE" clientside suggestedext="asp"
s-defaultfields s-norecordsfound="No records returned." i-maxrecords="256"
i-groupsize="0" botid="0" u-dblib="_fpclass/fpdblib.inc"
u-dbrgn1="_fpclass/fpdbrgn1.inc" u-dbrgn2="_fpclass/fpdbrgn2.inc" tag="TBODY"
preview="<tr><td colspan=64 bgcolor="#FFFF00" width="100%"><font
color="#000000">This is the start of a Database Results region. The region
will not work unless the page has a file extension of ".asp". The page must
be fetched from a web server with a web browser to display correctly; the
current web is stored on your local disk or network.</font></td></tr>"
startspan --><!--#include file="_fpclass/fpdblib.inc"-->
<% if 0 then %>
<SCRIPT Language="JavaScript">
document.write("<div style='background: yellow; color: black;'>The Database
Results component on this page is unable to display database content. The
page must have a filename ending in '.asp', and the web must be hosted on a
server that supports Active Server Pages.</div>");
</SCRIPT>
<% end if %>
<%
fp_sQry="SELECT * FROM NADSummary_Master_Counts"
fp_sDefault=""
fp_sNoRecords="<tr><td colspan=1 align=""LEFT"" width=""100%"">No records
returned.</td></tr>"
fp_sDataConn="Onestop"
fp_iMaxRecords=256
fp_iCommandType=1
fp_iPageSize=0
fp_fTableFormat=True
fp_fMenuFormat=False
fp_sMenuChoice=""
fp_sMenuValue=""
fp_sColTypes="&CacTotal=131&CACActive=131&CACSuspended=131&PSTotalActive=131&ACSTotalSites=131&ActiveACSSitesNotInCAC=131&ActiveCACSitesNotInACS=131&ACSSitesNotInPS=131&"
fp_iDisplayCols=1
fp_fCustomQuery=False
BOTID=0
fp_iRegion=BOTID
%>
<!--#include file="_fpclass/fpdbrgn1.inc"-->
<!--webbot bot="DatabaseRegionStart" endspan i-checksum="19797" --><tr>
<td>
<!--webbot bot="DatabaseResultColumn"
s-columnnames="CacTotal,CACActive,CACSuspended,PSTotalActive,ACSTotalSites,ActiveACSSitesNotInCAC,ActiveCACSitesNotInACS,ACSSitesNotInPS"
s-column="CacTotal" b-tableformat="TRUE" b-hashtml="FALSE" b-makelink="FALSE"
clientside b-MenuFormat preview="<font size="-1">&lt;&lt;</font>CacTotal<font
size="-1">&gt;&gt;</font>" startspan
--><%=FP_FieldVal(fp_rs,"CacTotal")%><!--webbot bot="DatabaseResultColumn"
endspan i-checksum="14077" --></td>
</tr>
<!--webbot bot="DatabaseRegionEnd" b-tableformat="TRUE"
b-menuformat="FALSE" u-dbrgn2="_fpclass/fpdbrgn2.inc" i-groupsize="0"
clientside tag="TBODY" preview="<tr><td colspan=64 bgcolor="#FFFF00"
width="100%"><font color="#000000">This is the end of a Database Results
region.</font></td></tr>" startspan --><!--#include
file="_fpclass/fpdbrgn2.inc"-->
<!--webbot bot="DatabaseRegionEnd" endspan i-checksum="62730" --></tbody>
</table>
<p> </td>
<td> </td>
</tr>
</table>

</body>

</html>
 
Back
Top