Office中国论坛/Access中国论坛
标题:
条形码控件数值如何刷新?
[打印本页]
作者:
aslxt
时间:
2008-11-10 11:26
标题:
条形码控件数值如何刷新?
我用BarCodeCtrl控件在word文档中,在打印的时候把打印时间用条形码打印出来,代码如下:
Private Sub oApp_DocumentBeforePrint(ByVal Doc As Document, Cancel As Boolean)
ThisDocument.BarCodeCtrl1.Value = Now
ThisDocument.BarCodeCtrl1.Refresh
ThisDocument.PageSetup.Orientation = wdOrientPortrait
ThisDocument.Save
If MsgBox("真的要打印吗?", vbYesNo) = vbNo Then
Cancel = True
Else
Cancel = False
End If
End Sub
可是,每次打印的数值都不是当前时间Now,但现实的数值又是Now。怎么办?谢谢
欢迎光临 Office中国论坛/Access中国论坛 (http://www.office-cn.net/)
Powered by Discuz! X3.3