找回密码
 立即注册

QQ登录

只需一步,快速开始

zjl880

高级会员

4

主题

13

帖子

1081

积分

高级会员

积分
1081

活字格认证

zjl880
高级会员   /  发表于:2012-7-26 17:29  /   查看:5380  /  回复:4
我成功将RTF文件转换为二进制保存到数据库后,二次调出转换为RTF文件,加载出现如下提示,求助。
error.jpg (5.86 KB, 下载次数: 69)

4 个回复

倒序浏览
iceman
社区贡献组   /  发表于:2012-7-26 18:38:00
沙发
回复 1楼zjl880的帖子

你好,我这边没有重现问题,能否提供 Demo调试?
回复 使用道具 举报
zjl880
高级会员   /  发表于:2012-7-26 18:58:00
板凳

TX保存成功后二次加载RTF文件出错,求助

1、代码如下
  1. /// <summary>
  2.         /// 删除内容记录
  3.        /// </summary>
  4.        /// <param name="empID">医生编号</param>
  5.        /// <param name="empName">医生姓名</param>
  6.         public void MedicalContentDel(int empID, string empName)
  7.         {
  8.             if (this.textControl.Selection.Length == 0x00)
  9.                 return;

  10.             int currentLine = this.textControl.InputPosition.Line;
  11.             int currentColumn = this.textControl.InputPosition.Column;
  12.             int currentPage = this.textControl.InputPosition.Page;

  13.             int start = this.textControl.Selection.Start;
  14.             int length = this.textControl.Selection.Length;

  15.             this.textControl.Selection.Strikeout = true;
  16.             this.textControl.Selection.ForeColor = Color.Red;

  17.             //痕迹保留,记录删除内容
  18.             DeleteField delTextField = new DeleteField(this.textControl, this.textControl.Selection.Text, empID.ToString(), empName);

  19.             this.textControl.Selection.Start = start;
  20.             this.textControl.Selection.Length = length;
  21.             this.textControl.Selection.ForeColor = Color.Black;

  22.             this.textControl.Selection.Text = string.Empty;

  23.             if (currentColumn == this.textControl.Lines[currentLine].Length || currentColumn == this.textControl.Lines[currentLine].Length - 1)
  24.             {
  25.                 if (currentLine == this.textControl.Lines.Count)
  26.                 {
  27.                     this.textControl.InputPosition = new TXTextControl.InputPosition(currentPage, currentLine, currentColumn);
  28.                 }
  29.                 else
  30.                 {
  31.                     this.textControl.InputPosition = new TXTextControl.InputPosition(currentPage, currentLine + 1, 0);
  32.                 }
  33.             }
  34.             else
  35.             {
  36.                 this.textControl.InputPosition = new TXTextControl.InputPosition(currentPage, currentLine, currentColumn + 1);
  37.             }
  38.         }
复制代码


2、执行以上代码效果如下:
111.jpg (2.42 KB, 下载次数: 53)
回复 使用道具 举报
zjl880
高级会员   /  发表于:2012-7-26 19:02:00
地板
我将这行代码: this.textControl.InputPosition = new TXTextControl.InputPosition(currentPage, currentLine, currentColumn + 1);
改为: this.textControl.InputPosition = new TXTextControl.InputPosition(currentPage, currentLine, currentColumn );
出现第一个问题,UnKnown Format.
回复 使用道具 举报
iceman
社区贡献组   /  发表于:2012-7-27 18:00:00
5#
回复 4楼zjl880的帖子

你好,我使用以上代码运行正常,楼主能否提供调试 Demo?
回复 使用道具 举报
您需要登录后才可以回帖 登录 | 立即注册
返回顶部