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

企业管理

开发平台:

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