Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    Regular Coder
    Join Date
    Sep 2011
    Posts
    193
    Thanks
    147
    Thanked 0 Times in 0 Posts

    Check if a recordset exists

    Hello,

    Quick question for y'all,

    Using javascript coding, how can you check if a recordset exists?

    if (rs) { alert("yup the rs is active alright") }

    this does not work,

    Any ideas?

    thanks,

    Jay

  • #2
    Supreme Master coder! Old Pedant's Avatar
    Join Date
    Feb 2009
    Posts
    27,650
    Thanks
    80
    Thanked 4,636 Times in 4,598 Posts
    What *kind* of recordset?

    Where did it come from?

    That code you showed would only check if the variable is null or not, so even if (example) rs == 7 or rs == "wham" you'd see the message. Not too useful.
    An optimist sees the glass as half full.
    A pessimist sees the glass as half empty.
    A realist drinks it no matter how much there is.


  •  

    LinkBacks (?)


    Posting Permissions

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