473,386 Members | 1,745 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,386 software developers and data experts.

Find non-quoted string using RegEx

Joe
I need to do a find/replace on a column name in DataColumn.Expression.

Is there a way to do the following using RegEx?

MyColumn 10 and Desc = "This is MyColumn desc"

I need to replace the MyColumn which is not in a quoted string.

Thanks,
Joe
Sep 29 '06 #1
4 1799
Do you know what hte value will be beforehand? If so it could be a
simple regex.Replace type of thing.

If you need more info on regex I have a short tutorial on my site:
http://devdistrict.com/CodeDetails.aspx?A=314
Kelly Elias
Webmaster
http://devdistrict.com
Joe wrote:
I need to do a find/replace on a column name in DataColumn.Expression.

Is there a way to do the following using RegEx?

MyColumn 10 and Desc = "This is MyColumn desc"

I need to replace the MyColumn which is not in a quoted string.

Thanks,
Joe
Sep 29 '06 #2
Joe
The problem with replace is that it will replace all instances of the value
even if it is contained in a quoted string. I need to replace the value that
is not in a quoted string.

"Cryptik" <ke*********@gmail.comwrote in message
news:11**********************@m7g2000cwm.googlegro ups.com...
Do you know what hte value will be beforehand? If so it could be a
simple regex.Replace type of thing.

If you need more info on regex I have a short tutorial on my site:
http://devdistrict.com/CodeDetails.aspx?A=314
Kelly Elias
Webmaster
http://devdistrict.com
Joe wrote:
>I need to do a find/replace on a column name in DataColumn.Expression.

Is there a way to do the following using RegEx?

MyColumn 10 and Desc = "This is MyColumn desc"

I need to replace the MyColumn which is not in a quoted string.

Thanks,
Joe

Sep 30 '06 #3
Hi Joe,

The Regular Expression replacement needs to following certain pattern.
Which means that you need to find out a rule what your expression will be.
For example, is your expression always like this

MyColumn 10 and Desc = "This is MyColumn desc"

Or it will be more complex? What are the "MyColumn"s you need to replace
will be? Just replace all that is not in the quotes? Please let me know
more about this, so that I can deliver my further assistance. Thank you!

Kevin Yu
Microsoft Online Community Support

==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscripti...ult.aspx#notif
ications.
Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscripti...t/default.aspx.
==================================================

(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Oct 2 '06 #4
Hi Joe,

I'd like to know if this issue has been resolved yet. Is there anything
that I can help. I'm still monitoring on it. If you have any questions,
please feel free to post them in the community.

Kevin Yu
Microsoft Online Community Support
==================================================
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Oct 5 '06 #5

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

Similar topics

8
by: Yasutaka Ito | last post by:
Hi, Is there a way to find to which control the current control is docked against? For example, let's say I have panel1 and panel2 docked to left within a form. The panel1 is the first one on...
3
by: RobG | last post by:
I would like a query that will tell me the minimum non-zero value in a row. Say I have a table with a column called recordID that contains unique record IDs, and have a set of values named V1,...
6
by: Ravi | last post by:
Hi, I need to find the non-recursive algorithm to find the height of a Binary Tree. Regards, SunLight.
3
by: Bruce D | last post by:
I'm new to .NET and I have a error that is coming up but it's not telling me where the error is coming from (no file). Is that because I'm doing something wrong...or is it a type of error that has...
9
by: Nak | last post by:
Hi there, I'm getting some strange warnings appearing while I'm compiling a couple of setup projects I have in a solution. I'm being informed of the following warnings, WARNING: Unable to...
9
by: Lad | last post by:
Hello How can I find out in Python whether the operand is integer or a character and change from char to int ? Regards, L.
18
by: anand | last post by:
*********************************************************************************************************** #include<stdio.h> #include<conio.h> #include<math.h> void main() { double...
3
usafshah
by: usafshah | last post by:
C:\Documents and Settings\Link>nslookup *** Can't find server name for address 192.168.0.100: Non-existent domain Default Server: UnKnown Address: 192.168.0.100 > mypc *** UnKnown can't find...
11
by: Siddhu | last post by:
Hai, i am student & i have struck up with the following program's output. Kindly help me to reason out why the output goes as which is given below. THE PROGRAM goes as; #include<iostream.h>...
0
by: Bryce | last post by:
I have an ObjectDataSource binding a GridView, with Delete enabled. The following is the declaration (with non-delete stuff left out to save space): <asp:ObjectDataSource...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

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.