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.

notepad ++ - How to select specific lines?

Discussion in 'Programming' started by haliloo22, Feb 15, 2014.

  1. #1
    hello,

    i have a list of 1000 urls. all with .com, .net etc domains like:

    http://site1.org
    http://site2.org
    http://site3.com
    http://site4.net
    http://site5.ru
    http://site6.ws
    http://site7.com
    http://site8.net
    Code (markup):

    i want to only copy the domains with .com domain. how can i do this? i want to copy all .com domains and paste it in a new document
     
    haliloo22, Feb 15, 2014 IP
  2. RobinInTexas

    RobinInTexas Active Member

    Messages:
    217
    Likes Received:
    14
    Best Answers:
    2
    Trophy Points:
    65
    #2
    I would copy the list to excel and write a formula something like
    and then sort on the formula results.
     
    RobinInTexas, Feb 15, 2014 IP
  3. ThePHPMaster

    ThePHPMaster Well-Known Member

    Messages:
    737
    Likes Received:
    52
    Best Answers:
    33
    Trophy Points:
    150
    #3
    Using Notepad++ regular expression search

    1) Replace:
    .*[^\.com]$
    with empty text

    Then select all (control + A)
    Menu -> TextFX -> TextFX Edit -> Delete Blank Lines

    Then to clear out spaces
     
    ThePHPMaster, Feb 15, 2014 IP
    RobinInTexas likes this.
  4. haliloo22

    haliloo22 Member

    Messages:
    46
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    36
    #4
    thnx, i have solved it with mark .com and then go to search and copy all marked lines
     
    haliloo22, Feb 15, 2014 IP