Rabu, 25 Juli 2012

Re: [MS_AccessPros] Do not display a form if the control source (a query) return no rows

 

Thomas

I just tried this code on the click event below and it worked

Private Sub cmdOpenTable_Click()
If Text34.Value > 5000 Then
    DoCmd.OpenTable "Education", acViewNormal
Else
    MsgBox "there are not enough records"
End If
End Sub
 
Jim Wagner
________________________________

________________________________
From: Thomas <thomas_lam_us@yahoo.com>
To: MS_Access_Professionals@yahoogroups.com
Sent: Wednesday, July 25, 2012 10:16 AM
Subject: Re: [MS_AccessPros] Do not display a form if the control source (a query) return no rows


 
Hi Crystal,

So I still have to check if there is something to be displayed on the form and then do something.

There is no quick and easy way of checking if zero row is return or something like that.

Regards,
Thomas

--- In MS_Access_Professionals@yahoogroups.com, Crystal <strive4peace2008@...> wrote:
>
> Hi Thomas,
>
> the Form OPEN Event has Cancel
>
> Warm Regards,
> Crystal
>
> Learn Access on YouTube
> http://www.YouTube.com/LearnAccessByCrystal
>
>
>  *
>    (: have an awesome day :)
>  *
>
>
>
> ________________________________
> From: Thomas <thomas_lam_us@...>
> To: MS_Access_Professionals@yahoogroups.com
> Sent: Tuesday, July 24, 2012 5:40 PM
> Subject: [MS_AccessPros] Do not display a form if the control source (a query) return no rows
>
> What is the event which will be fired under this condition? Can I display a message box and then issue the CANCEL = TRUE to suppress the form from displaying?
>
> Regards,
> Thomas
>
>
>
>
>
> ------------------------------------
>
> Yahoo! Groups Links
>
>
>
> [Non-text portions of this message have been removed]
>

[Non-text portions of this message have been removed]

__._,_.___
Recent Activity:
.

__,_._,___

Tidak ada komentar:

Posting Komentar