• PASCAL知识


    API Index

    http://docs.embarcadero.com/products/rad_studio/delphiAndcpp2009/HelpUpdate2/EN/html/delphivclwin32/idx.html

    专业术语

    Delphi - Delphi 百科
    PASCAL - PASCAL 百科
    Object PASCAL - Object PASCAL 百科

    系统PASCAL方法WIKI参考

    Stingray Scripting Component

    FileCopy
    //- This function will copy files.
    DeleteFile
    //- This function will delete files.
    ListFilesInDirectory
    //- This function return a list (TStringList) of files in specified folder.
    

    删除文件夹下所有文件,清空文件夹

    var
      FileList : TStringList;
      filesfrom, filepath : string;
      ISEMPTY, i : integer;
    begin
    
    filesfrom:= ReqList.Values['DocPath'];
    FileList:= TStringList.Create;
    
    try
    
     ListFilesInDirectory(filesfrom, '*.*', false, FileList);
     ISEMPTY:= FileList.Count;
    
     if ISEMPTY > 0 then
      for i:= 0 to FileList.Count - 1 do begin
        filepath:= FileList.Strings[i];
        DeleteFile(filepath);
      end;
    
    finally
     FileList.free;
    
    end;
    

    Object Pascal语言参考

    //包含字符, indexOf 
    //Pos 函数 在字符串中搜索子串 
    if POS('软','软件工具')>0 then 1 
    // ExecuteCompiledScript( Reqlist.values['Stingray_Phys_Path'] + 'StingrayRulesPostQR_Entry', FSQLConnection, ReqList, FTrnMan ) 
    // ExecuteCompiledScript( ReqList.Values['prefile'], FSQLConnection, ReqList, FTrnMan );
    if ReqList.Values['NBRESULT']='1' THEN ReqList.Values['__NBRESULT']:='1';
    // Upload_FilePath:= ReqList.Values['Upload_FilePath'];
    Srv_Img_Path:= ReqList.Values['Srv_Img_Path'] + ExtractFileName(Upload_FilePath);
    FileCopy( Upload_FilePath, Srv_Img_Path, True );
    // ExecuteCompiledScript( Reqlist.values['Stingray_Phys_Path'] + 'StingrayRulesPostQR_Entry', FSQLConnection, ReqList, FTrnMan ) 
    //GetConstant 
    ReqList.Values['Not_Sufficient_Right '] := GetConstant('Global ', 'Not_Sufficient_Right ');
    
    ReqList.Values['OldtoNewACrID_ '+ReqList.Values['ACraftID ']] := ReqList.Values['NEWACRID '];
    ReqList.Values['NEWAirCraftID '] := ReqList.Values['OldtoNewACrID_ '+ReqList.Values['aPQA_ID ']];
    Reqlist.values['TheSaveString '] := ReplaceString(Reqlist.values['TheSaveString '],' * * ','''', false);
    UpdateWrittenPremium( StrToIntDef(ReqList.Values['sLOB_ID '], 1), ReqList.Values['PolicyCode '], FSQLConnection );
    UpdateWrittenPremiumLevel( StrToIntDef(ReqList.Values['sFRM_D '],1) , ReqList.Values['PolicyCode '], FSQLConnection );
    // EdtResult.Text := Copy(EdtResult.Text, 1, Length(EdtResult.Text)-1); 
    ReqList.Values['sqlarrstr '] :=Copy(ReqList.Values['sqlarrstr '],1,Length(ReqList.Values['sqlarrstr '])-1);
    // if trim(uppercase(Reqlist.values['sSSR_CompareType '])) = 'INTEGER ' then 
    begin if ProcessExpression(Reqlist.values[Reqlist.values['sSSR_FieldName ']] + Reqlist.values['sSSR_Operator '] + Reqlist.values['sSSR_StopValue ']) then 
    Reqlist.values['AddSeRR ']:= '1 ' else Reqlist.values['AddSeRR ']:= '0 ';
    // var NewFile, NewFileName: String;
    begin NewFile:= CreateReport(Reqlist.values['sREP_ID'], 'PDF', ReqList, FSqlConnection);
    Reqlist.values['Response_Content']:= NewFile;
    // 
    ----------------------------------------------------=----------------------- PASCAL
    类型转换函数 
    DateTimeToFileDate
    DateTimeToStr
    DateTimeToString
    DateToStr
    FileDateToDateTime
    FloatToDecimal
    FloatToStrF
    FloatToStr
    FloatToText
    FloatToTextFmt
    IntToHex
    IntToStr
    StringToWideChar
    StrToDate
    StrToDateTime
    StrToFloat
    StrToInt
    StrToIntDef
    StrToFloatDef
    StrToTime
    TextToFloat
    TimeToStr
    VarToDateTime
    WideCharLenToString
    WideCharToString
    WideCharToStrVar 
    

    pascal+sublime搭建Pascal学习环境

  • 相关阅读:
    Yii框架2.0 数据库操作初接触
    Yii框架2.0的视图和widgets表单的使用
    Yii框架2.0的安装过程
    监控之snmpd 服务
    在HTML里面HEAD部分的META元素要表达的内容是什么
    被table单元格colspan属性折磨了
    excel模版从xp复制到win7系统后出现错误 运行时错误 '429' ActiveX 部件不能创建对象
    oracle左连接连表查询
    Nginx 关闭防火墙
    左连接不能与or否则in连用
  • 原文地址:https://www.cnblogs.com/wancy86/p/PASCAL.html
Copyright © 2020-2023  润新知