当前位置: 首页>>代码示例>>C#>>正文


C# IData.GetDataString方法代码示例

本文整理汇总了C#中IData.GetDataString方法的典型用法代码示例。如果您正苦于以下问题:C# IData.GetDataString方法的具体用法?C# IData.GetDataString怎么用?C# IData.GetDataString使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在IData的用法示例。


在下文中一共展示了IData.GetDataString方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: GetExportData

 private string GetExportData(IData data)
 {
     StringBuilder builder = new StringBuilder();
     builder.AppendLine(data.TimeStamp.ToString("yyyyMMddHHmmss", DateTimeFormatInfo.InvariantInfo));
     builder.AppendLine(((int) data.Status).ToString());
     builder.AppendLine(data.UserFolder);
     builder.AppendLine(this.FlagCheck(data.IsRead).ToString());
     builder.AppendLine(this.FlagCheck(data.IsPrinted).ToString());
     builder.AppendLine(this.FlagCheck(data.IsSaved).ToString());
     builder.AppendLine(this.FlagCheck(data.IsDeleted).ToString());
     builder.AppendLine(data.SignFileFolder).ToString();
     builder.Append(data.GetDataString());
     return builder.ToString();
 }
开发者ID:huamanhtuyen,项目名称:VNACCS,代码行数:14,代码来源:UDataView.cs

示例2: OnSend

 private void OnSend(object sender, IData Data)
 {
     if (base.ComStatus == 1)
     {
         this.sendjobsender = sender;
         if (Data.Signflg == 1)
         {
             if (this.CA == null)
             {
                 this.CA = new SignaturesCert();
             }
             try
             {
                 IntPtr handle;
                 if (sender == null)
                 {
                     handle = base.Handle;
                 }
                 else
                 {
                     handle = ((Form) sender).Handle;
                 }
                 this.CA.GetSigneture(handle);
             }
             catch (Exception exception)
             {
                 new MessageDialog().ShowMessage("E124", MessageDialog.CreateExceptionMessage(exception));
                 base.StatusChange(1);
                 base.Enabled = true;
                 this.SendRecvDlgHide();
                 return;
             }
         }
         this.SendRecvDlgShow(1);
         if (this.bSendFlag)
         {
             base.frmSendRecv.lblSendJobCode.Text = Data.JobCode + " " + this.SendCount.ToString() + "/" + this.SendAllCount.ToString();
         }
         else
         {
             base.frmSendRecv.lblSendJobCode.Text = Data.JobCode;
         }
         base.Enabled = false;
         ComParameter senddata = new ComParameter();
         Data = base.SendDataCreate(Data, 0);
         senddata.DataString = Data.GetDataString();
         senddata.AttachFolder = Data.AttachFolder;
         if (Data.Signflg == 1)
         {
             senddata.SelectSign = this.CA.Cert;
             senddata.Sign = Data.Signflg.ToString();
         }
         base.StatusChange(2);
         string iD = Data.ID;
         if (!this.bSendFlag)
         {
             if (Data.ID == null)
             {
                 iD = base.idv.AppendJobData(Data, 0, false, false, false);
             }
             else
             {
                 iD = base.idv.UpdateJobData(Data);
             }
         }
         else
         {
             iD = base.idv.UpdateJobData(Data);
         }
         if (base.sysenv.TerminalInfo.Debug)
         {
             ULogClass.LogWrite("INET_SEND ", Data.GetDataString(), false);
         }
         else
         {
             ULogClass.LogWrite("INET_SEND ", Data.GetDataString().Substring(0, 400), true);
         }
         this.ConnectFlag = true;
         int errcode = this.ihc.Send(this, iD, senddata);
         if (errcode > 0)
         {
             HttpErrorDlg dlg = new HttpErrorDlg();
             base.StatusChange(1);
             base.Enabled = true;
             this.SendRecvDlgHide();
             dlg.ShowSendError(errcode);
             ULogClass.LogWrite("SendError Status=" + System.Enum.GetNames(typeof(HttpResult))[errcode].ToString());
             dlg.Dispose();
         }
         else if (errcode < 0)
         {
             base.StatusChange(1);
             base.Enabled = true;
             this.SendRecvDlgHide();
             ULogClass.LogWrite("User Cancel StatusCode = " + errcode.ToString());
             if (this.bSendFlag)
             {
                 if (base.BatchSendFlag)
                 {
                     base.BatchSendFlag = false;
//.........这里部分代码省略.........
开发者ID:huamanhtuyen,项目名称:VNACCS,代码行数:101,代码来源:InteractiveMain.cs

示例3: SaveToEdiFile

 public static void SaveToEdiFile(IData data, string fileName)
 {
     using (FileStream stream = new FileStream(fileName, FileMode.Create, FileAccess.Write))
     {
         using (StreamWriter writer = new StreamWriter(stream, FileEncoding))
         {
             writer.Write(data.GetDataString());
         }
         stream.Close();
     }
 }
开发者ID:huamanhtuyen,项目名称:VNACCS,代码行数:11,代码来源:DataFactory.cs


注:本文中的IData.GetDataString方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。