473,320 Members | 1,817 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Regular expression that doesn't recognize newline

Good morning,
I've the following part of an html file,

////////////////////////////////////////////////////////////////////////
</font></b></td>
</tr> <tr>
<td bgcolor=white class=s><div style=padding:10px;>Computer
science, Universit,
Economy, Finance</div></td>
</tr>
////////////////////////////////////////////////////////////////////////

I would want to extract the words "Computer science, Universit,
Economy, Finance" using the following regular expression:

style=padding:10px;>(?<Traduzione>(?:\w|\s|\.|\d|\ :|\"|\,|\?|\'|\-)*)</div></td>

the problem is that it doesn't recognize the newline character after
Universit, so the result is no match but I can't understand why, can
you help me to solve the problem???

Many thanks,

Antonio D'Ottavio
www.etantonio.it/en
po********@etantonio.it
Nov 16 '05 #1
1 1482
Ciao Antonio,

Try enabling the MultiLine option on the RegExp instance.

--
Sincerely,
Dmitriy Lapshin [C# / .NET MVP]
Bring the power of unit testing to the VS .NET IDE today!
http://www.x-unity.net/teststudio.aspx

"Antonio" <et*******@libero.it> wrote in message
news:ba**************************@posting.google.c om...
Good morning,
I've the following part of an html file,

////////////////////////////////////////////////////////////////////////
</font></b></td>
</tr> <tr>
<td bgcolor=white class=s><div style=padding:10px;>Computer
science, Universit,
Economy, Finance</div></td>
</tr>
////////////////////////////////////////////////////////////////////////

I would want to extract the words "Computer science, Universit,
Economy, Finance" using the following regular expression:

style=padding:10px;>(?<Traduzione>(?:\w|\s|\.|\d|\ :|\"|\,|\?|\'|\-)*)</div></td>

the problem is that it doesn't recognize the newline character after
Universit, so the result is no match but I can't understand why, can
you help me to solve the problem???

Many thanks,

Antonio D'Ottavio
www.etantonio.it/en
po********@etantonio.it


Nov 16 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: tdl | last post by:
Hi everybody, I'm a regular expressions newbie; I read many tutorials, but need more experience before becoming indipendent in this field. I need a little help from you. How can I split such a...
2
by: Oriana | last post by:
Hi! I'm trying to 'clean up' this source file using regular expressions in Python. My problem is, that when I try to delete extra lines, my code fails. Here's an example.... /** * *...
1
by: Antonio | last post by:
Good morning, I've the following part of an html file, //////////////////////////////////////////////////////////////////////// </font></b></td> </tr> <tr> <td bgcolor=white class=s><div...
3
by: Gianluca | last post by:
Hi, I'm using regular expressions to extract some information from my vb.net source code files. I have something like this: 1: '<class name="xyz" description="xxxxxx"/> 2: Class xyz ......
3
by: Guoqi Zheng | last post by:
Dear sir, On regular expression, a . means Match anything except newline. How about if I need it to includes newline as well? I try , but it seems not working. and idea? -- Kind regards
7
by: Billa | last post by:
Hi, I am replaceing a big string using different regular expressions (see some example at the end of the message). The problem is whenever I apply a "replace" it makes a new copy of string and I...
3
by: Peter Afonin | last post by:
Hello, I'm looking for a simple regular expression for the Regular Expression validator that would allow any text, spaces and the line breaks and had a minimum and maximum text length. Something...
6
by: sk.rasheedfarhan | last post by:
Hi , I am using regular expression in C++ code, . Negation is not working in the down loaded code. matches all characters except "a", "b", and "c] So I am in dilemma can negation work in C++...
3
by: shapper | last post by:
Hello, I have a regular expression to validate email addresses: "\w+(\w+)*@\w+(\w+)*\.\w+(\w+)*" Now I need to force all emails to be from a given domain, for example, accept only:...
12
by: chaarmann | last post by:
I want to format a long line of text by inserting newline-characters in a way that the printout contains small rows with maximum 80 chars. But I am not allowed to split inside the sequence "<(>"....
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.