Results 1 to 3 of 3

Thread: Vb.net Equvilent for ... [Resolved]

  1. #1

    Thread Starter
    Frenzied Member <ABX's Avatar
    Join Date
    Jul 2002
    Location
    Canada eh...
    Posts
    1,622

    Resolved Vb.net Equvilent for ... [Resolved]

    C#
    Code:
    string val    = Request.QueryString["val"]==null?"defaultvalue":Request.QueryString["val"].ToString();
    was looking at some C# code and found noticed that this looks really handy.
    Last edited by <ABX; Sep 21st, 2004 at 10:33 AM.
    Tips:
    • Google is your friend! Search before posting!
    • Name your thread appropriately... "I Need Help" doesn't cut it!
    • Always post your code!!!! We can't read your mind!!! (well, at least most of us!)
    • Allways Include the Name and Line of the Exception (if one is occuring!)
    • If it is relevant state the version of Visual Studio/.Net Framwork you are using (2002/2003/2005)


    If you think I was helpful, rate my post
    IRC Contact: Rizon/xous ChakraNET/xous Freenode/xous

  2. #2
    Lively Member carl_mathews200's Avatar
    Join Date
    May 2004
    Location
    Wales, UK
    Posts
    94
    c# aint my thing but it looks like possibly...

    string val = Request.QueryString["val"]==null?"defaultvalue":Request.QueryString["val"].ToString();
    Code:
    Dim val As String = IIF(Request.QueryString Is Null, "DefaultValue", Request.QueryString("val").ToString())

  3. #3

    Thread Starter
    Frenzied Member <ABX's Avatar
    Join Date
    Jul 2002
    Location
    Canada eh...
    Posts
    1,622
    forgot about IIF

    thanx
    Tips:
    • Google is your friend! Search before posting!
    • Name your thread appropriately... "I Need Help" doesn't cut it!
    • Always post your code!!!! We can't read your mind!!! (well, at least most of us!)
    • Allways Include the Name and Line of the Exception (if one is occuring!)
    • If it is relevant state the version of Visual Studio/.Net Framwork you are using (2002/2003/2005)


    If you think I was helpful, rate my post
    IRC Contact: Rizon/xous ChakraNET/xous Freenode/xous

Posting Permissions

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



Click Here to Expand Forum to Full Width