读书人

Print2flash 只能生成图片不能生成w

发布时间: 2012-02-22 19:36:55 作者: rapoo

Print2flash 只能生成图片,不能生成word,excel文档
我想弄一个在线生成FLASH 的功能,使用 Print2Flash的service,但只能将JPG,Gif的生成swf文档,无法处理.doc,.xls的文档,提示如下错误

HTML code
“/ASP.NET”应用程序中的服务器错误。 
--------------------------------------------

System.Web.Services.Protocols.SoapException: 服务器无法处理请求。 ---> System.Runtime.InteropServices.COMException (0x80004005): Before printing timeout expired
在 P2F.Server2Class.ConvertFile(String SourceFileName, String OutputFileName, Object Profile, Object BatchProcessingOptions, Object PrintingPreferences)
在 WebService.InternalConvert(String InputFileName, String OutputFileName) 位置 e:\2flash\print2flashsdk\Automation\Samples\ASP.NET\App_Code\WebService.cs:行号 25
在 WebService.ConvertStreamToStream(Byte[] inputFile, String FileName) 位置 e:\2flash\print2flashsdk\Automation\Samples\ASP.NET\App_Code\WebService.cs:行号 79
--- 内部异常堆栈跟踪的结尾 ---
说明: 执行当前 Web 请求期间,出现未处理的异常。请检查堆栈跟踪信息,以了解有关该错误以及代码中导致错误的出处的详细信息。

异常详细信息: System.Web.Services.Protocols.SoapException: System.Web.Services.Protocols.SoapException: 服务器无法处理请求。 ---> System.Runtime.InteropServices.COMException (0x80004005): Before printing timeout expired
在 P2F.Server2Class.ConvertFile(String SourceFileName, String OutputFileName, Object Profile, Object BatchProcessingOptions, Object PrintingPreferences)
在 WebService.InternalConvert(String InputFileName, String OutputFileName) 位置 e:\2flash\print2flashsdk\Automation\Samples\ASP.NET\App_Code\WebService.cs:行号 25
在 WebService.ConvertStreamToStream(Byte[] inputFile, String FileName) 位置 e:\2flash\print2flashsdk\Automation\Samples\ASP.NET\App_Code\WebService.cs:行号 79
--- 内部异常堆栈跟踪的结尾 ---

源错误:


行 50: [return: System.Xml.Serialization.XmlElementAttribute(DataType="base64Binary")]
行 51: public byte[] ConvertStreamToStream([System.Xml.Serialization.XmlElementAttribute(DataType="base64Binary")] byte[] inputFile, string FileName) {
行 52: object[] results = this.Invoke("ConvertStreamToStream", new object[] {
行 53: inputFile,
行 54: FileName});


源文件: c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\asp.net\54356c22\82a10ce2\App_WebReferences.a6j1ffdl.0.cs 行: 52

堆栈跟踪:


[SoapException: System.Web.Services.Protocols.SoapException: 服务器无法处理请求。 ---> System.Runtime.InteropServices.COMException (0x80004005): Before printing timeout expired
在 P2F.Server2Class.ConvertFile(String SourceFileName, String OutputFileName, Object Profile, Object BatchProcessingOptions, Object PrintingPreferences)
在 WebService.InternalConvert(String InputFileName, String OutputFileName) 位置 e:\2flash\print2flashsdk\Automation\Samples\ASP.NET\App_Code\WebService.cs:行号 25
在 WebService.ConvertStreamToStream(Byte[] inputFile, String FileName) 位置 e:\2flash\print2flashsdk\Automation\Samples\ASP.NET\App_Code\WebService.cs:行号 79
--- 内部异常堆栈跟踪的结尾 ---]
System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall) +431678
System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters) +204
localhost.WebService.ConvertStreamToStream(Byte[] inputFile, String FileName) in c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\asp.net\54356c22\82a10ce2\App_WebReferences.a6j1ffdl.0.cs:52
webservice.btnConvert_Click(Object sender, EventArgs e) in e:\2flash\print2flashsdk\Automation\Samples\ASP.NET\webservice.aspx.cs:72


System.Web.UI.WebControls.Button.OnClick(EventArgs e) +111
System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +110
System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +10
System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +13
System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +36
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1565




已将Microsoft Excel Application的组件服务,权限修改为network service,还是不行,搞得头都大了,有没有兄弟做过类似的功能,指导一下
机子安装的是office 2007

相关网页 http://print2flash.com/index.php

[解决办法]
没做过 帮顶
[解决办法]

[解决办法]
看看~~

[解决办法]
我的机器上试了一切都好,没有问题。

不知道你的环境配置是什么样的,所以很难看得出是什么问题,我把我操作的要点说一下吧,看是不是和你做的一样:
1。Print2Flash我装的是2.7.3商业版,SERVER mode
2。装完后在Option里面启用windows service,帐号我用的是.\administrator
3。我是直接用它sdk里面的例子,新建Web Site,然后指向Samples\ASP.NET目录
直接在vs里面运行,一切都ok了

我看你用的好像也是它自带的例子,你试过先不用webservice直接转换吗(就是Default.aspx里面的功能)?

[解决办法]
友情UP
[解决办法]
你是由于没有开机服务造成的,我刚实验过(我也在做,以前用的pdf2swf,发现这个好些)
以我XP的机器为例子,做如下操作:
1.控制面板->管理工具->组件服务
2.选择组件服务中的“服务(本地)”
3.加入你已经安装了print2flash version 2.7.3商业版 server mode,你可以在服务中发现Print2Flash这一项
4.右键点击Print2Flash->属性->选择登录->将登陆身份改为“本地系统帐户”(假如你的计算机不需要admin的帐号进行登录)
5.选择常规选项卡,将服务启动类型改为自动,然后服务状态改为启动,确定
6,新建website,打开你下载的例子,将Default.aspx作为首页,运行,一切OK!
[解决办法]
是的,office 2007/2003试过都可以,我用的也是非注册的,30天试用。

你用7#的方法检查下window服务里print2flash服务是否已启动?
[解决办法]
还是到http://print2flash.com/看看
[解决办法]
真是没办法,看上去我们其他人试下来都没有任何问题,你也许要找另外一台电脑装下试试,只有你的电脑不行的话可能要重新装下office了
[解决办法]
可能跟Windows Server的安全性有关系,如果是在网页上转,则会调用系统的进程,需要额外加权限,建议还是在本地做转换的程式
[解决办法]
没弄过,帮顶

读书人网 >asp.net

热点推荐