The associated COM server does not support ActiveX Document embedding
winfrom 通过dsoframer实现读取excel文件报错:
System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.Runtime.InteropServices.COMException (0x80041103): The associated COM server does not support ActiveX Document embedding.
at DSOFramer._FramerControl.Open(Object Document, Object ReadOnly, Object ProgId, Object WebUsername, Object WebPassword)
--- End of inner exception stack trace ---
解决方法:
Open时把第三个progID加上就可以,
2. HRESULT Open([in] VARIANT Document, [in, optional] VARIANT ReadOnly,
[in, optional] VARIANT ProgId, [in, optional] VARIANT WebUsername, [in, optional] VARIANT WebPassword)
打开文档,可以是本地文件或者是服务器文件
参数:
Document 文档路径
ReadOnly 是否已只读模式打开
ProgId OLE类型
WebUsername 用户名(访问网络的文件时候,有可能需要)
WebPassword 密码
例子:
axFramerControl1.Open(sPath, true, "Excel.Sheet", "", "");//
DsoFramer1.Open "C:\TestBook.xls"
DsoFramer1.Open "C:\Plain.txt", , "Word.Document" //用Word来打开c:\plain.txt文件
DsoFramer1.Open "https://secureserver/test/mytest.asp?id=123", True, "Excel.Sheet", "MyUserAccount", "MyPassword"
3.HRESULT Save([in, optional] VARIANT SaveAsDocument, [in, optional] VARIANT OverwriteExisting,
[in, optional] VARIANT WebUsername, [in, optional] VARIANT WebPassword);
保存文件在本地
DsoFramer1.Save "c:\1.doc"
The associated COM server does not support ActiveX Document embedding的更多相关文章
- The server does not support version 3.0 of the J2EE Web module specification
1.错误: 在eclipse中使用run->run on server的时候,选择tomcat6会报错误:The server does not support version 3.0 of t ...
- svn 备份后双机同步热备失效,提示 W200007 target server does not support atomic revision property edits svynsync:E170009
svn 备份后双机同步热备失效,提示 W200007 target server does not support atomic revision property edits; consider u ...
- The server does not support version 3.1 of the JEE Web module specification.
使用MyEclipse2015打开MyEclipse2014编辑的项目,在服务器Tomcat 7部署时,提示"The server does not support version 3.1 ...
- Solution(项目部署):The server does not support version 3.0 of the J2EE Web module specification
1.错误: 在eclipse中使用run->run on server的时候,选择tomcat6会报错误:The server does not support version 3.0 of t ...
- navicat链接阿里云mysql报80070007: SSH Tunnel: Server does not support diffie-hellman-group1-sha1 for keyexchange
http://www.jianshu.com/p/200572ed066c navicat 链接数据库 使用navicat 的ssh通道连接数据库回遇到权限问题 错误代码如下: 80070007: ...
- Navicat---使用SSH远程连接到MySql,报错80070007: SSH Tunnel: Server does not support diffie-hellman-group1-sha1 for keyexchange
尝试使用Navicat远程连接到我在阿里云服务器上的MySql,通过SSH. 但是报错: 80070007: SSH Tunnel: Server does not support diffie-he ...
- <<< Tomcat运行提示The server does not support version 3.0
导入了一个项目,运行Tomcat出现此错误大致由于当前导入项目服务器不支持J2ee版本 原因是导入项目的Tomcat版本是6.0,Tomcat 6.0仅支持到Servlet 2.5,而此时项目是3.0 ...
- eclipse部署Tomcat6 : The server does not support version 3.0 of the JEE Web module specification
为项目添加tomcat 6,发现不能添加,原因如下 这是因为Tomcat6不能为JavaEE3.0版本服务,把项目的版本降低到2.5就可以了 现在可以部署了
- How to deal with "Could not find component on update server. Contact VMware Support or your system administrator." in Vmware.
手动将vmware安装目录下的vmtools镜像文件,windows.iso文件放到虚拟机的光区里. 再进入虚拟机的系统,在系统里打开光盘进行安装
随机推荐
- WCF系列教程之WCF服务宿主与WCF服务部署
本文参考自http://www.cnblogs.com/wangweimutou/p/4377062.html,纯属读书笔记,加深记忆. 一.简介 任何一个程序的运行都需要依赖一个确定的进程中,WCF ...
- Javascript之in操作符的用法
in操作符是js里面常用的一个操作符,下面是其几个常用的功能: 1.配合for语句循环遍历/迭代数组中的元素 2.配合for语句循环遍历/迭代集合中的属性 3.判断对象是否是数组的元素 4.判断对象是 ...
- Redis-集群 - 分片
Redis是一个基于内存的数据库,其不仅读写速度快,每秒可以执行大约110000的写操作,81000的读取操作,而且其支持存储字符串,哈希结构,链表,集合丰富的数据类型.所以得到很多开发者的青睐.加之 ...
- nginx图片处理笔记(http-image-filter-module、lua)
实验环境:CentOS 6.10 目标:1.使用http-image-filter-module进行图片变换:2.使用lua进行格式转换: 安装EPEL https://fedoraproject.o ...
- vuex requires a Promise polyfill in this browser
ie 浏览器访问 vue 项目(使用的vuex 状态管理组件)报错:vuex requires a Promise polyfill in this browser 处理办法: 1.npm insta ...
- 从父子组件的mounted钩子的同步执行与页面的异步渲染看nextTick的用法
最近复习vue的时候遇到了一个很奇怪的问题,我们直接从实例中看: <div id="app"> <child ref="child">& ...
- android应用执行需要root权限的shell命令
导入jar包:http://blog.csdn.net/zhw1551706847/article/details/77709142 RootTools:http://blog.csdn.net/st ...
- jsonp/ajax 自己的一些总结
data.json代码:[{"name": "张三", "age": 18}, {"name": "李四&qu ...
- .NET中的集合-ArrayList2
数组特点:类型同统一,长度固定 集合常用操作 添加 遍历 移除 ArrayList可变长度数组,使用类似于数组 属性:capacity(集合中可以容纳元素的个数,翻倍增长)count(集合中实际存放的 ...
- g2o error
/home/lzp/slamtest/graduationcode/p3/poseestimation/pose_estimation_3d2d.cpp: In function ‘void bund ...