Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8133513
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T09:37:41+00:00 2026-06-06T09:37:41+00:00

Ok, let me preface this question with the fact that I am extremely new

  • 0

Ok, let me preface this question with the fact that I am extremely new to vb script, but I need to make an addition to a script that another developer created and he is away.

Problem. :
I am getting data that is feed into a process. The script I already have handles some things that I won’t go into. One thing I found out that it doesn’t handle correctly is commas that occur in double quotes.

So I get some data like this. :

Joe, Bill, James, Alex, “Google, Inc”, Rose, “Kickstarter, LLC”

What happens is that when this script kicks to the process application it blows up because of these commas in the double quotes. I need to be able to have this script go in and replace those commas in the Google and Kickstarter blocks with something a little more unique.

If you have the answer to this I would appreciate it, but I wouldn’t mind some direction either of something that does something like this, etc.

Any answers are greatly appreciated. Again very new to vbascript just started reading syntax on it today.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-06T09:37:43+00:00Added an answer on June 6, 2026 at 9:37 am

    You left out a few details about the format of the input data and the replacement text. However, the approach you need to take is to use the regular expression capability of VBScript to identify patterns in your input data, then use the “Replace” method to replace them. Here’s a short MS article about regular expressions in VBScript.

    Here’s an example of what it might look like. This example is definitely NOT bullet proof and it makes some assumptions, but I think it will get you started:

    Dim re, strstr, newstrstr
    Dim inputstrarray(7)
    Set re = new regexp 
    
    inputstrarray(0) = "Joe"
    inputstrarray(1) = "Bill"
    inputstrarray(2) = "James"
    inputstrarray(3) = "Alex"
    inputstrarray(4) = """" & "Google, Inc" & """"
    inputstrarray(5) = "Rose"
    inputstrarray(6) = """" & "Kickstarter, LLC" & """"
    
    re.pattern = ",\s"  'pattern is a comma followed by a space
    For Each strstr In inputstrarray 'loop through each string in the array
        newstrstr = re.Replace(strstr, "_")  'replace the pattern with an underscore
        If StrComp(strstr,newstrstr) Then 
            Wscript.Echo "Replace " & strstr & " with " & newstrstr
        Else
            Wscript.Echo "No Change"   
        End If
    Next
    

    Output looks like the following:

    No Change
    No Change
    No Change
    No Change
    Replace "Google, Inc" with "Google_Inc"
    No Change
    Replace "Kickstarter, LLC" with "Kickstarter_LLC"
    No Change
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Let me preface this question by stating that I'm not a C# developer. I'm
Before the question, let me preface this with the fact that I am working
Let me preface this question with first stating that I'm new to GUI interfaces:
First let me preface this question by saying that I'm fairly new to Javascript.
Let me preface this by saying I am extremely new to git but have
Let me preface this question by saying that I am a .NET developer at
Let me preface this question by saying that I am relatively new to writing
Let me preface by saying that I saw this other question on the subject
First, let me preface this by saying that I'm brand-new to Ember.js and relatively
Let me preface this with the disclaimer that I am very new to multithreading

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.