Web访问Domino,如何下载服务器的磁盘上的Excel文件
我们现在正在开发一套基于Domino的bs应用,应用中有如下的一个功能,但是不知道怎么实现好:用户在ie端发起操作,Domino服务器根据用户的请求,在服务器上生成相应的Excel文件,然后在下载至ie端。
各位帮忙看看有什么好的解决方法? --------------------编程问答-------------------- 参考这个看看。
Sub Initialize
On Error Goto errmsg
Print |Content-Type:application/vnd.ms-excel;charset=GBK|
Print | <meta http-equiv="Content-Type" content="text/html; charset=GBK">|
Dim s As New notessession
Dim doc As NotesDocument
Dim db As NotesDatabase
Dim view As NotesView
Dim htmlstr As String
Set db = s.CurrentDatabase
Set view = db.GetView("Notes_GroupPersonList")
htmlstr = htmlstr & " <table border=1>"
htmlstr = htmlstr &" <tr>"
htmlstr = htmlstr &" <td colspan='8' align='center'> <b>"+DateStr$+"Rocket Service项目组通讯录"+" </b> </td>"
htmlstr = htmlstr &" </tr>"
htmlstr = htmlstr & " <tr>"
htmlstr = htmlstr & " <td width='8%' height='19' align='center' bgcolor='#666666'> <b> <font size='2' color='#ffffff'>姓名 </font> </b> </td>"
htmlstr = htmlstr & " <td width='8%' height='19' align='center' bgcolor='#666666'> <b> <font size='2' color='#ffffff'>所属公司 </font> </b> </td>"
htmlstr = htmlstr & " <td width='15%' height='19' align='center' bgcolor='#666666'> <b> <font size='2' color='#ffffff'>工作内容 </font> </b> </td>"
htmlstr = htmlstr & " <td width='10%' height='19' align='center' bgcolor='#666666'> <b> <font size='2' color='#ffffff'>电话 </font> </b> </td>"
htmlstr = htmlstr & " <td width='15%' height='19' align='center' bgcolor='#666666'> <b> <font size='2' color='#ffffff'>手机 </font> </b> </td>"
htmlstr = htmlstr & " <td width='15%' height='19' align='center' bgcolor='#666666'> <b> <font size='2' color='#ffffff'>邮箱 </font> </b> </td>"
htmlstr = htmlstr & " <td width='30%' height='19' align='center' bgcolor='#666666'> <b> <font size='2' color='#ffffff'>Skype </font> </b> </td>"
htmlstr = htmlstr & " <td width='30%' height='19' align='center' bgcolor='#666666'> <b> <font size='2' color='#ffffff'>到岗日期 </font> </b> </td>"
htmlstr = htmlstr & " <td width='30%' height='19' align='center' bgcolor='#666666'> <b> <font size='2' color='#ffffff'>服务方式 </font> </b> </td>"
htmlstr = htmlstr & " </tr>"
Set doc = view.GetFirstDocument
While Not(doc Is Nothing)
htmlstr = htmlstr+ " <tr>"
htmlstr = htmlstr+ " <td height='19' align='center' bgcolor='#ffffff'> <font size='2' color='#000000'>"+doc.CName(0)+" </font> </td>"
htmlstr = htmlstr+ " <td height='19' align='center' bgcolor='#ffffff'> <font size='2' color='#000000'>"+doc.CompanyName(0)+" </font> </td>"
htmlstr = htmlstr+ " <td height='19' align='center' bgcolor='#ffffff'> <font size='2' color='#000000'>"+doc.WorkSummary(0)+" </font> </td>"
htmlstr = htmlstr+ " <td height='19' align='center' bgcolor='#ffffff'> <font size='2' color='#000000'>"+doc.Phone(0)+" </font> </td>"
htmlstr = htmlstr+ " <td height='19' align='center' bgcolor='#ffffff'> <font size='2' color='#000000'>"+doc.Mobile(0)+" </font> </td>"
htmlstr = htmlstr+ " <td height='19' align='center' bgcolor='#ffffff'> <font size='2' color='#000000'>"+doc.EmaiAddress(0)+" </font> </td>"
htmlstr = htmlstr+ " <td height='19' align='center' bgcolor='#ffffff'> <font size='2' color='#000000'>"+doc.SkypeAddress(0)+" </font> </td>"
htmlstr = htmlstr+ " <td height='19' align='center' bgcolor='#ffffff'> <font size='2' color='#000000'>"+doc.OnBoardDate(0)+" </font> </td>"
htmlstr = htmlstr+ " <td height='19' align='center' bgcolor='#ffffff'> <font size='2' color='#000000'>"+doc.ServiceType(0)+" </font> </td>"
htmlstr = htmlstr+ " </tr>"
Set doc = view.GetNextDocument(doc)
Wend
htmlstr = htmlstr+ " </table>"
Print htmlstr
errmsg:
If Cstr(Erl) = "0" Then
Msgbox "代理程序成功执行完毕!"
Else
Msgbox "代理程序出错..出错行数为:" & Cstr(Erl) & "行!错误原因为:" & Error
End If
End Sub
补充:企业软件 , Lotus