我在做金额录入的表单,想模拟金蝶等财务软件的那个输入系统,:如下图
我想VFP的Grid能做到这样,不知道哪个高手有没有这样现成的例子给我一个
Public oform1
oform1=Newobject("form1")
oform1.Show
Return
Define Class form1 As Form
Top = 0
Left = 0
Height = 273
Width = 452
DoCreate = .T.
Caption = "Form1"
Name = "Form1"
AutoCenter = .T.
Add Object grid1 As Grid With ;
DeleteMark = .F., ;
Height = 218, ;
Left = 24, ;
TabIndex = 1, ;
Top = 47, ;
Visible = .T., ;
Width = 396, ;
AllowCellSelection = .F., ;
Name = "Grid1"
Add Object cmd_add As CommandButton With ;
Top = 13, ;
Left = 68, ;
Height = 25, ;
Width = 60, ;
Caption = "增加", ;
TabIndex = 2, ;
Name = "CMD_ADD"
Add Object cmd_save As CommandButton With ;
Top = 13, ;
Left = 248, ;
Height = 25, ;
Width = 60, ;
Caption = "保存", ;
Enabled = .F., ;
TabIndex = 5, ;
Name = "CMD_SAVE"
Add Object cmd_modify As CommandButton With ;
Top = 13, ;
Left = 128, ;
Height = 25, ;
Width = 60, ;
Caption = "修改", ;
TabIndex = 3, ;
Name = "CMD_MODIFY"
Add Object cmd_del As CommandButton With ;
Top = 13, ;
Left = 188, ;
Height = 25, ;
Width = 60, ;
Caption = "删除", ;
TabIndex = 4, ;
Name = "CMD_DEL"