⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 unit_public.pas

📁 招投标软件代码,很有应用价值,请大家参考下哦,不明白的地方给我留言
💻 PAS
📖 第 1 页 / 共 2 页
字号:
  cell1.ShowSideLabel(0, 0); //不显示行标
  cell1.ShowTopLabel(0, 0);  //不显示列标
  if jj>0 then
  begin
    if  (iirow=0) then
    begin
      cell1.InsertSheet(1, jj-1);
      ll:=jj-1;
    end;
    if iirow>0 then
    begin
      cell1.InsertSheet(1,jj);
      ll:=jj;
    end;
    for ii:=1 to ll do
    begin
      cell1.CopySheet(ii , 0);
      cell1.SetSheetLabel(ii,'第'+inttostr(ii+1)+'页');
    end;
  end;
end;
procedure getcellXuhao(Acell:tcell;Astartrow,Arow:Integer);
var
  i,j:integer;
  totalpage,totalrow:integer;
begin
  totalpage:=acell.GetTotalSheets;
  for i:=0 to totalpage do
  begin
    for j:=0 to arow-1 do
    begin
      if trim(acell.GetCellString(1,j+astartrow,i))<>'' then
      begin
        acell.SetCellDouble(1,j+astartrow,i,i*arow+j+1);
      end;
    end;
  end;
end;


function format_str(str:string):string;
var bb:string ;
begin
   bb:=copy('000'+str,length(str)+1,3);
   result:=bb;
end;

function CreatedForm(FromClass: TFromClass): TForm;
var
  Form: TForm;
begin
  Form := fromclass.Create(Application);
  Result := Form;
end;

function ShowChildForm(AParam: string): Hwnd;
var
  AForm: TForm;
begin
  if  AParam='xt_zblx' then
  begin
    AForm := Tfrm_zhaobiaolx(CreatedForm(Tfrm_zhaobiaolx) as Tfrm_zhaobiaolx);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='xt_gclx' then
  begin
    AForm := Tfrm_biaoduanlx(CreatedForm(Tfrm_biaoduanlx) as Tfrm_biaoduanlx);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='xt_xmxx' then
  begin
    AForm := Tf_XMXinXi(CreatedForm(Tf_XMXinXi) as Tf_XMXinXi);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='xt_bdgl' then
  begin
    AForm := Tf_BDXinXi(CreatedForm(Tf_BDXinXi) as Tf_BDXinXi);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='xt_dwxx' then
  begin
    AForm := Tfrm_dwXinXi(CreatedForm(Tfrm_dwXinXi) as Tfrm_dwXinXi);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='xt_zjxx' then
  begin

    AForm := TFrm_zhuanjiaxx(CreatedForm(TFrm_zhuanjiaxx) as TFrm_zhuanjiaxx);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='xt_szsjlj' then
  begin
    AForm := TFrm_condb(CreatedForm(TFrm_condb) as TFrm_condb);
    Result := AForm.Handle;
    AForm.Formstyle:=fsMDIChild;
    AForm.show;
    Exit;
  end
  else if  AParam='xt_yhgl' then
  begin
    AForm := Tf_YongHu(CreatedForm(Tf_YongHu) as Tf_YongHu);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end

  else if  AParam='gcgl_ztbjh' then
  begin
    AForm := tfrm_TouBiaojh(CreatedForm(tfrm_TouBiaojh) as tfrm_TouBiaojh);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='gcgl_ztbrz' then
  begin
    AForm := tfrm_TouBiaorz(CreatedForm(tfrm_TouBiaorz) as tfrm_TouBiaorz);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='zsgl_zsrgl' then
  begin
    AForm := tfrm_ZiShenSqr(CreatedForm(tfrm_ZiShenSqr) as tfrm_ZiShenSqr);
    Result := AForm.Handle;
    AForm.show;
    Exit;            
  end
  else if  AParam='zsgl_zswjgl' then
  begin
    AForm := tf_ZiShenWj(CreatedForm(tf_ZiShenWj) as tf_ZiShenWj);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='zsgl_zssqrwjgl' then
  begin
    AForm := tfrm_zishenrenwj(CreatedForm(tfrm_zishenrenwj) as tfrm_zishenrenwj);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='zsgl_zspf' then
  begin
    AForm := tfrm_ZiShenPF(CreatedForm(tfrm_ZiShenPF) as tfrm_ZiShenPF);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='zsgl_tgzssqrgl' then
  begin
    AForm := Tfrm_tongguozigesqr(CreatedForm(Tfrm_tongguozigesqr) as Tfrm_tongguozigesqr);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='zsgl_gzz' then
  begin
    AForm := TFrm_ZiShengzz(CreatedForm(TFrm_ZiShengzz) as TFrm_ZiShengzz);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='zsgl_gzz' then
  begin
    AForm := Tfrm_tongguozigesqr(CreatedForm(Tfrm_tongguozigesqr) as Tfrm_tongguozigesqr);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='zsgl_zgyspsbg' then
  begin
    AForm := tf_Zigeyspsbg(CreatedForm(tf_Zigeyspsbg) as tf_Zigeyspsbg);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='zsgl_zstgtzs' then
  begin
    AForm := tf_ZigeysTzs(CreatedForm(tf_ZigeysTzs) as tf_ZigeysTzs);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='tbgl_yhgl' then
  begin
    AForm := tfrm_YaoHao(CreatedForm(tfrm_YaoHao) as tfrm_YaoHao);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='tbgl_zbwj' then
  begin
    AForm := tf_ZhaoBiaowj(CreatedForm(tf_ZhaoBiaowj) as tf_ZhaoBiaowj);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='tbgl_zbyqs' then
  begin
    AForm := tf_ZhaoBiaoyqs(CreatedForm(tf_ZhaoBiaoyqs) as tf_ZhaoBiaoyqs);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='tbgl_zbyqs' then
  begin
    AForm := tf_ZhaoBiaoyqs(CreatedForm(tf_ZhaoBiaoyqs) as tf_ZhaoBiaoyqs);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='tbgl_bqhy' then
  begin
    AForm := tfrm_BiaoQianhy(CreatedForm(tfrm_BiaoQianhy) as tfrm_BiaoQianhy);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='tbgl_tbwj' then
  begin
    AForm := tf_TouBiaowj(CreatedForm(tf_TouBiaowj) as tf_TouBiaowj);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='pb_wy' then
  begin
    AForm := TFrm_weiyhmd(CreatedForm(TFrm_weiyhmd) as TFrm_weiyhmd);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='pb_yzbd' then
  begin
    AForm := tfrm_YeZhuBd(CreatedForm(tfrm_YeZhuBd) as tfrm_YeZhuBd);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='pb_kbjl' then
  begin
    AForm := tfrm_KaiBiaojl(CreatedForm(tfrm_KaiBiaojl) as tfrm_KaiBiaojl);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='pb_qb' then
  begin
    AForm := tfrm_QingBiao(CreatedForm(tfrm_QingBiao) as tfrm_QingBiao);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='pb_pbj' then
  begin
    AForm := TFrm_pingbiaoj(CreatedForm(TFrm_pingbiaoj) as TFrm_pingbiaoj);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='pb_pbhxr' then
  begin
    AForm := tfrm_PingBiaohxr(CreatedForm(tfrm_PingBiaohxr) as tfrm_PingBiaohxr);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='pb_zbqd' then
  begin
    AForm := TFrm_zhongbiaoqd(CreatedForm(TFrm_zhongbiaoqd) as TFrm_zhongbiaoqd);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='pb_zbtzs' then
  begin
    AForm := tf_ZhongBiaotzs(CreatedForm(tf_ZhongBiaotzs) as tf_ZhongBiaotzs);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
  else if  AParam='pb_bg' then
  begin
    AForm := tf_zhongbiaobg(CreatedForm(tf_zhongbiaobg) as tf_zhongbiaobg);
    Result := AForm.Handle;
    AForm.show;
    Exit;
  end
end;

function GetChildNodeByName(AXmlNode: IXmlNode;AStrName: string): IXmlNode;
var
  ATempXmlNode : IXmlNode;
  AXmlNodeResult : IXmlNode;
begin
  AXmlNodeResult := nil;
  if AXmlNode <> nil then
  begin
    if AXmlNode.HasChildNodes then
    begin
      ATempXmlNode := AXmlNode.ChildNodes.First;

      while (not (ATempXmlNode = Nil)) do
      begin
        if ATempXmlNode.NodeName = AStrName then
        begin
          AXmlNodeResult := ATempXmlNode;
          break;
        end;
        ATempXmlNode := ATempXmlNode.NextSibling;
      end;
    end;
  end;
  Result := AXmlNodeResult;
end;


end.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -