-
上传用户:zhpu1995
上传日期:2013-09-06
资源大小:61151k
文件大小:46k
源码类别:

企业管理

开发平台:

Visual Basic

  1. VERSION 5.00
  2. Object = "{BEEECC20-4D5F-4F8B-BFDC-5D9B6FBDE09D}#1.0#0"; "vsflex8.ocx"
  3. Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "mscomctl.ocx"
  4. Begin VB.Form Report_FrmAccAgeList 
  5.    Caption         =   "账龄分析表"
  6.    ClientHeight    =   8595
  7.    ClientLeft      =   315
  8.    ClientTop       =   390
  9.    ClientWidth     =   11820
  10.    HelpContextID   =   5001
  11.    Icon            =   "统计分析_账龄分析查询列表.frx":0000
  12.    KeyPreview      =   -1  'True
  13.    LinkTopic       =   "Form1"
  14.    MDIChild        =   -1  'True
  15.    ScaleHeight     =   8595
  16.    ScaleWidth      =   11820
  17.    WindowState     =   2  'Maximized
  18.    Begin MSComctlLib.Toolbar GsToolbar 
  19.       Height          =   525
  20.       Left            =   9210
  21.       TabIndex        =   3
  22.       Top             =   30
  23.       Width           =   2595
  24.       _ExtentX        =   4577
  25.       _ExtentY        =   926
  26.       ButtonWidth     =   1455
  27.       ButtonHeight    =   926
  28.       Appearance      =   1
  29.       Style           =   1
  30.       ImageList       =   "ImageList2"
  31.       _Version        =   393216
  32.       BeginProperty Buttons {66833FE8-8583-11D1-B16A-00C0F0283628} 
  33.          NumButtons      =   3
  34.          BeginProperty Button1 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  35.             Caption         =   "保存格式"
  36.             Key             =   "bcgs"
  37.             ImageKey        =   "bcgs"
  38.          EndProperty
  39.          BeginProperty Button2 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  40.             Caption         =   "默认列宽"
  41.             Key             =   "hfmrgs"
  42.             ImageKey        =   "mrlk"
  43.          EndProperty
  44.          BeginProperty Button3 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  45.             Caption         =   "显示项目"
  46.             Key             =   "szxsxm"
  47.             ImageKey        =   "xsxm"
  48.          EndProperty
  49.       EndProperty
  50.    End
  51.    Begin VB.PictureBox Pic_Title 
  52.       Height          =   1095
  53.       Left            =   0
  54.       Picture         =   "统计分析_账龄分析查询列表.frx":1042
  55.       ScaleHeight     =   1035
  56.       ScaleWidth      =   11715
  57.       TabIndex        =   1
  58.       Top             =   570
  59.       Width           =   11775
  60.       Begin VB.Label Lab_Date 
  61.          AutoSize        =   -1  'True
  62.          BackStyle       =   0  'Transparent
  63.          Caption         =   "截止日期:"
  64.          Height          =   180
  65.          Left            =   8820
  66.          TabIndex        =   8
  67.          Top             =   780
  68.          Width           =   810
  69.       End
  70.       Begin VB.Label Lab_Foreign 
  71.          AutoSize        =   -1  'True
  72.          BackStyle       =   0  'Transparent
  73.          Caption         =   "币别:"
  74.          Height          =   180
  75.          Left            =   6040
  76.          TabIndex        =   7
  77.          Top             =   780
  78.          Width           =   450
  79.       End
  80.       Begin VB.Label Lab_Person 
  81.          AutoSize        =   -1  'True
  82.          BackStyle       =   0  'Transparent
  83.          Caption         =   "经办人:"
  84.          Height          =   180
  85.          Left            =   3080
  86.          TabIndex        =   6
  87.          Top             =   780
  88.          Width           =   630
  89.       End
  90.       Begin VB.Label Lab_Dept 
  91.          AutoSize        =   -1  'True
  92.          BackStyle       =   0  'Transparent
  93.          Caption         =   "部门:"
  94.          Height          =   180
  95.          Left            =   300
  96.          TabIndex        =   5
  97.          Top             =   780
  98.          Width           =   450
  99.       End
  100.       Begin VB.Label Lab_Title 
  101.          AutoSize        =   -1  'True
  102.          BackColor       =   &H80000018&
  103.          BackStyle       =   0  'Transparent
  104.          Caption         =   "账龄分析表"
  105.          BeginProperty Font 
  106.             Name            =   "宋体"
  107.             Size            =   12
  108.             Charset         =   134
  109.             Weight          =   700
  110.             Underline       =   0   'False
  111.             Italic          =   0   'False
  112.             Strikethrough   =   0   'False
  113.          EndProperty
  114.          ForeColor       =   &H00000000&
  115.          Height          =   240
  116.          Index           =   4
  117.          Left            =   510
  118.          TabIndex        =   2
  119.          Top             =   210
  120.          Width           =   1275
  121.       End
  122.    End
  123.    Begin VB.Timer Timer1 
  124.       Enabled         =   0   'False
  125.       Interval        =   1
  126.       Left            =   7620
  127.       Top             =   90
  128.    End
  129.    Begin VSFlex8Ctl.VSFlexGrid CxbbGrid 
  130.       Height          =   7305
  131.       Left            =   0
  132.       TabIndex        =   0
  133.       Top             =   1680
  134.       Width           =   11775
  135.       _cx             =   5080
  136.       _cy             =   5080
  137.       Appearance      =   1
  138.       BorderStyle     =   1
  139.       Enabled         =   -1  'True
  140.       BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  141.          Name            =   "宋体"
  142.          Size            =   9
  143.          Charset         =   134
  144.          Weight          =   400
  145.          Underline       =   0   'False
  146.          Italic          =   0   'False
  147.          Strikethrough   =   0   'False
  148.       EndProperty
  149.       MousePointer    =   0
  150.       BackColor       =   16777215
  151.       ForeColor       =   -2147483640
  152.       BackColorFixed  =   13826538
  153.       ForeColorFixed  =   -2147483630
  154.       BackColorSel    =   -2147483635
  155.       ForeColorSel    =   -2147483634
  156.       BackColorBkg    =   -2147483636
  157.       BackColorAlternate=   16777215
  158.       GridColor       =   -2147483633
  159.       GridColorFixed  =   -2147483632
  160.       TreeColor       =   -2147483632
  161.       FloodColor      =   192
  162.       SheetBorder     =   -2147483642
  163.       FocusRect       =   1
  164.       HighLight       =   1
  165.       AllowSelection  =   -1  'True
  166.       AllowBigSelection=   -1  'True
  167.       AllowUserResizing=   0
  168.       SelectionMode   =   0
  169.       GridLines       =   1
  170.       GridLinesFixed  =   2
  171.       GridLineWidth   =   1
  172.       Rows            =   50
  173.       Cols            =   10
  174.       FixedRows       =   1
  175.       FixedCols       =   1
  176.       RowHeightMin    =   0
  177.       RowHeightMax    =   0
  178.       ColWidthMin     =   0
  179.       ColWidthMax     =   0
  180.       ExtendLastCol   =   0   'False
  181.       FormatString    =   ""
  182.       ScrollTrack     =   0   'False
  183.       ScrollBars      =   3
  184.       ScrollTips      =   0   'False
  185.       MergeCells      =   0
  186.       MergeCompare    =   0
  187.       AutoResize      =   -1  'True
  188.       AutoSizeMode    =   0
  189.       AutoSearch      =   0
  190.       AutoSearchDelay =   2
  191.       MultiTotals     =   -1  'True
  192.       SubtotalPosition=   1
  193.       OutlineBar      =   0
  194.       OutlineCol      =   0
  195.       Ellipsis        =   0
  196.       ExplorerBar     =   0
  197.       PicturesOver    =   0   'False
  198.       FillStyle       =   0
  199.       RightToLeft     =   0   'False
  200.       PictureType     =   0
  201.       TabBehavior     =   0
  202.       OwnerDraw       =   0
  203.       Editable        =   0
  204.       ShowComboButton =   1
  205.       WordWrap        =   0   'False
  206.       TextStyle       =   0
  207.       TextStyleFixed  =   0
  208.       OleDragMode     =   0
  209.       OleDropMode     =   0
  210.       DataMode        =   0
  211.       VirtualData     =   -1  'True
  212.       DataMember      =   ""
  213.       ComboSearch     =   3
  214.       AutoSizeMouse   =   -1  'True
  215.       FrozenRows      =   0
  216.       FrozenCols      =   0
  217.       AllowUserFreezing=   0
  218.       BackColorFrozen =   0
  219.       ForeColorFrozen =   0
  220.       WallPaperAlignment=   9
  221.       AccessibleName  =   ""
  222.       AccessibleDescription=   ""
  223.       AccessibleValue =   ""
  224.       AccessibleRole  =   24
  225.       Begin MSComctlLib.ImageList ImageList2 
  226.          Left            =   0
  227.          Top             =   0
  228.          _ExtentX        =   1005
  229.          _ExtentY        =   1005
  230.          BackColor       =   -2147483643
  231.          ImageWidth      =   16
  232.          ImageHeight     =   16
  233.          MaskColor       =   12632256
  234.          _Version        =   393216
  235.          BeginProperty Images {2C247F25-8591-11D1-B16A-00C0F0283628} 
  236.             NumListImages   =   40
  237.             BeginProperty ListImage1 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  238.                Picture         =   "统计分析_账龄分析查询列表.frx":35106
  239.                Key             =   "sz"
  240.             EndProperty
  241.             BeginProperty ListImage2 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  242.                Picture         =   "统计分析_账龄分析查询列表.frx":354A0
  243.                Key             =   "dy"
  244.             EndProperty
  245.             BeginProperty ListImage3 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  246.                Picture         =   "统计分析_账龄分析查询列表.frx":3583A
  247.                Key             =   "yl"
  248.             EndProperty
  249.             BeginProperty ListImage4 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  250.                Picture         =   "统计分析_账龄分析查询列表.frx":35BD4
  251.                Key             =   "xg"
  252.             EndProperty
  253.             BeginProperty ListImage5 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  254.                Picture         =   "统计分析_账龄分析查询列表.frx":35F6E
  255.                Key             =   "zh"
  256.             EndProperty
  257.             BeginProperty ListImage6 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  258.                Picture         =   "统计分析_账龄分析查询列表.frx":36308
  259.                Key             =   "sh"
  260.             EndProperty
  261.             BeginProperty ListImage7 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  262.                Picture         =   "统计分析_账龄分析查询列表.frx":366A2
  263.                Key             =   "bc"
  264.             EndProperty
  265.             BeginProperty ListImage8 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  266.                Picture         =   "统计分析_账龄分析查询列表.frx":36A3C
  267.                Key             =   "fq"
  268.             EndProperty
  269.             BeginProperty ListImage9 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  270.                Picture         =   "统计分析_账龄分析查询列表.frx":36DD6
  271.                Key             =   "bz"
  272.             EndProperty
  273.             BeginProperty ListImage10 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  274.                Picture         =   "统计分析_账龄分析查询列表.frx":37170
  275.                Key             =   "tc"
  276.             EndProperty
  277.             BeginProperty ListImage11 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  278.                Picture         =   "统计分析_账龄分析查询列表.frx":3750A
  279.                Key             =   "bcgs"
  280.             EndProperty
  281.             BeginProperty ListImage12 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  282.                Picture         =   "统计分析_账龄分析查询列表.frx":378A4
  283.                Key             =   "mrlk"
  284.             EndProperty
  285.             BeginProperty ListImage13 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  286.                Picture         =   "统计分析_账龄分析查询列表.frx":37C3E
  287.                Key             =   "xsxm"
  288.             EndProperty
  289.             BeginProperty ListImage14 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  290.                Picture         =   "统计分析_账龄分析查询列表.frx":37FD8
  291.                Key             =   "first"
  292.             EndProperty
  293.             BeginProperty ListImage15 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  294.                Picture         =   "统计分析_账龄分析查询列表.frx":38372
  295.                Key             =   "prev"
  296.             EndProperty
  297.             BeginProperty ListImage16 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  298.                Picture         =   "统计分析_账龄分析查询列表.frx":3870C
  299.                Key             =   "next"
  300.             EndProperty
  301.             BeginProperty ListImage17 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  302.                Picture         =   "统计分析_账龄分析查询列表.frx":38AA6
  303.                Key             =   "last"
  304.             EndProperty
  305.             BeginProperty ListImage18 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  306.                Picture         =   "统计分析_账龄分析查询列表.frx":38E40
  307.                Key             =   "xx"
  308.             EndProperty
  309.             BeginProperty ListImage19 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  310.                Picture         =   "统计分析_账龄分析查询列表.frx":391DA
  311.                Key             =   "define"
  312.             EndProperty
  313.             BeginProperty ListImage20 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  314.                Picture         =   "统计分析_账龄分析查询列表.frx":39574
  315.                Key             =   "exec"
  316.             EndProperty
  317.             BeginProperty ListImage21 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  318.                Picture         =   "统计分析_账龄分析查询列表.frx":3990E
  319.                Key             =   "xz"
  320.             EndProperty
  321.             BeginProperty ListImage22 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  322.                Picture         =   "统计分析_账龄分析查询列表.frx":39CA8
  323.                Key             =   "sc"
  324.             EndProperty
  325.             BeginProperty ListImage23 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  326.                Picture         =   "统计分析_账龄分析查询列表.frx":3A042
  327.                Key             =   "sx"
  328.             EndProperty
  329.             BeginProperty ListImage24 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  330.                Picture         =   "统计分析_账龄分析查询列表.frx":3A3DC
  331.                Key             =   "cx"
  332.             EndProperty
  333.             BeginProperty ListImage25 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  334.                Picture         =   "统计分析_账龄分析查询列表.frx":3A776
  335.                Key             =   "zd"
  336.             EndProperty
  337.             BeginProperty ListImage26 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  338.                Picture         =   "统计分析_账龄分析查询列表.frx":3AB10
  339.                Key             =   "dz"
  340.             EndProperty
  341.             BeginProperty ListImage27 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  342.                Picture         =   "统计分析_账龄分析查询列表.frx":3AEAA
  343.                Key             =   "ph"
  344.             EndProperty
  345.             BeginProperty ListImage28 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  346.                Picture         =   "统计分析_账龄分析查询列表.frx":3B244
  347.                Key             =   "fz"
  348.             EndProperty
  349.             BeginProperty ListImage29 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  350.                Picture         =   "统计分析_账龄分析查询列表.frx":3B5DE
  351.                Key             =   "dw"
  352.             EndProperty
  353.             BeginProperty ListImage30 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  354.                Picture         =   "统计分析_账龄分析查询列表.frx":3B978
  355.                Key             =   "hf"
  356.             EndProperty
  357.             BeginProperty ListImage31 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  358.                Picture         =   "统计分析_账龄分析查询列表.frx":3BD12
  359.                Key             =   "pz"
  360.             EndProperty
  361.             BeginProperty ListImage32 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  362.                Picture         =   "统计分析_账龄分析查询列表.frx":3C0AC
  363.                Key             =   "check"
  364.             EndProperty
  365.             BeginProperty ListImage33 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  366.                Picture         =   "统计分析_账龄分析查询列表.frx":3C446
  367.                Key             =   "qs"
  368.             EndProperty
  369.             BeginProperty ListImage34 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  370.                Picture         =   "统计分析_账龄分析查询列表.frx":3C7E0
  371.                Key             =   "fullcheck"
  372.             EndProperty
  373.             BeginProperty ListImage35 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  374.                Picture         =   "统计分析_账龄分析查询列表.frx":3CB7A
  375.                Key             =   "qq"
  376.             EndProperty
  377.             BeginProperty ListImage36 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  378.                Picture         =   "统计分析_账龄分析查询列表.frx":3CF14
  379.                Key             =   "bcw"
  380.             EndProperty
  381.             BeginProperty ListImage37 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  382.                Picture         =   "统计分析_账龄分析查询列表.frx":3D2AE
  383.                Key             =   "ye"
  384.             EndProperty
  385.             BeginProperty ListImage38 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  386.                Picture         =   "统计分析_账龄分析查询列表.frx":3D648
  387.                Key             =   ""
  388.             EndProperty
  389.             BeginProperty ListImage39 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  390.                Picture         =   "统计分析_账龄分析查询列表.frx":3D9E2
  391.                Key             =   "frist"
  392.             EndProperty
  393.             BeginProperty ListImage40 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  394.                Picture         =   "统计分析_账龄分析查询列表.frx":3DD7C
  395.                Key             =   "dj"
  396.             EndProperty
  397.          EndProperty
  398.       End
  399.    End
  400.    Begin MSComctlLib.Toolbar SzToolbar 
  401.       Align           =   1  'Align Top
  402.       Height          =   555
  403.       Left            =   0
  404.       TabIndex        =   4
  405.       Top             =   0
  406.       Width           =   11820
  407.       _ExtentX        =   20849
  408.       _ExtentY        =   979
  409.       ButtonWidth     =   820
  410.       ButtonHeight    =   926
  411.       AllowCustomize  =   0   'False
  412.       Appearance      =   1
  413.       Style           =   1
  414.       ImageList       =   "ImageList1"
  415.       _Version        =   393216
  416.       BeginProperty Buttons {66833FE8-8583-11D1-B16A-00C0F0283628} 
  417.          NumButtons      =   12
  418.          BeginProperty Button1 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  419.             Caption         =   "设置"
  420.             Key             =   "ymsz"
  421.             ImageKey        =   "sz"
  422.          EndProperty
  423.          BeginProperty Button2 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  424.             Caption         =   "打印"
  425.             Key             =   "dy"
  426.             ImageKey        =   "dy"
  427.          EndProperty
  428.          BeginProperty Button3 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  429.             Caption         =   "预览"
  430.             Key             =   "yl"
  431.             ImageKey        =   "yl"
  432.          EndProperty
  433.          BeginProperty Button4 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  434.             Style           =   3
  435.          EndProperty
  436.          BeginProperty Button5 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  437.             Caption         =   "查询"
  438.             Key             =   "cx"
  439.             ImageKey        =   "cx"
  440.          EndProperty
  441.          BeginProperty Button6 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  442.             Object.Visible         =   0   'False
  443.             Caption         =   "单据"
  444.             Key             =   "Bill"
  445.             ImageKey        =   "pz"
  446.          EndProperty
  447.          BeginProperty Button7 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  448.             Object.Visible         =   0   'False
  449.             Style           =   3
  450.          EndProperty
  451.          BeginProperty Button8 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  452.             Object.Visible         =   0   'False
  453.             Caption         =   "新增"
  454.             Key             =   "xz"
  455.             ImageKey        =   "xz"
  456.          EndProperty
  457.          BeginProperty Button9 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  458.             Object.Visible         =   0   'False
  459.             Caption         =   "删除"
  460.             Key             =   "sc"
  461.             ImageKey        =   "sc"
  462.          EndProperty
  463.          BeginProperty Button10 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  464.             Style           =   3
  465.          EndProperty
  466.          BeginProperty Button11 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  467.             Caption         =   "帮助"
  468.             Key             =   "bz"
  469.             ImageKey        =   "bz"
  470.          EndProperty
  471.          BeginProperty Button12 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  472.             Caption         =   "退出"
  473.             Key             =   "fh"
  474.             ImageKey        =   "tc"
  475.          EndProperty
  476.       EndProperty
  477.       BorderStyle     =   1
  478.       Begin MSComctlLib.ImageList ImageList1 
  479.          Left            =   6990
  480.          Top             =   30
  481.          _ExtentX        =   1005
  482.          _ExtentY        =   1005
  483.          BackColor       =   -2147483643
  484.          ImageWidth      =   16
  485.          ImageHeight     =   16
  486.          MaskColor       =   12632256
  487.          _Version        =   393216
  488.          BeginProperty Images {2C247F25-8591-11D1-B16A-00C0F0283628} 
  489.             NumListImages   =   34
  490.             BeginProperty ListImage1 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  491.                Picture         =   "统计分析_账龄分析查询列表.frx":3E116
  492.                Key             =   "sz"
  493.             EndProperty
  494.             BeginProperty ListImage2 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  495.                Picture         =   "统计分析_账龄分析查询列表.frx":3E4B0
  496.                Key             =   "dy"
  497.             EndProperty
  498.             BeginProperty ListImage3 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  499.                Picture         =   "统计分析_账龄分析查询列表.frx":3E84A
  500.                Key             =   "yl"
  501.             EndProperty
  502.             BeginProperty ListImage4 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  503.                Picture         =   "统计分析_账龄分析查询列表.frx":3EBE4
  504.                Key             =   "xg"
  505.             EndProperty
  506.             BeginProperty ListImage5 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  507.                Picture         =   "统计分析_账龄分析查询列表.frx":3EF7E
  508.                Key             =   "zh"
  509.             EndProperty
  510.             BeginProperty ListImage6 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  511.                Picture         =   "统计分析_账龄分析查询列表.frx":3F318
  512.                Key             =   "sh"
  513.             EndProperty
  514.             BeginProperty ListImage7 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  515.                Picture         =   "统计分析_账龄分析查询列表.frx":3F6B2
  516.                Key             =   "bc"
  517.             EndProperty
  518.             BeginProperty ListImage8 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  519.                Picture         =   "统计分析_账龄分析查询列表.frx":3FA4C
  520.                Key             =   "fq"
  521.             EndProperty
  522.             BeginProperty ListImage9 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  523.                Picture         =   "统计分析_账龄分析查询列表.frx":3FDE6
  524.                Key             =   "bz"
  525.             EndProperty
  526.             BeginProperty ListImage10 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  527.                Picture         =   "统计分析_账龄分析查询列表.frx":40180
  528.                Key             =   "tc"
  529.             EndProperty
  530.             BeginProperty ListImage11 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  531.                Picture         =   "统计分析_账龄分析查询列表.frx":4051A
  532.                Key             =   "bcgs"
  533.             EndProperty
  534.             BeginProperty ListImage12 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  535.                Picture         =   "统计分析_账龄分析查询列表.frx":408B4
  536.                Key             =   "mrlk"
  537.             EndProperty
  538.             BeginProperty ListImage13 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  539.                Picture         =   "统计分析_账龄分析查询列表.frx":40C4E
  540.                Key             =   "xsxm"
  541.             EndProperty
  542.             BeginProperty ListImage14 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  543.                Picture         =   "统计分析_账龄分析查询列表.frx":40FE8
  544.                Key             =   "first"
  545.             EndProperty
  546.             BeginProperty ListImage15 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  547.                Picture         =   "统计分析_账龄分析查询列表.frx":41382
  548.                Key             =   "prev"
  549.             EndProperty
  550.             BeginProperty ListImage16 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  551.                Picture         =   "统计分析_账龄分析查询列表.frx":4171C
  552.                Key             =   "next"
  553.             EndProperty
  554.             BeginProperty ListImage17 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  555.                Picture         =   "统计分析_账龄分析查询列表.frx":41AB6
  556.                Key             =   "last"
  557.             EndProperty
  558.             BeginProperty ListImage18 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  559.                Picture         =   "统计分析_账龄分析查询列表.frx":41E50
  560.                Key             =   "xx"
  561.             EndProperty
  562.             BeginProperty ListImage19 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  563.                Picture         =   "统计分析_账龄分析查询列表.frx":421EA
  564.                Key             =   "define"
  565.             EndProperty
  566.             BeginProperty ListImage20 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  567.                Picture         =   "统计分析_账龄分析查询列表.frx":42584
  568.                Key             =   "exec"
  569.             EndProperty
  570.             BeginProperty ListImage21 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  571.                Picture         =   "统计分析_账龄分析查询列表.frx":4291E
  572.                Key             =   "xz"
  573.             EndProperty
  574.             BeginProperty ListImage22 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  575.                Picture         =   "统计分析_账龄分析查询列表.frx":42CB8
  576.                Key             =   "sc"
  577.             EndProperty
  578.             BeginProperty ListImage23 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  579.                Picture         =   "统计分析_账龄分析查询列表.frx":43052
  580.                Key             =   "sx"
  581.             EndProperty
  582.             BeginProperty ListImage24 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  583.                Picture         =   "统计分析_账龄分析查询列表.frx":433EC
  584.                Key             =   "cx"
  585.             EndProperty
  586.             BeginProperty ListImage25 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  587.                Picture         =   "统计分析_账龄分析查询列表.frx":43786
  588.                Key             =   "zd"
  589.             EndProperty
  590.             BeginProperty ListImage26 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  591.                Picture         =   "统计分析_账龄分析查询列表.frx":43B20
  592.                Key             =   "dz"
  593.             EndProperty
  594.             BeginProperty ListImage27 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  595.                Picture         =   "统计分析_账龄分析查询列表.frx":43EBA
  596.                Key             =   "ph"
  597.             EndProperty
  598.             BeginProperty ListImage28 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  599.                Picture         =   "统计分析_账龄分析查询列表.frx":44254
  600.                Key             =   "fz"
  601.             EndProperty
  602.             BeginProperty ListImage29 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  603.                Picture         =   "统计分析_账龄分析查询列表.frx":445EE
  604.                Key             =   "dw"
  605.             EndProperty
  606.             BeginProperty ListImage30 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  607.                Picture         =   "统计分析_账龄分析查询列表.frx":44988
  608.                Key             =   "hf"
  609.             EndProperty
  610.             BeginProperty ListImage31 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  611.                Picture         =   "统计分析_账龄分析查询列表.frx":44D22
  612.                Key             =   "pz"
  613.             EndProperty
  614.             BeginProperty ListImage32 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  615.                Picture         =   "统计分析_账龄分析查询列表.frx":450BC
  616.                Key             =   "check"
  617.             EndProperty
  618.             BeginProperty ListImage33 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  619.                Picture         =   "统计分析_账龄分析查询列表.frx":45456
  620.                Key             =   "AllCheck"
  621.             EndProperty
  622.             BeginProperty ListImage34 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  623.                Picture         =   "统计分析_账龄分析查询列表.frx":457F0
  624.                Key             =   "AllNoCheck"
  625.             EndProperty
  626.          EndProperty
  627.       End
  628.    End
  629. End
  630. Attribute VB_Name = "Report_FrmAccAgeList"
  631. Attribute VB_GlobalNameSpace = False
  632. Attribute VB_Creatable = False
  633. Attribute VB_PredeclaredId = True
  634. Attribute VB_Exposed = False
  635. '**************************************************************************
  636. '*    模 块 名 称 :账龄分析表
  637. '*    功 能 描 述 :主要根据到期日、供应商、部门、经办人以及币别等条件对供应商账龄进行统计分析
  638. '*    程序员姓名  :陈恩宇
  639. '*    最后修改人  :陈恩宇
  640. '*    最后修改时间:2002/01/04
  641. '*    备        注:程序中所有依实际情况自定义部分均用[>>  <<]括起
  642. '**************************************************************************
  643. Dim ReportTitle As String                '报表主标题
  644. Dim Str_QueryCondi As String             '用户录入查询条件
  645. Dim Rec_BillID As New ADODB.Recordset    '用户查询单据ID动态集
  646. Dim FillCol As Integer                   '填充网格列
  647. Dim AccAge() As Single                   '账龄区间对应的最长值
  648. Dim BeginCol As Integer                  '填充起始列值
  649. '以下为固定使用变量
  650. Dim Dyymctbl As New DY_Dyymsz            '打印页面窗体变量
  651. Dim GridCode As String                   '显示网格网格代码
  652. Dim GridInf() As Variant                 '整个网格设置信息
  653. Dim Tsxx As String                       '系统提示信息
  654. Dim Qslz As Long                         '网格隐藏(非操作显示)列数
  655. Dim Sjhgd As Double                      '网格数据行高度
  656. Dim Sfxshjwg As Boolean                  '是否显示合计网格
  657. Dim GridBoolean() As Boolean             '网格列信息(布尔型)
  658. Dim GridStr()  As String                 '网格列信息(字符型)
  659. Dim GridInt() As Integer                 '网格列信息(整型)
  660. Dim Szzls As Integer                     '数组总列数(网格列数-1)
  661. Private Sub Form_Resize()                '根据窗体大小来调整网格,标题栏大小(Fixed)
  662.     
  663.     On Error Resume Next
  664.     
  665.     With CxbbGrid
  666.         .Width = Me.Width - 160
  667.         .Height = Me.Height - .Top - 400
  668.     End With
  669.     
  670.     With Pic_Title
  671.         .Width = Me.Width - 160
  672.     End With
  673.     
  674.     GsToolbar.Left = Me.Width - GsToolbar.Width - 140
  675. End Sub
  676. Private Sub Form_Load()                                                   '窗体装入
  677.   
  678.     '调入打印页面设置窗体
  679.     ReportTitle = "账龄分析表"
  680.     XtReportCode = "Ap_AccAgeAnalyse"
  681.     Load Dyymctbl
  682.   
  683.     '调整标题栏及网格、格式工具条位置(Fixed)
  684.     Pic_Title.Left = 40
  685.     Pic_Title.Top = SzToolbar.Top + SzToolbar.Height - 10
  686.     CxbbGrid.Left = Pic_Title.Left
  687.     CxbbGrid.Top = Pic_Title.Top + Pic_Title.Height + 20
  688.  
  689.     '调 入 网 格(Fixed)
  690.     GridCode = "Ap_AccAgeAnalyse"
  691.     Call BzWgcsh(CxbbGrid, GridCode, GridInf(), GridBoolean(), GridInt(), GridStr())
  692.   
  693.     Qslz = GridInf(1)
  694.     Sjhgd = GridInf(2)
  695.     Sfxshjwg = GridInf(7)
  696.     Szzls = CxbbGrid.Cols - 1
  697. End Sub
  698. Private Sub Form_Unload(Cancel As Integer)                                  '窗体卸载
  699.     '卸载条件窗体
  700.     Report_FrmAccAgeQuery.UnloadCheck.Value = 1
  701.     Unload Report_FrmAccAgeQuery
  702.     
  703.     '卸载打印页面设置窗体
  704.     Unload Dyymctbl
  705. End Sub
  706. Private Sub CxbbGrid_BeforeMoveColumn(ByVal Col As Long, Position As Long)           '网格列发生移动时自动交换网格索引信息
  707.     Call FnBln_RefreshArray(Col, Position, GridStr(), GridInf())
  708. End Sub
  709. Private Sub GsToolbar_ButtonClick(ByVal Button As MSComctlLib.Button)       '网格格式调整(Fixed)
  710.     
  711.     Select Case Button.Key
  712.         Case "bcgs"                                          '保存表格格式
  713.             Call Bcwggs(CxbbGrid, GridCode, GridStr())
  714.         Case "hfmrgs"                                        '恢复默认格式
  715.             Call Hfmrgs(CxbbGrid, GridCode, GridStr())
  716.         Case "szxsxm"                                        '设置显示项目
  717.             Call Szxsxm(CxbbGrid, GridCode)
  718.     End Select
  719. End Sub
  720. Private Sub SzToolbar_ButtonClick(ByVal Button As MSComctlLib.Button)
  721.     
  722.     Select Case Button.Key
  723.         Case "ymsz"                                          '页面设置
  724.             Dyymctbl.Show 1
  725.         Case "yl"                                            '预 览
  726.             Call bbyl(True)
  727.         Case "dy"                                            '打 印
  728.             Call bbyl(False)
  729.         Case "cx"                                            '查 询
  730.             Report_FrmAccAgeQuery.Show 1
  731.         Case "bz"                                            '帮 助
  732.             Call F1bz
  733.         Case "fh"                                            '退 出
  734.             Unload Me
  735.     End Select
  736. End Sub
  737. Private Sub Timer1_Timer()                                 '在窗体激活后调入查询程序
  738.     
  739.     Timer1.Enabled = False
  740.     Xt_Wait.Show
  741.     Xt_Wait.Refresh
  742.    
  743.     '加快显示速度
  744.     CxbbGrid.Redraw = False
  745.  
  746.     '生成查询结果
  747.     Call Sub_Query(0)
  748.    
  749.     CxbbGrid.Redraw = True
  750.     
  751.     Xt_Wait.Hide
  752. End Sub
  753. Private Sub Sub_Query(Int_QueryType As Integer)                                     '生成查询结果(Define)
  754.     
  755.     '过程参数:Int_QueryType 0-"点确定按钮"查询  1-"刷新"查询
  756.     Dim Rec_Query As New ADODB.Recordset        '查询结果动态集
  757.     Dim Coljsq As Long                          '网格列计数器
  758.     Dim Jsqte As Integer                        '临时动态计数器
  759.     Dim TempForCur As String                    '临时币别代码
  760.     Dim Str_FillGrid As String                  '填充网格数据
  761.     Dim TotalYe As Double                       '汇总余额
  762.     Dim TmpJsq As Integer                       '临时计数器
  763.     Dim Rec_Temp As New ADODB.Recordset         '过期数值查询结果动态集
  764.     Dim Str_Bill As String                      '存储过程代码
  765.     Dim GqTotal() As Double                     '过期数组
  766.     Dim Str_Foreign As String                   '币别编码
  767.     Dim Str_Department As String                '部门编码
  768.     Dim Str_Person As String                    '经办人编码
  769.     Dim Str_Date As Date                        '截止日期
  770.     '填充网格表头内容
  771.     Str_FillGrid = "Select MinBillAge,MaxBillAge,REPLACE (BEDays,'过期','')BEDays From RP_BillAge Where RPFlag='Ap' Order by MinBillAge "
  772.     Call Sub_FillGrid(Str_FillGrid)
  773.     
  774.     '如果没有设置帐龄区间,则不能进行帐龄区间的统计
  775.     If FillCol < 1 Then
  776.         Tsxx = "请在基础设置中设置帐龄区间后查询!"
  777.         Call Xtxxts(Tsxx, 0, 4)
  778.         Exit Sub
  779.     End If
  780.     
  781.     '定义过期数组
  782.     ReDim GqTotal(FillCol) As Double
  783.     '以下为自定义部分[
  784.  
  785.     If Int_QueryType = 0 Then   '0-"点确定按钮"查询
  786.         With Report_FrmAccAgeQuery
  787.             
  788.             '填充表头部门内容
  789.             Report_FrmAccAgeList.Lab_Dept = "部门: " & .LrText(4).Text
  790.             Report_FrmAccAgeList.Lab_Person = "经办人: " & .LrText(5).Text
  791.             Report_FrmAccAgeList.Lab_Date = "截止日期: " & .LrText(0).Text
  792.             If Trim(.LrText(3).Text) <> "" Then
  793.                 Report_FrmAccAgeList.Lab_Foreign = "币别: " & .LrText(3).Text
  794.                 TempForCur = Trim(.LrText(3).Tag)
  795.             Else
  796.                 Report_FrmAccAgeList.Lab_Foreign = "币别: " & XtSCurrName
  797.                 TempForCur = XtSCurrCode
  798.             End If
  799.             
  800.             Str_Date = CDate(.LrText(0).Text)
  801.             Str_Foreign = Trim(.LrText(3).Tag & "")
  802.             Str_Department = Trim(.LrText(4).Tag & "")
  803.             Str_Person = Trim(.LrText(5).Tag & "")
  804.             
  805.             '生成查询条件
  806.             Str_QueryCondi = " where 1=1 and RPFlag = 'AP' and OverStatus=0 and BillItemCode in (80,70,71) and (StartFlag=0 or (startFlag=1 and Checker<>''))"
  807.          
  808.             For Jsqte = 1 To 6
  809.                 Select Case Jsqte
  810.                     Case 1  '截止日期
  811.                         If Trim(.LrText(0).Text) <> "" Then
  812.                             Str_QueryCondi = Str_QueryCondi & " and BillDate <= '" & CDate(.LrText(0).Text) & "'"
  813.                         End If
  814.                     Case 2  '客户(起)
  815.                         If Trim(.LrText(1).Text) <> "" Then
  816.                             Str_QueryCondi = Str_QueryCondi & " and PsCode >= '" & Trim(.LrText(1).Tag) & "'"
  817.                         End If
  818.                     Case 3  '客户(止)
  819.                         If Trim(.LrText(2).Text) <> "" Then
  820.                             Str_QueryCondi = Str_QueryCondi & " and PsCode <= '" & Trim(.LrText(2).Tag) & "'"
  821.                         End If
  822.                     Case 4  '币别
  823.                         If Trim(.LrText(3).Text) <> "" Then
  824.                             Str_QueryCondi = Str_QueryCondi & " And ForeignCurrCode='" & Trim(.LrText(3).Tag) & "'"
  825.                         End If
  826.                     Case 5  '部门
  827.                         If Trim(.LrText(4).Text) <> "" Then
  828.                             Str_QueryCondi = Str_QueryCondi & " And DeptCode= '" & Trim(.LrText(4).Tag) & "'"
  829.                         End If
  830.                     Case 6 '经办人
  831.                         If Trim(.LrText(5).Text) <> "" Then
  832.                             Str_QueryCondi = Str_QueryCondi & " And PersonCode= '" & Trim(.LrText(5).Tag) & "'"
  833.                         End If
  834.                 
  835.                 End Select
  836.             
  837.             Next Jsqte
  838.             
  839.         End With
  840.     Else
  841.         '1-"刷新"查询
  842.     End If
  843.      
  844.     Sqlstr = "SELECT PsCode,SupplierName,Sum(YbYsje)YbYsje ,Sum(BbYsje)BbYsje,Sum(YbCancelje)YbCancelje,Sum(BbCancelje)BbCancelje " & _
  845.              " FROM Ap_V_AccMxList " & Str_QueryCondi & " Group By PsCode,SupplierName Order By PsCode"
  846.     Set Rec_Query = Cw_DataEnvi.DataConnect.Execute(Sqlstr)
  847.     With Rec_Query
  848.         CxbbGrid.Rows = CxbbGrid.FixedRows
  849.         Jsqte = CxbbGrid.FixedRows
  850.         Do While Not .EOF
  851.             CxbbGrid.AddItem ""
  852.             
  853.             '[>>自定义填充内容
  854.             CxbbGrid.TextMatrix(Jsqte, Sydz("001", GridStr(), Szzls)) = Trim(.Fields("PsCode") & "")                                 '供应商编码
  855.             CxbbGrid.TextMatrix(Jsqte, Sydz("002", GridStr(), Szzls)) = Trim(.Fields("SupplierName") & "")                           '供应商名称
  856.             If Str_Foreign <> "" Then
  857.                 If Val(.Fields("YbYsje")) <> Val(.Fields("YbCancelje")) Then
  858.                     CxbbGrid.TextMatrix(Jsqte, Sydz("003", GridStr(), Szzls)) = Val(.Fields("YbYsje")) - Val(.Fields("YbCancelje"))  '原币应付金额
  859.                 End If
  860.             Else
  861.                 If Val(.Fields("BbYsje")) <> Val(.Fields("BbCancelje")) Then
  862.                     CxbbGrid.TextMatrix(Jsqte, Sydz("003", GridStr(), Szzls)) = Val(.Fields("BbYsje")) - Val(.Fields("BbCancelje"))  '本币应付金额
  863.                 End If
  864.             End If
  865.                
  866.                 '调用存储过程填充过期数值
  867.                 For TmpJsq = 0 To FillCol
  868.                  
  869.                     If TmpJsq <> FillCol Then
  870.                         Str_Bill = "Ap_Sp_AccAgeAnalyse '" & Rec_Query!PsCode & "','" & Str_Foreign & "','" & Str_Department & "','" & Str_Person & "','" & AccAge(TmpJsq) & "','" & AccAge(TmpJsq + 1) & "','" & Str_Date & "'"
  871.                     Else
  872.                         Str_Bill = "Ap_Sp_AccAgeAnalyse '" & Rec_Query!PsCode & "','" & Str_Foreign & "','" & Str_Department & "','" & Str_Person & "','" & AccAge(TmpJsq) & "','" & -1 & "','" & Str_Date & "'"
  873.                     End If
  874.                     
  875.                     Set Rec_Temp = Cw_DataEnvi.DataConnect.Execute(Str_Bill)
  876.                     If Not Rec_Temp.EOF Then
  877.                         With CxbbGrid
  878.                             If Str_Foreign <> "" Then
  879.                                 If Val((Rec_Temp!GqNumberYb) & "") <> 0 Then
  880.                                     .TextMatrix(Jsqte, TmpJsq + 4) = Format(Val((Rec_Temp!GqNumberYb) & ""), "#,##0.00")    '原币过期金额
  881.                                 End If
  882.                                 GqTotal(TmpJsq) = GqTotal(TmpJsq) + Val(Rec_Temp!GqNumberYb & "")                           '原币过期金额合计
  883.                             Else
  884.                                 If Val((Rec_Temp!GqNumber) & "") <> 0 Then
  885.                                     .TextMatrix(Jsqte, TmpJsq + 4) = Format(Val((Rec_Temp!GqNumber) & ""), "#,##0.00")      '本币过期金额
  886.                                 End If
  887.                                 GqTotal(TmpJsq) = GqTotal(TmpJsq) + Val(Rec_Temp!GqNumber & "")                             '本币过期金额合计
  888.                             End If
  889.                         End With
  890.                     End If
  891.     
  892.                 Next TmpJsq
  893.             '<<]
  894.             
  895.             '重新汇总客户余额]
  896.             If Str_Foreign <> "" Then
  897.                 TotalYe = TotalYe + .Fields("YbYsje") - .Fields("YbCancelje")
  898.             Else
  899.                 TotalYe = TotalYe + .Fields("BbYsje") - .Fields("BbCancelje")
  900.             End If
  901.             
  902.             '设置数据行高度(Fixed)
  903.             CxbbGrid.RowHeight(Jsqte) = Sjhgd
  904.             '动态集指针加1,同时将计数器加1(Fixed)
  905.             .MoveNext
  906.             Jsqte = Jsqte + 1
  907.             
  908.             If .EOF Then
  909.                 '填充合计金额
  910.                 CxbbGrid.AddItem ""
  911.                 CxbbGrid.RowHeight(Jsqte) = Sjhgd
  912.                 CxbbGrid.TextMatrix(Jsqte, Sydz("002", GridStr(), Szzls)) = "  合  计"              '摘要
  913.                 CxbbGrid.TextMatrix(Jsqte, Sydz("003", GridStr(), Szzls)) = TotalYe                 '填充余额合计
  914.                 
  915.                 '填充过期合计数
  916.                 For TmpJsq = 0 To FillCol
  917.                     CxbbGrid.TextMatrix(Jsqte, TmpJsq + 4) = Format(GqTotal(TmpJsq), "#,##0.00")    '过期金额合计
  918.                 Next TmpJsq
  919.                 
  920.                 '设置合计行颜色
  921.                 CxbbGrid.Cell(flexcpBackColor, Jsqte, 0, , CxbbGrid.Cols - 1) = "&H00F7F3EC"
  922.                 Jsqte = Jsqte + 1
  923.                 
  924.                 '填充占总金额比例
  925.                 CxbbGrid.AddItem ""
  926.                 CxbbGrid.RowHeight(Jsqte) = Sjhgd
  927.                 CxbbGrid.TextMatrix(Jsqte, Sydz("002", GridStr(), Szzls)) = "  占总额(%)"           '摘要
  928.                 CxbbGrid.TextMatrix(Jsqte, Sydz("003", GridStr(), Szzls)) = "100"                   '余额合计百分比
  929.                 
  930.                 If TotalYe <> 0 Then
  931.                     For TmpJsq = 0 To FillCol                                                       '过期金额百分比
  932.                         CxbbGrid.TextMatrix(Jsqte, TmpJsq + 4) = Format(GqTotal(TmpJsq) / TotalYe * 100, "#,##0.00")
  933.                     Next TmpJsq
  934.                 End If
  935.                 
  936.                 '设置合计行颜色
  937.                 CxbbGrid.Cell(flexcpBackColor, Jsqte, 0, , CxbbGrid.Cols - 1) = "&H00C0E0FF"
  938.                 
  939.             End If
  940.         Loop
  941.         
  942.     End With
  943.     ']以上为用户自定义部分
  944. End Sub
  945. '填充网格表头数据内容
  946. Private Sub Sub_FillGrid(Str_Grid As String)
  947.     
  948.     Dim Rec_FillGrid As New Recordset               '网格列标题动态集
  949.     Dim jsq As Integer, Rowjsq As Integer
  950.     Dim Coljsq As Integer
  951.     Dim ArrayNum As Integer
  952.     
  953.     '打开账龄区间设置动态集
  954.     Set Rec_FillGrid = Cw_DataEnvi.DataConnect.Execute(Str_Grid)
  955.     FillCol = Rec_FillGrid.RecordCount
  956.     If FillCol < 1 Then Exit Sub
  957.     
  958.         '根据帐龄区间设置各个帐龄分析区间段的最小值
  959.         '<<
  960.         ReDim AccAge(FillCol) As Single
  961.     
  962.         Rec_FillGrid.MoveFirst
  963.         ArrayNum = 0
  964.         Do While Not Rec_FillGrid.EOF
  965.             ArrayNum = ArrayNum + 1
  966.             AccAge(ArrayNum) = Trim(Rec_FillGrid.Fields("MinBillAge") & "")
  967.             Rec_FillGrid.MoveNext
  968.         Loop
  969.         '>>
  970.     
  971.     '填充网格表头数据
  972.     Rec_FillGrid.MoveFirst
  973.     With CxbbGrid
  974.         '设置网格属性
  975.         .BackColorFixed = &H8000000F                                           '固定行背景色 ('&H80000018)
  976.         .Cols = Qslz + 4 + Rec_FillGrid.RecordCount
  977.         .AllowUserResizing = flexResizeBoth
  978.         .SelectionMode = flexSelectionByRow
  979.         .ExplorerBar = flexExNone                                              '网格列是否可移动及排序
  980.         .ScrollTips = True
  981.         .WordWrap = True
  982.         
  983.         For jsq = Qslz To .Cols - 1
  984.             .ColHidden(jsq) = False
  985.         Next jsq
  986.         
  987.         '填 充 网 格 标 题
  988.         For Rowjsq = 0 To .FixedRows - 1
  989.             If Rowjsq = 0 Then
  990.                 .MergeRow(Rowjsq) = True
  991.                 .RowHeight(Rowjsq) = Sjhgd * 1.8
  992.                 .TextMatrix(Rowjsq, Qslz) = "供应商编码"
  993.                 .TextMatrix(Rowjsq, Qslz + 1) = "供应商名称"
  994.                 .TextMatrix(Rowjsq, Qslz + 2) = "余额"
  995.                 .TextMatrix(Rowjsq, Qslz + 3) = "未到期"
  996.                 
  997.                 .TextMatrix(Rowjsq + 1, Qslz) = "供应商编码"
  998.                 .TextMatrix(Rowjsq + 1, Qslz + 1) = "供应商名称"
  999.                 .TextMatrix(Rowjsq + 1, Qslz + 2) = "余额"
  1000.                 .TextMatrix(Rowjsq + 1, Qslz + 3) = "未到期"
  1001.                 
  1002.                 BeginCol = Qslz + 4             '定义起始列
  1003.                 
  1004.                 '从数据表填充网格列
  1005.                 If Not Rec_FillGrid.EOF Then
  1006.                     Rec_FillGrid.MoveFirst
  1007.                     For Coljsq = (Qslz + 4) To (.Cols - 1)
  1008.                         .TextMatrix(Rowjsq, Coljsq) = "过期天数"
  1009.                         .TextMatrix(Rowjsq + 1, Coljsq) = Trim(Rec_FillGrid.Fields("BEDays") & "")
  1010.                         Rec_FillGrid.MoveNext
  1011.                     Next Coljsq
  1012.                 End If
  1013.             
  1014.             End If
  1015.         Next Rowjsq
  1016.         
  1017.         '数 据 网 格 高 度
  1018.         For Rowjsq = 0 To .FixedRows - 1
  1019.             .RowHeight(Rowjsq) = 250
  1020.         Next Rowjsq
  1021.         
  1022.          '定 义 录 入 字 段 属 性
  1023.         For Coljsq = (Qslz + 4) To .Cols - 1
  1024.             .MergeCol(Coljsq) = True
  1025.             .ColAlignment(Coljsq) = flexAlignRightTop
  1026.             .FixedAlignment(Coljsq) = flexAlignCenterCenter
  1027.         Next Coljsq
  1028.              
  1029.         '定义网格列宽度
  1030.         For Coljsq = 4 To .Cols - 1
  1031.             .ColWidth(Coljsq) = Sjhgd * 5
  1032.         Next Coljsq
  1033.     
  1034.     End With
  1035. End Sub
  1036. '[>>===================以下为根据实际业务需要自定义过程区域=============================<<]
  1037. Private Sub bbyl(bbylte As Boolean)                    '报表打印预览
  1038.     
  1039.     Dim Bbzbt$, Bbxbt() As String, bbxbtzzxs() As Integer, Bbxbtgs As Integer
  1040.     Dim Bbbwh() As String, Bbbwhzzxs() As Integer, Bbbwhgs As Integer
  1041.     Bbxbtgs = 2                                          '报 表 小 标 题 行 数
  1042.     Bbbwhgs = 0                                          '报 表 表 尾 行 数
  1043.     
  1044.     ReDim Bbxbt(1 To Bbxbtgs)
  1045.     ReDim bbxbtzzxs(1 To Bbxbtgs)
  1046.     If Bbbwhgs <> 0 Then
  1047.         ReDim Bbbwh(1 To Bbbwhgs)
  1048.         ReDim Bbbwhzzxs(1 To Bbbwhgs)
  1049.     End If
  1050.     
  1051.     Bbzbt = ReportTitle
  1052.     Bbxbt(1) = Space(2) + Fun_FormatOutPut(Lab_Dept, 28) + Fun_FormatOutPut(Lab_Person, 28) + Fun_FormatOutPut(Lab_Foreign, 28) + Fun_FormatOutPut(Lab_Date, 28)
  1053.     bbxbtzzxs(1) = 0                                     '报表行组织形式(0-居左 1-居中 2-居右)
  1054.     Call Scyxsjb(CxbbGrid)                               '生成报表数据
  1055.     Call Scdybb(Dyymctbl, Bbzbt, Bbxbt(), bbxbtzzxs(), Bbxbtgs, Bbbwh(), Bbbwhzzxs(), Bbbwhgs, bbylte)
  1056.     If Not bbylte Then
  1057.         Unload DY_Tybbyldy
  1058.     End If
  1059. End Sub