文档介绍:asp读取excel代码(举了四个 excel不同实例应用)
asp? a e ?excel ' ? ??(? u a ?????excel2? i ?
e a y o | o ?).txt37??3? e ??a??£??e - Y??? ???,????.. & 0 £ ???3?e ????e£??u ??' |? a - ?2? o u ???a a ?£ ???3? e ?? e ? ,, £ ?? i ?? o u e ?e ?o D)o a ???£
public property let createtype(byval val)
if val <> 1 and val <> 2 then
createtype_ = 1 else
createtype_ = val end if
end property
public property let data(byval val)
if not isarray(val) then
inerr(" ± i e y?Ye 6 ??6 D?6 ')
end if
exceldata = val
end property
public property get savepath()
savepath = savepath_
end property
public property get usedtime()
usedtime = usedtime_ end property public property let
sheetname(byval val) if not isarray(val) then if val = "" then
inerr(" ± i ??6 6 ??6 D?6
end if titlefirstline = true
else redim titlefirstline(ubound(val)) dim ik_
for ik_ =0 to ubound(val)
titlefirstline(ik_) =
true
next
end if sheetname = val
end property
public property let
sheettitle(byval val)
if not isarray(val) then if val = "" then
nerr(" ± i ± e i a6 6 ??6 D?6 ") end if
end if sheettitle_ = val
end property
rem ? i 2e e y?Y
private sub checkdata()
if savepath_ = "" then
nerr(" ± £ ' ??・??2?? u ?a??")
if not isarray(sheetname_)
then
if sheetname_ = "" then
inerr(" ± i ??2??u ?a??")
end if
end if
if createtype_ = 2 then
if not isarray(exceldata)
then
end if
inerr
(nEy^YO0Ee' ii6£-i»dOBI' O0Ee n)
end if
exit sub end if
if isarray(sheetname_) then if not isarray (sheettitle_) then
if sheettitle_ <> then
inerr (n±i±eiaEedAODi6£-i6e±iAu2 »500 i")
end if
end if
if not isarray (exceldata) then inerr(H±iEy^Yd0EeODi6n)
end if
end if
if isarray(sheetname_) then if getarraydim(exceldata)
<> 1 then
nerr(" ± i e y?Y??6 ?6 D?6 £ ?e y?Y??e ?' i ? o ? ????e o |???a o ?") else
if getarraydim(exceldata)
<> 2 then
nerr(" ± i e y?Y??e ?6 D?6 £ ?e y?Y??e ?' i ? o ? ????e o |???a?t") end if end sub rem e u 3e excel public function create() call checkdata()