我使用C#Regex從我的輸入中找到所有「http:// .....」。 這是我的代碼,但我沒有找到任何東西。請告訴我我錯過了什麼?「http *」正則表達式與URL匹配
Match m = Regex.Match(input, "http* ");
while (m.Success)
{
Console.WriteLine("'{0}' found at index {1}.",
m.Value, m.Index);
m = m.NextMatch();
}
這是我輸入文本(爲了便於閱讀):
I recently moved and have a buI recently moved and have a bunch of stuff for sale.
Most prices are based on my research from CL and ebay. Let me know or make an offer
if you like something from the list. Thanks. IKEA RAMBERG bed frame and Sultan
mattress - $150 http://seattle.craigslist.org/est/fuo/4688883554.html Sanus Platinum
Foundations TV Stand - $75 http://seattle.craigslist.org/est/fuo/4687613962.html
Staples Mission Coffee table and 2 sets of nesting/side tables - $90
http://seattle.craigslist.org/est/fuo/4687499215.html
Like new Hoover SteamVac Carpet Cleaner with Clean Surge, F5914900 - $100
http://seattle.craigslist.org/est/hsh/4687474666.html Hauppauge WinTV-HVR-1600
ATSC/NTSC/QAM Tuner Video Card + Remote - $35
http://seattle.craigslist.org/est/sop/4687372003.html Computer with core 2 quad, 2GB
RAM, nforce MB, 1.5TB HDD and more - $200 http://seattle.craigslist.org/est/sys/4687362266.html
LINKSYS CM100 Cable Modem (works with Comcast) - $15
http://seattle.craigslist.org/est/ele/4687639722.html Various computer parts for sale - $1 I
recently moved and have a buI recently moved and have a bunch of stuff for sale. Most prices
are based on my research from CL and ebay. Let me know or make an offer if you like something
from the list. Thanks. IKEA RAMBERG bed frame and Sultan mattress - $150
http://seattle.craigslist.org/est/fuo/4688883554.html Sanus Platinum Foundations TV Stand - $75
http://seattle.craigslist.org/est/fuo/4687613962.html Staples Mission Coffee table and 2 sets of
nesting/side tables - $90 http://seattle.craigslist.org/est/fuo/4687499215.html Like new Hoover
SteamVac Carpet Cleaner with Clean Surge, F5914900 - $100
http://seattle.craigslist.org/est/hsh/4687474666.html Hauppauge WinTV-HVR-1600 ATSC/NTSC/QAM
Tuner Video Card + Remote - $35 http://seattle.craigslist.org/est/sop/4687372003.html Computer
with core 2 quad, 2GB RAM, nforce MB, 1.5TB HDD and more - $200
http://seattle.craigslist.org/est/sys/4687362266.html LINKSYS CM100 Cable Modem (works with
Comcast) - $15 http://seattle.craigslist.org/est/ele/4687639722.html Various computer parts for
sale - $1 "
您缺少點。 – 2014-09-29 17:12:58