|
请老师帮助看看我的保存代码错在哪?单击窗体Form1中save命令就提示编译错误?请帮助看看:
Private Sub Command12_Click()
Dim Sql As String
If Nz([µ¥¾ÝºÅ]) = "" Or Nz([²úÆ·ºÅ]) = "" Then
MsgBox "µ¥¾ÝºÅ»ò²úÆ·ºÅ²»ÄÜΪ¿Õ£¡"
Else
Sql = "insert into tblStockIn/out(µ¥¾ÝºÅ,²úÆ·ºÅ,ÃèÊö,Ô Òò,[Èë_³ö],ÊýÁ¿,[ÈÕÆÚ],±¸×¢) select [µ¥¾ÝºÅ],[²úÆ·ºÅ],[ÃèÊö],[Ô Òò],[Èë_³ö],[ÊýÁ¿],[ÈÕÆÚ],[±¸×¢] "
DoCmd.RunSQL Sql
MsgBox "Êý¾ÝÒѾ Ìí¼Ó³É¹¦£¡"
Me.[µ¥¾ÝºÅ] = Null
Me.[²úÆ·ºÅ] = Null
Me.[ÃèÊö] = Null
Me.[Ô Òò] = Null
Me.[Èë_³ö] = Null
Me.[ÊýÁ¿] = Null
Me.[ÈÕÆÚ] = Null
Me.[±¸×¢] = Null
Me.[frmStockIn_out].Requery
Me![µ¥¾ÝºÅ].SetFocus
SQLText = "UPDATE [tblStock] SET [tblStock].[¿â´æÊýÁ¿] = Forms![frmAddData]![ÊýÁ¿]+[tblStock]![¿â´æÊýÁ¿]WHERE ((([tblStock].[²úÆ·ºÅ])=Forms![frmAddData]![²úÆ·ºÅ]));"
DoCmd.RunSQL SQLText
Me.Form.Refresh
End If
End Sub |
本帖子中包含更多资源
您需要 登录 才可以下载或查看,没有帐号?注册
x
|