regular expression necessary?

J

John Salerno

Can someone tell me how I can search for the phrase:

Function -

(Has spaces before and after the hyphen)

I'm using UltraEdit, and when I type it in just like that, it can't find
it, so I may have to use Regular Expressions. I've tried a few things,
but they didn't work either, so I'm not sure I'm doing it right.
Basically I want to replace that text in a bunch of files with nothing.
 
E

Els

John said:
Can someone tell me how I can search for the phrase:

Function -

(Has spaces before and after the hyphen)

I'm using UltraEdit, and when I type it in just like that, it can't find
it, so I may have to use Regular Expressions. I've tried a few things,
but they didn't work either, so I'm not sure I'm doing it right.
Basically I want to replace that text in a bunch of files with nothing.

Have you tried just doing a copy paste from your file into the
search/replace box? Sometimes that tells you for instance that the
space is a tab. Have you tried unticking the 'regular expression' box
in the search/replace area? (I don't have UltraEdit, but those are the
things I'd try in TextPad)
 
J

John Salerno

Els said:
Have you tried just doing a copy paste from your file into the
search/replace box? Sometimes that tells you for instance that the
space is a tab. Have you tried unticking the 'regular expression' box
in the search/replace area? (I don't have UltraEdit, but those are the
things I'd try in TextPad)

Thanks. The copy/paste trick worked, but it turns out that what *wasn't*
working was the option to replace the string in all open files. When I
chose to do it in just the current file, it worked, so maybe it's an
UltraEdit issue.
 
S

Stan McCann

Can someone tell me how I can search for the phrase:

Function -

(Has spaces before and after the hyphen)

I'm using UltraEdit, and when I type it in just like that, it can't
find it, so I may have to use Regular Expressions. I've tried a few
things, but they didn't work either, so I'm not sure I'm doing it
right. Basically I want to replace that text in a bunch of files
with nothing.

Yep, Select Regular Expressions and 'function *-*(*)*' should give you
what you want. (untested)

Another UE user.
 
J

John Salerno

Stan said:
Yep, Select Regular Expressions and 'function *-*(*)*' should give you
what you want. (untested)

Another UE user.

Hmmm, weird. Function*-* only found "Function -" without the trailing
space. But when I typed in just "Function - " (no quotes) and checked
Regular Expressions, then it found the whole thing.

Oh well, I still think UE is great! :)
 
J

John Salerno

dorayme said:
If you get a Mac and BBEdit or TextWrangler you will have no trouble
over such simple issues...


Yes, ok, I will buy a Mac just so I can do a search and replace.
 
R

Richard Sexton

Yes, ok, I will buy a Mac just so I can do a search and replace.

Come for the search and replace, stay for the lack of blue screen of death
and viruses.
 
J

John Salerno

Richard said:
Come for the search and replace, stay for the lack of blue screen of death
and viruses.

Honestly, I don't think I've ever had a problem with either of these in
the 10+ years I've used computers. Maybe it's just been so long since
I've seen the blue screen that I've forgotten what it looks like.

And as for viruses, if you're smart enough, you won't get them. Not to
mention that probably the biggest reason that viruses are more of a
problem on PCs than Macs is simply because PCs are far more prevalent,
so viruses target them more. Even if Macs are inherently better
protected, people could still create viruses for them if they wanted to.
So trying to get everyone to convert to Macs only seems to hurt the case
of "we have no viruses." :)
 
R

Richard Sexton

Honestly, I don't think I've ever had a problem with either of these in
the 10+ years I've used computers. Maybe it's just been so long since
I've seen the blue screen that I've forgotten what it looks like.

And as for viruses, if you're smart enough, you won't get them. Not to
mention that probably the biggest reason that viruses are more of a
problem on PCs than Macs is simply because PCs are far more prevalent,
so viruses target them more. Even if Macs are inherently better
protected, people could still create viruses for them if they wanted to.
So trying to get everyone to convert to Macs only seems to hurt the case
of "we have no viruses." :)

I used to say this too. I've used Windows since version 1.0. No kidding;
although my work is primarily c/unix I've had to use Windows forever.

Until XP I found windows annoying but mosty usable. Now, keep in mind
I'm on a dialup line here at home where I work; my servers are in
another city in another country.

I live far enough away from civilization that dialup is the only
option, period and on a good day I get 28.8. I've never got higher
than that with any modem. There's a 4 db loss between here and the CO.

So, I tried XP. Seems nice for a chnage, but once a month it would
shit itself. SP2? Check. MS anit-spyware ? check. AV? check? Zone
alarm ? Check. Windows update on? Check.

The damn thing spent so much time updating itself
I was lucky to be able to use 75% of my bandwidth.

And it still got infected. I'm not sure on dialup it can update
itself fast enough.

I've written Windowss device drivers for several graphics and
scsi cards. I think I know what I'm doing. But I don't have hours
a day to waste trying to keep it on the air. Meanwhile the mac
somebody gave me as a joke seems to jsut work and doesn't waste
my time. Perhapos one day it will be a problem too, but at the
end of the day I get paid to write C, not unfuck a lame OS.

I'm gad there are people that can use it and keep it on the
air. Much to my own amazement, I am not one of them. Whateever.

I still have an XP box here dor video work but I will not connect
it to the internet. Hot swap SCA is my friend. I use W98 to
connect windows to the net where I need to but I'm phasing
out all MS software here. It just doesn't work.
 
D

dorayme

John Salerno said:
Can someone tell me how I can search for the phrase:

Function -

(Has spaces before and after the hyphen)

I'm using UltraEdit, and when I type it in just like that, it can't find
it, so I may have to use Regular Expressions. I've tried a few things,
but they didn't work either, so I'm not sure I'm doing it right.
Basically I want to replace that text in a bunch of files with nothing.

Search text in what? The actual article open? All articles in a
folder? Using built in search and replace? If your Find and
Replace function has a GREP option, you sometimes need to to turn
this off. Basically I am saying, need more details of what is
going on that you can see at your end. You might need to take a
closer look a your preferences (options), to take care of spaces
(these are important in searches). The program may be corrupt. If
you get a Mac and BBEdit or TextWrangler you will have no trouble
over such simple issues...
 
N

Neredbojias

With neither quill nor qualm, Richard Sexton quothed:
I used to say this too. I've used Windows since version 1.0. No kidding;
although my work is primarily c/unix I've had to use Windows forever.

Until XP I found windows annoying but mosty usable. Now, keep in mind
I'm on a dialup line here at home where I work; my servers are in
another city in another country.

I live far enough away from civilization that dialup is the only
option, period and on a good day I get 28.8. I've never got higher
than that with any modem. There's a 4 db loss between here and the CO.

So, I tried XP. Seems nice for a chnage, but once a month it would
shit itself. SP2? Check. MS anit-spyware ? check. AV? check? Zone
alarm ? Check. Windows update on? Check.

The damn thing spent so much time updating itself
I was lucky to be able to use 75% of my bandwidth.

And it still got infected. I'm not sure on dialup it can update
itself fast enough.

I've written Windowss device drivers for several graphics and
scsi cards. I think I know what I'm doing. But I don't have hours
a day to waste trying to keep it on the air. Meanwhile the mac
somebody gave me as a joke seems to jsut work and doesn't waste
my time. Perhapos one day it will be a problem too, but at the
end of the day I get paid to write C, not unfuck a lame OS.

I'm gad there are people that can use it and keep it on the
air. Much to my own amazement, I am not one of them. Whateever.

I still have an XP box here dor video work but I will not connect
it to the internet. Hot swap SCA is my friend. I use W98 to
connect windows to the net where I need to but I'm phasing
out all MS software here. It just doesn't work.

Yes, I agree, that automatic-update parasite on XP was a BAAAAAAADD
idea. -As are most things that ultimately take control away from the
user.

Interestingly, though, I'll take IE6's javascript performance over the
current Gecko's. It just works better. -And Opera? Hah!
 
N

Neredbojias

With neither quill nor qualm, John Salerno quothed:
Yes, ok, I will buy a Mac just so I can do a search and replace.

Uh, if you have that much money, why not just hire someone who knows
what he's doing to make your web pages for you?
 
R

Richard Sexton

Yes, I agree, that automatic-update parasite on XP was a BAAAAAAADD
idea. -As are most things that ultimately take control away from the
user.

Hey I was fine with jumpers. Plug and pray is dodgy. I had no problems installing
my own drivers. My computer deciding to do things to "help" me when I didn't
ask for help is alarming, intrusive and unproductive.
Interestingly, though, I'll take IE6's javascript performance over the
current Gecko's. It just works better. -And Opera? Hah!

That's what I love about browers. IE is better except where it's wrong, Opera
is better and faster except whee it doesn't work. Firefox is trensy but apart
from that I see no reason to use it.

Doesn't matter to me, stuff has to work in all 3, period. I use Opera because
I can get my work done faster with it than any other browser.
 
N

Neredbojias

With neither quill nor qualm, Richard Sexton quothed:
Hey I was fine with jumpers. Plug and pray is dodgy. I had no problems installing
my own drivers. My computer deciding to do things to "help" me when I didn't
ask for help is alarming, intrusive and unproductive.


That's what I love about browers. IE is better except where it's wrong, Opera
is better and faster except whee it doesn't work. Firefox is trensy but apart
from that I see no reason to use it.

Doesn't matter to me, stuff has to work in all 3, period. I use Opera because
I can get my work done faster with it than any other browser.

He he, yeah, I think we agree. I use Mozilla, though (-not ff), for
its, uh, charisma.
 
J

John Salerno

Neredbojias said:
With neither quill nor qualm, John Salerno quothed:


Uh, if you have that much money, why not just hire someone who knows
what he's doing to make your web pages for you?

sarcasm? i hope so, because mine was....
 
N

Neredbojias

With neither quill nor qualm, John Salerno quothed:
sarcasm? i hope so, because mine was....

Exactly! <grin> That's why I posted in such a plebeian manner.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,770
Messages
2,569,586
Members
45,084
Latest member
HansGeorgi

Latest Threads

Top