Got more questions? Find advice on: ASP | SQL | XML | Windows
in Search
Welcome to RegexAdvice Sign in | Join | Help

Please help me come with an expression!

I require to search for a space which is not part of double quotes. How do I do this?

  • Consider this case......Please help


    Here's the scenario

    There are a list of codes seperated by "comma" like so:
    codes: "Code1 code2 F/UN=\"value1 value2\" code3 code4"
    Now I need to split this string such that i get all the list of codes into an array of somekind,i.e. the elements of the array should be
    [0]: Code1
    [1]: Code2
    [2]: F/UN=\"value1 value2\"
    [3]: code3
    [4]: code4

    i.e, i require to find a regular expression such that we can split on the basis of those spaces which are not part of quotes.

    Can you please help me resolve this issue.

    Thanks & Regards

    arjun

    Sponsor
  • How to do this?

    Suppose there is some string like:

    "This is \"body text\" sample \"body text\" no more"

    Now I need to find matches for all spaces which are not part of the quoted text. (i.e, the space in between the "body text" needs to be excluded).

    How do i do this?Please help.....

     

    Sponsor

This Blog

Syndication

Tags

No tags have been created or used yet.