How to load HTML into mshtml.HTMLDocumentClass with UCOMIPersistFile and my ignorance
[ 2010-02-11 12:26:26 | Author: sunrise_chen ]
What a weird one. I'm looking at the source for NDoc.Document.HtmlHelp2.Compiler.HtmlHelpFile. It uses the Microsoft.mshtml interop Assembly to load an HTML file into the HTMLDocumentClass for easy parsing.
It's code looks like this (DOESN'T WORK):
private
HTMLDocumentClass GetHtmlDocument( FileInfo f )...
Read More...
JPivot易用性修改
[ 2010-02-11 12:26:07 | Author: 狰狞的微笑 ]
mondrianQuery TAG 修改
scriplet 输出MDX查询支持
修改 TLD文件中 mondrianQuery TAG 的 body-content 为JSP
修改 MondrianOlapModelTag 的父类 com.tonbeller.jpivot.tags.OlapModelTag
为其加入 doStartTag 方法,返回EVAL_BODY_BUFFERED,
使之在 getBodyContent 之前先对 scriplet 进行处理。
ex:public int doStartTag(){return EVAL_BODY_BUFFERED;}
scriplet 输出MDX查询支持
修改 TLD文件中 mondrianQuery TAG 的 body-content 为JSP
修改 MondrianOlapModelTag 的父类 com.tonbeller.jpivot.tags.OlapModelTag
为其加入 doStartTag 方法,返回EVAL_BODY_BUFFERED,
使之在 getBodyContent 之前先对 scriplet 进行处理。
ex:public int doStartTag(){return EVAL_BODY_BUFFERED;}
ExternalInterface的call函数返回null的原因分析(AS2)
[ 2010-02-11 12:25:43 | Author: sunrise_chen ]
还是先研究一下AS2中的一个常见问题,在IE下和flash交互不正常的情况~!这些情况包括题目中的ExternalInterface.call函数调用JS函数不能得到返回值、ExternalInterface的callback函数不能被JS正常调用以及FlashVar不能正常传给flash,这些情况基本都是发生在IE下。这其实算是IE中的一个bug,以上问题的解决办法都是一样的:
首先保证<object>和<embed>标签都是存在的,有时候大家会忘记<object>标签,那么在除了IE以外的浏览器就会出问题了,呵呵。
其次<object>和<embed>标签中allowScriptAccess最好都设置为always
然后最关键的一点就是<object>标签中必须设置id属性,且<embed>标签中必须设置name属性,两个属性的值要一样。例如<object id="f_ckIE">...<embed ...
Read More...
首先保证<object>和<embed>标签都是存在的,有时候大家会忘记<object>标签,那么在除了IE以外的浏览器就会出问题了,呵呵。
其次<object>和<embed>标签中allowScriptAccess最好都设置为always
然后最关键的一点就是<object>标签中必须设置id属性,且<embed>标签中必须设置name属性,两个属性的值要一样。例如<object id="f_ckIE">...<embed ...
Read More...
OWC11.ChartSpace in office 2007
[ 2010-02-11 12:24:58 | Author: sunrise_chen ]
<P>Office 2003 加载项:Office Web Components<BR><A href="http://www.microsoft.com/downloads/details.aspx?familyid=7287252C-402E-4F72-97A5-E0FD290D4B76&displaylang=zh-cn">http://www.microsoft.com/downloads/details.aspx?familyid=7287252C-402E-4F72-97A5-E0FD290D4B76&displaylang=zh-cn</A>
<P>Microsoft Office 2003 Web Components Service Pack 1 (SP1) for the 2007 Microsoft Office System <BR><A ...
Read More...
<P>Microsoft Office 2003 Web Components Service Pack 1 (SP1) for the 2007 Microsoft Office System <BR><A ...
Read More...
JPivot中文支持
[ 2010-02-11 12:23:42 | Author: 狰狞的微笑 ]
老版本 1.3 将就着。。
中文化支持修改LOG
jpivot-1.3.0 src
fop-0.20.5 src
EXCEL 导出:
/WEB-INF/jpivot/table/xls_mdxtable.xsl
line 21 :content="text/html; charset=GBK"
PDF 导出:
* PDF 文件必须有中文字体支持,非编码转换可解决
生成宋体的XML描述文件
C:\Documents and Settings\tao.jie>java -classpath D:\workspace\jpivot\lib\fop.jar org.apache.fop.fonts.apps.TTFReader C:\WINNT\Fonts\simsun.ttc -ttcname "SimSun" c:\simsun.xml
...
Read More...
中文化支持修改LOG
jpivot-1.3.0 src
fop-0.20.5 src
EXCEL 导出:
/WEB-INF/jpivot/table/xls_mdxtable.xsl
line 21 :content="text/html; charset=GBK"
PDF 导出:
* PDF 文件必须有中文字体支持,非编码转换可解决
生成宋体的XML描述文件
C:\Documents and Settings\tao.jie>java -classpath D:\workspace\jpivot\lib\fop.jar org.apache.fop.fonts.apps.TTFReader C:\WINNT\Fonts\simsun.ttc -ttcname "SimSun" c:\simsun.xml
...
Read More...
Select data from an Excel sheet in MSSQL
[ 2007-06-22 15:10:08 | Author: sunrise_chen ]
select *
from openrowset('Microsoft.Jet.OLEDB.4.0'
,'Excel 8.0;HDR=YES;IMEX=1;DATABASE=d:\folder\excel.xls',Sheet1$)
-------NOTE------
Setting IMEX=1 tells the driver to use Import mode. In this state, the registry setting ImportMixedTypes=Text will be noticed. This forces mixed data to be converted to text. For this to work reliably, you may also have to modify the registry setting, TypeGuessRows=8. The ISAM driver by default looks at the first eight rows and from that sampling determines the datatype. If this eight row sampling is all numeric, then s...
Read More...
from openrowset('Microsoft.Jet.OLEDB.4.0'
,'Excel 8.0;HDR=YES;IMEX=1;DATABASE=d:\folder\excel.xls',Sheet1$)
-------NOTE------
Setting IMEX=1 tells the driver to use Import mode. In this state, the registry setting ImportMixedTypes=Text will be noticed. This forces mixed data to be converted to text. For this to work reliably, you may also have to modify the registry setting, TypeGuessRows=8. The ISAM driver by default looks at the first eight rows and from that sampling determines the datatype. If this eight row sampling is all numeric, then s...
Read More...
Send Mail with CDO
[ 2007-01-25 16:58:22 | Author: sunrise_chen ]
<!--METADATA TYPE="typelib" UUID="CD000000-8B95-11D1-82DB-00C04FB1625D" NAME="CDO for Windows 2000 Library" -->
<%
myMail = new ActiveXObject("CDO.Message");
myMail.Configuration.Fields.Item(cdoSendUsingMethod) = cdoSendUsingPort;
myMail.Configuration.Fields.Item(cdoSMTPServer) = "mail.mailserver.com";
myMail.Configuration.Fields.Item(cdoSMTPServerPort) = 25;
myMail.Configuration.
...<%
myMail = new ActiveXObject("CDO.Message");
myMail.Configuration.Fields.Item(cdoSendUsingMethod) = cdoSendUsingPort;
myMail.Configuration.Fields.Item(cdoSMTPServer) = "mail.mailserver.com";
myMail.Configuration.Fields.Item(cdoSMTPServerPort) = 25;
myMail.Configuration.
Read More...
Send Mail with JMail
[ 2007-01-25 16:44:22 | Author: sunrise_chen ]
Dim JMail
Set JMail = Server.CreateObject("JMail.Message")
JMail.Logging = true
JMail.Silent = true
JMail.MailServerUserName = "serverusername"
JMail.MailServerPassword = "password"
JMail.Charset = "utf-8"
JMail.From = "sender@xxx.com"
JMail.AddRecipient("recipient@xxx.com")
...Set JMail = Server.CreateObject("JMail.Message")
JMail.Logging = true
JMail.Silent = true
JMail.MailServerUserName = "serverusername"
JMail.MailServerPassword = "password"
JMail.Charset = "utf-8"
JMail.From = "sender@xxx.com"
JMail.AddRecipient("recipient@xxx.com")
Read More...







