您当前的位置:delphi教程 > Delphi语言基础 > 为什么这段代码在服务中会出错,而在一般应用程序中没有错误呢?

为什么这段代码在服务中会出错,而在一般应用程序中没有错误呢?

Type  
          PSendSmsInfo   =   ^TSendSmsInfo;  
          TSendSmsInfo   =   Record  
                Mobile:string;  
                Msg:string;  
                MsgId:string;  
    end;  
   
          ARecord:PSendSmsInfo;  
          MsgList:TList;  
   
   
                  New(ARecord);  
                  ARecord^.MsgId   :=inttostr(nMsgIndex);  
                  ARecord^.Mobile:=RegMonthUser.FieldValues['Mobile'];  
                  ARecord^.Msg       :=TB_Message.FieldValues['Message'];  
                  MsgList.Add(ARecord);  
   
  请问为什么到最后一句会出现错误:  
  Invalid   variant   type   conversion  
  是什么原因?急啊


查看回复
关于我们 | 网站地图 | 广告刊登 | 友情链接
Copyright ©2008 - 2010  Delphi2007.net  ,All Rights Reserved  粤ICP备09038647号
业务联系:allceoad#gmail.com QQ:20008835 最佳分辨率 1024×768