devo esportare dei record su un foglio execel
usando un codice di questo tipo:
codice:
act.WriteLine "<html xmlns:x=""urn:schemas-microsoft-com:office:excel"">"
act.WriteLine "<head>"
act.WriteLine "<!--[if gte mso 9]><xml>"
act.WriteLine "<x:ExcelWorkbook>"
act.WriteLine "<x:ExcelWorksheets>"
act.WriteLine "<x:ExcelWorksheet>"
act.WriteLine "<x:Name>"& u_title &"</x:Name>"
act.WriteLine "<x:WorksheetOptions>"
act.WriteLine "<x:Print>"
act.WriteLine "<x:ValidPrinterInfo/>"
act.WriteLine "</x:Print>"
act.WriteLine "</x:WorksheetOptions>"
act.WriteLine "</x:ExcelWorksheet>"
act.WriteLine "</x:ExcelWorksheets>"
act.WriteLine "</x:ExcelWorkbook>"
act.WriteLine "</xml>"
act.WriteLine "<![endif]--> "
act.WriteLine "</head>"
act.WriteLine "<body>"
DO while not rs.EOF
u_cell1=rs("codicecli")
u_cell2=rs("email")
if rs("piva")="" then
u_cell3="dato non presente"
else
u_cell3=rs("piva")
end if
act.WriteLine "<table>"
act.WriteLine "<tr>"
act.WriteLine "<td>"
act.WriteLine u_cell1
act.WriteLine "</td>"
act.WriteLine "<td>"
act.WriteLine u_cell2
act.WriteLine "</td>"
act.WriteLine "<td>"
act.WriteLine u_cell3
act.WriteLine "</td>"....
il problema è che se utilizzo solo i primi due campi tutto è ok
se inserisco il terzo u_cell3 ottengo questo codice di errore
codice:
Type mismatch: 'act.WriteLine'
perchè?
come posso prevenire la cosa?