C
Coleen
Hi all 
I have a weird formatting problem with an HTML table that I am populating using VB.Net and HTML.
Here is the snippet of code for the cell I'm trying to format:
Dim ld_tot_pet_clean_fee_calc As Double
ld_tot_pet_clean_fee_calc = li_net_total_calc * 0.0075
ld_tot_pet_clean_fee = lo_misc_func.FormatMC(ld_tot_pet_clean_fee_calc, "D")
Session("tot_pet_clean_fee") = lo_misc_func.FormatMC(ld_tot_pet_clean_fee, "D")
Response.Write(lo_misc_func.FormatMC(ld_tot_pet_clean_fee_calc, "D"))
lo_misc_func.FormatMC calls a function that formats a variable into an Integer, Long or Double ("I", "L", or "D"). As you can see, I'm trying to format this as a double. The value for this calculation is 114.80 - I can not get the variable to format correctly as .80, it will not format the 0 after the 8. The format in the function is done as:
Case "D"
ls_format = Format(CDbl(ls_format), "##,##0.#0")
Return ls_format
I have never had problems with this format function before. The value of the cell is populated in the html of the table as:
<td class="table" style="FONT-WEIGHT: bold" width="75"><%=ld_tot_pet_clean_fee%></td>
The weird thing is that in another table with the exact same formatting and table structure, it works just fine. Also, as you can see, I've tried to make certain that it is working by doing a response.write - which works perfectly. Any suggestion as to how I can force it to format the 0?
TIA
Coleen

I have a weird formatting problem with an HTML table that I am populating using VB.Net and HTML.
Here is the snippet of code for the cell I'm trying to format:
Dim ld_tot_pet_clean_fee_calc As Double
ld_tot_pet_clean_fee_calc = li_net_total_calc * 0.0075
ld_tot_pet_clean_fee = lo_misc_func.FormatMC(ld_tot_pet_clean_fee_calc, "D")
Session("tot_pet_clean_fee") = lo_misc_func.FormatMC(ld_tot_pet_clean_fee, "D")
Response.Write(lo_misc_func.FormatMC(ld_tot_pet_clean_fee_calc, "D"))
lo_misc_func.FormatMC calls a function that formats a variable into an Integer, Long or Double ("I", "L", or "D"). As you can see, I'm trying to format this as a double. The value for this calculation is 114.80 - I can not get the variable to format correctly as .80, it will not format the 0 after the 8. The format in the function is done as:
Case "D"
ls_format = Format(CDbl(ls_format), "##,##0.#0")
Return ls_format
I have never had problems with this format function before. The value of the cell is populated in the html of the table as:
<td class="table" style="FONT-WEIGHT: bold" width="75"><%=ld_tot_pet_clean_fee%></td>
The weird thing is that in another table with the exact same formatting and table structure, it works just fine. Also, as you can see, I've tried to make certain that it is working by doing a response.write - which works perfectly. Any suggestion as to how I can force it to format the 0?
TIA
Coleen