Đáp:
Trong Report, bạn vẽ 1 textbox đặt tên là txtpic, đặt thuộc tính visible của nó là False.
Vẽ 1 đối tượng image đặt tên nó là image1
Sau đó cho đoạn code sau vào
Private Sub Detail_Format(Cancel As Integer, FormatCount As Integer)On Error GoTo err_PicIf IsNull(Me.txtPic) ThenMe.Image1.Picture = ""Me.Image1.Visible = FalseElseMe.Image1.Picture = txtPic.ValueMe.Image1.Visible = TrueEnd IfExit Suberr_Pic:MsgBox Err.Description, vbOKOnlyExit SubEnd Sub
Không có nhận xét nào:
Đăng nhận xét