RE: Regular Expression Question

  • From: "Sina Bahram" <sbahram@xxxxxxxxx>
  • To: <programmingblind@xxxxxxxxxxxxx>
  • Date: Mon, 8 Oct 2007 16:27:01 -0400

Just do

.*\n

That will grab everything 0 or more times, including the new line.

if you don't want to include the new line, but want to go right up against
it, then use parentheses like this:

(.*)\n

Take care,
Sina 

-----Original Message-----
From: programmingblind-bounce@xxxxxxxxxxxxx
[mailto:programmingblind-bounce@xxxxxxxxxxxxx] On Behalf Of
james.homme@xxxxxxxxxxxx
Sent: Monday, October 08, 2007 3:22 PM
To: programmingblind@xxxxxxxxxxxxx
Subject: Regular Expression Question


Hi,
I tried and failed a few times to get this, but for some reason I am thick
about regular expressions. I want to represent whatever might be on the
current line. I don't care if the line is blank or if it has text on it. I
want to represent everything from the beginning up to the new line. I think
I want to include the new line, but I haven't thought that through yet. Is
this how to do it?

^.*\n

Thanks.

Jim

James D Homme, , Usability Engineering, Highmark Inc.,
james.homme@xxxxxxxxxxxx, 412-544-1810

"It's more important for me to start to do the right thing than it is to
wait until I think I can do it just right."


__________
View the list's information and change your settings at
//www.freelists.org/list/programmingblind

__________
View the list's information and change your settings at 
//www.freelists.org/list/programmingblind

Other related posts: