Results 1 to 3 of 3
  1. #1
    Silver Lounger
    Join Date
    Jan 2002
    Posts
    1,615
    Thanks
    0
    Thanked 1 Time in 1 Post

    If list is null msgbox (2002)

    Hi,

    I have various forms that contain lists that are requeried based on txtstartdate and txtenddate. They work well. There are times when the list will not contain information for the date range entered. In these instances I'd like a msgbox to come up that tells the user there is no data for the date range selected. I can do the msgbox piece but am having trouble with having the form determine if the list is empty. I tied

    If isnull (me.lstISFRecords) then
    msgbox.....................
    end if

    The result was the message box whether the list was populated or not.

    Leesha

  2. #2
    Gold Lounger
    Join Date
    Feb 2001
    Location
    Sint Niklaas, Belgium
    Posts
    2,778
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: If list is null msgbox (2002)

    You can use :
    If me.lstISFRecords.ListCount = 0 then
    msgbox "No records"
    end if
    Francois

  3. #3
    Silver Lounger
    Join Date
    Jan 2002
    Posts
    1,615
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: If list is null msgbox (2002)

    As always Francois it worked beautifully!!

    Thanks,
    Leesha

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •