1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Help with some Regex (VB.net)

Discussion in 'Programming' started by FPForum, Dec 17, 2018.

  1. #1
    I hope someone can help me here. I'm using some regex in VB.net to pull out some text in a string. The text contains "v=" and then the version number. Here is the RegEx I'm using:
    
    v(\d+).(\d+)
    
    Code (markup):
    This works fine when the string is something like v1.8 or v9.3...However, not when trying to pull double digits like v10.4 or v20.9...Any idea how this regex would be updated to look for double digits instead? I've tried the following:
    
    v(\d+)(\d+).(\d+)
    
    Code (markup):
    But it doesn't seem to be working. Am I missing something?
     
    FPForum, Dec 17, 2018 IP
  2. RoseHosting

    RoseHosting Well-Known Member

    Messages:
    230
    Likes Received:
    11
    Best Answers:
    11
    Trophy Points:
    138
    #2
    v\d*\.\d+
    Code (markup):
    This will match:

    v5.5
    v55.55
    v555.555
     
    RoseHosting, Dec 30, 2018 IP
  3. qwikad.com

    qwikad.com Illustrious Member Affiliate Manager

    Messages:
    7,151
    Likes Received:
    1,656
    Best Answers:
    29
    Trophy Points:
    475