<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: String Manipulation-Fetch data in between the string in Product Forum</title>
    <link>https://community.blueprism.com/t5/Product-Forum/String-Manipulation-Fetch-data-in-between-the-string/m-p/97019#M45123</link>
    <description>&lt;P&gt;Hi &lt;a href="https://community.blueprism.com/t5/user/viewprofilepage/user-id/69"&gt;@NirbhayMishra&lt;/a&gt;&lt;BR /&gt;&lt;BR /&gt;You can use the "Split Text" action from "Utility - Strings" Object​. If you don't have the object, you can get it from &lt;A href="https://digitalexchange.blueprism.com/dx/entry/3439/solution/utility---strings" target="_blank" rel="noopener"&gt;here.&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It should look like this &lt;span class="lia-inline-image-display-wrapper" image-alt="35256.png"&gt;&lt;img src="https://community.blueprism.com/t5/image/serverpage/image-id/35318i67FBC80FFA4FD2C7/image-size/large?v=v2&amp;amp;px=999" role="button" title="35256.png" alt="35256.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;And your output will be like in a collection like this &lt;span class="lia-inline-image-display-wrapper" image-alt="35257.png"&gt;&lt;img src="https://community.blueprism.com/t5/image/serverpage/image-id/35321iC44A1848105E790A/image-size/large?v=v2&amp;amp;px=999" role="button" title="35257.png" alt="35257.png" /&gt;&lt;/span&gt;&lt;BR /&gt;Alternatively, you can use calculation stage that will look like this, &lt;span class="lia-inline-image-display-wrapper" image-alt="35258.png"&gt;&lt;img src="https://community.blueprism.com/t5/image/serverpage/image-id/35322i5216F91D61A18600/image-size/large?v=v2&amp;amp;px=999" role="button" title="35258.png" alt="35258.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Mid([Data1], InStr(Upper([Data1]), "CONTACT PERSON")+16, InStr(Upper([Data1]), "TELEPHONE")-(InStr(Upper([Data1]), "CONTACT PERSON"))-16)&lt;BR /&gt;&lt;BR /&gt;This exact calculation stage will give you the exact name. The way it works that it gets you everything that is between the words "CONTACT PERSON" and "TELEPHONE".&lt;BR /&gt;You can apply the same logic by changing the words you're searching for and as well the number of digits which is 16 in the previous example. You might want to reduce it or increase it.&lt;BR /&gt;&lt;BR /&gt;Hope that helps.&lt;/P&gt;</description>
    <pubDate>Mon, 09 Jan 2023 13:32:45 GMT</pubDate>
    <dc:creator>EslamGhandour</dc:creator>
    <dc:date>2023-01-09T13:32:45Z</dc:date>
    <item>
      <title>String Manipulation-Fetch data in between the string</title>
      <link>https://community.blueprism.com/t5/Product-Forum/String-Manipulation-Fetch-data-in-between-the-string/m-p/97012#M45116</link>
      <description>Hi Community,&lt;BR /&gt;&lt;BR /&gt;I have a string in a variable that looks as following:&lt;BR /&gt;"Name : Nirbhay Mishra&lt;BR /&gt;Profile : Intelligent Automation&lt;BR /&gt;Age : 42&lt;BR /&gt;abc@xyz.in"&lt;BR /&gt;I want to fetch the value of Name, Profile and Age in separate variables for further processing.&lt;BR /&gt;What are the possible ways to do that ?</description>
      <pubDate>Wed, 04 Jan 2023 11:36:08 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/String-Manipulation-Fetch-data-in-between-the-string/m-p/97012#M45116</guid>
      <dc:creator>NirbhayMishra</dc:creator>
      <dc:date>2023-01-04T11:36:08Z</dc:date>
    </item>
    <item>
      <title>Re: String Manipulation-Fetch data in between the string</title>
      <link>https://community.blueprism.com/t5/Product-Forum/String-Manipulation-Fetch-data-in-between-the-string/m-p/97013#M45117</link>
      <description>&lt;P&gt;Hi!&lt;/P&gt;
&lt;P&gt;Maybe you can provide a screenshot of the value inside the data item you're talking about?&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;The reason for my question is to know if the value is a one line string that holds all the value which will looks something like "Name : Nirbhay MishraProfile : Intelligent Automation" or it will be separated by a line.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;If by lines, you can easily use the "Split Text" action from Utility - Strings, this will give you a collection with each value in a row for easy manipulation.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;If it's a one line string, you can use the below expression in a calculation stage. Assuming your input is saved in a Data Item called "&lt;STRONG&gt;Data1&lt;/STRONG&gt;" and there is a space before and after the colons as the example you provided. This should be giving you an output of the name as it lies between "&lt;STRONG&gt;Name&lt;/STRONG&gt;" and "&lt;STRONG&gt;Profile&lt;/STRONG&gt;" words. &lt;SPAN style="text-decoration: underline;"&gt;I added a screenshot and the exact syntax for easier copying&lt;/SPAN&gt;.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;P&gt;Mid([Data1], InStr(Upper([Data1]), "NAME")+7, InStr(Upper([Data1]), "PROFILE")-(InStr(Upper([Data1]), "NAME"))-7)&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="35241.png"&gt;&lt;img src="https://community.blueprism.com/t5/image/serverpage/image-id/35304iA1E0054A2D26195F/image-size/large?v=v2&amp;amp;px=999" role="button" title="35241.png" alt="35241.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;You can modify the words and the numbers to get different values.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 04 Jan 2023 13:03:51 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/String-Manipulation-Fetch-data-in-between-the-string/m-p/97013#M45117</guid>
      <dc:creator>EslamGhandour</dc:creator>
      <dc:date>2023-01-04T13:03:51Z</dc:date>
    </item>
    <item>
      <title>Re: String Manipulation-Fetch data in between the string</title>
      <link>https://community.blueprism.com/t5/Product-Forum/String-Manipulation-Fetch-data-in-between-the-string/m-p/97014#M45118</link>
      <description>&lt;a href="https://community.blueprism.com/t5/user/viewprofilepage/user-id/69"&gt;@NirbhayMishra&lt;/a&gt;&lt;BR /&gt;&lt;BR /&gt;If you look in Blue Prism's "Utility - Strings" VBO , there is a nice little action called "Extract Regex All Matches" (&lt;EM&gt;you might have to pull a later one from the Digital Exchange depending on your version of the VBO&lt;/EM&gt;) which allows you to extract values into a collection using a Regex pattern with capture groups. For the example above, the following Regex pattern would extract the values:&lt;BR /&gt;
&lt;PRE class="language-markup"&gt;&lt;CODE&gt;Name\s:\s(?&amp;lt;Name&amp;gt;.*)[\r\n]+Profile\s:\s(?&amp;lt;Profile&amp;gt;.*)[\r\n]+Age\s:\s(?&amp;lt;Age&amp;gt;.*)[\r\n]+​&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;BR /&gt;The action would look like the following:&lt;/P&gt;
&lt;DIV class="media" style="overflow: hidden; zoom: 1;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="35242.png"&gt;&lt;img src="https://community.blueprism.com/t5/image/serverpage/image-id/35305i3FEEB4934791D474/image-size/large?v=v2&amp;amp;px=999" role="button" title="35242.png" alt="35242.png" /&gt;&lt;/span&gt;&lt;BR /&gt;The output collection would be:&lt;BR /&gt;
&lt;DIV class="media" style="overflow: hidden; zoom: 1;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="35243.png"&gt;&lt;img src="https://community.blueprism.com/t5/image/serverpage/image-id/35307iE4AE48385C98D246/image-size/large?v=v2&amp;amp;px=999" role="button" title="35243.png" alt="35243.png" /&gt;&lt;/span&gt;&lt;/DIV&gt;
&lt;BR /&gt;With that you can simply refer to the collection fields [Regex Matches.Name], [Regex Matches.Profile] and [Regex Matches.Age] to get your data.&lt;/DIV&gt;
​&lt;BR /&gt;The real neat thing about this action though is that if you have a document with multiple sets of that same formatted data, the action can extract each set into it's own row in the collection.</description>
      <pubDate>Wed, 04 Jan 2023 14:14:00 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/String-Manipulation-Fetch-data-in-between-the-string/m-p/97014#M45118</guid>
      <dc:creator>MichealCharron</dc:creator>
      <dc:date>2023-01-04T14:14:00Z</dc:date>
    </item>
    <item>
      <title>Re: String Manipulation-Fetch data in between the string</title>
      <link>https://community.blueprism.com/t5/Product-Forum/String-Manipulation-Fetch-data-in-between-the-string/m-p/97015#M45119</link>
      <description>&lt;DIV id="ViewAnswer_bc811092-b3b9-4fcd-93ac-01857da37e56-answer-content" class="col-xs-12"&gt;Hi&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;a href="https://community.blueprism.com/t5/user/viewprofilepage/user-id/69"&gt;@NirbhayMishra&lt;/a&gt;&lt;BR /&gt;&lt;BR /&gt;You can try by using action&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;Extract Text Field&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;action from&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;Utility Strings&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;​VBO. give inputs pretext&amp;nbsp; &amp;nbsp;&lt;STRONG&gt;Name :&lt;/STRONG&gt;&amp;nbsp; and post text&amp;nbsp;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;Profile&lt;/STRONG&gt;.&lt;BR /&gt;Use separate actions to extract Name, Profile and Age by giving proper pretext and post text&amp;nbsp;&lt;BR /&gt;I hope this helps,&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;Soumya&lt;/DIV&gt;</description>
      <pubDate>Wed, 04 Jan 2023 15:47:33 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/String-Manipulation-Fetch-data-in-between-the-string/m-p/97015#M45119</guid>
      <dc:creator>Soumya21</dc:creator>
      <dc:date>2023-01-04T15:47:33Z</dc:date>
    </item>
    <item>
      <title>Re: String Manipulation-Fetch data in between the string</title>
      <link>https://community.blueprism.com/t5/Product-Forum/String-Manipulation-Fetch-data-in-between-the-string/m-p/97016#M45120</link>
      <description>Hi &lt;a href="https://community.blueprism.com/t5/user/viewprofilepage/user-id/69"&gt;@NirbhayMishra&lt;/a&gt;&lt;BR /&gt;&lt;BR /&gt;You can try by using action &lt;STRONG&gt;Extract Text Field&lt;/STRONG&gt; action from &lt;STRONG&gt;Utility Strings&lt;/STRONG&gt; ​VBO. give inputs pretext&amp;nbsp; &amp;nbsp;&lt;STRONG&gt;Name :&lt;/STRONG&gt;&amp;nbsp; and post text&amp;nbsp; &lt;STRONG&gt;Profile&lt;/STRONG&gt;.&lt;BR /&gt;Use separate actions to extract Name, Profile and Age by giving proper pretext and post text&amp;nbsp;&lt;BR /&gt;I hope this helps,&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;Soumya</description>
      <pubDate>Wed, 04 Jan 2023 16:35:44 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/String-Manipulation-Fetch-data-in-between-the-string/m-p/97016#M45120</guid>
      <dc:creator>Soumya21</dc:creator>
      <dc:date>2023-01-04T16:35:44Z</dc:date>
    </item>
    <item>
      <title>Re: String Manipulation-Fetch data in between the string</title>
      <link>https://community.blueprism.com/t5/Product-Forum/String-Manipulation-Fetch-data-in-between-the-string/m-p/97017#M45121</link>
      <description>&lt;DIV class="media" style="overflow: hidden; zoom: 1;"&gt;
&lt;DIV class="media" style="overflow: hidden; zoom: 1;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="35246.jpg"&gt;&lt;img src="https://community.blueprism.com/t5/image/serverpage/image-id/35309i94F32C78FC55E1D8/image-size/large?v=v2&amp;amp;px=999" role="button" title="35246.jpg" alt="35246.jpg" /&gt;&lt;/span&gt;&lt;/DIV&gt;
&lt;BR /&gt;Hi &lt;a href="https://community.blueprism.com/t5/user/viewprofilepage/user-id/48138"&gt;@EslamGhandour&lt;/a&gt; above is the screenshot of the value inside the data item I am talking about.&lt;BR /&gt;I need to fetch Contact Person, Telephone number and Number of cartons from this data item.&lt;BR /&gt;&lt;BR /&gt;Can you please help how can I achieve that ?&lt;/DIV&gt;
​​</description>
      <pubDate>Mon, 09 Jan 2023 13:10:13 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/String-Manipulation-Fetch-data-in-between-the-string/m-p/97017#M45121</guid>
      <dc:creator>NirbhayMishra</dc:creator>
      <dc:date>2023-01-09T13:10:13Z</dc:date>
    </item>
    <item>
      <title>Re: String Manipulation-Fetch data in between the string</title>
      <link>https://community.blueprism.com/t5/Product-Forum/String-Manipulation-Fetch-data-in-between-the-string/m-p/97018#M45122</link>
      <description>Hi &lt;a href="https://community.blueprism.com/t5/user/viewprofilepage/user-id/548"&gt;@MichealCharron&lt;/a&gt;&lt;BR /&gt;Using the solution you suggested I tried using &lt;SPAN&gt;&lt;SPAN&gt;&amp;nbsp;"Extract Regex All Matches"&amp;nbsp; for extracting the data from data item as in snip below:&lt;BR /&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;
&lt;DIV class="media" style="overflow: hidden; zoom: 1;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="35251.jpg"&gt;&lt;img src="https://community.blueprism.com/t5/image/serverpage/image-id/35310iF6C082A83194BAA1/image-size/large?v=v2&amp;amp;px=999" role="button" title="35251.jpg" alt="35251.jpg" /&gt;&lt;/span&gt;&lt;BR /&gt;I used following regex :&lt;BR /&gt;"Contact person\s:\s(?&amp;lt;Contact person&amp;gt;.*)[\r\n]+Telephone number\s:\s(?&amp;lt;Telephone number&amp;gt;.*)[\r\n]+Number of cartons\s:\s(?&amp;lt;Number of cartons&amp;gt;.*)[\r\n]+​"&lt;BR /&gt;&lt;BR /&gt;It is erroring out with Exception :&amp;nbsp;&lt;BR /&gt;Internal : Could not execute code stage because exception thrown by code stage: parsing "Contact person\s:\s(?&amp;lt;Contact person&amp;gt;.*)[\r\n]+Telephone number\s:\s(?&amp;lt;Telephone number&amp;gt;.*)[\r\n]+Number of cartons\s:\s(?&amp;lt;Number of cartons&amp;gt;.*)[\r\n]+​" - Invalid group name: Group names must begin with a word character.&lt;BR /&gt;refer the snip below for reference:&lt;BR /&gt;
&lt;DIV class="media" style="overflow: hidden; zoom: 1;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="35252.jpg"&gt;&lt;img src="https://community.blueprism.com/t5/image/serverpage/image-id/35313i9010E0644949C63D/image-size/large?v=v2&amp;amp;px=999" role="button" title="35252.jpg" alt="35252.jpg" /&gt;&lt;/span&gt;&lt;/DIV&gt;
&lt;BR /&gt;I tried finding the solution and making some changes here and there but nothing seems to be working, can you please suggest how can we resolve this or any workaround to &lt;SPAN&gt;fetch Contact Person, Telephone number and Number of cartons&lt;/SPAN&gt;&lt;/DIV&gt;
​​​</description>
      <pubDate>Mon, 09 Jan 2023 13:19:14 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/String-Manipulation-Fetch-data-in-between-the-string/m-p/97018#M45122</guid>
      <dc:creator>NirbhayMishra</dc:creator>
      <dc:date>2023-01-09T13:19:14Z</dc:date>
    </item>
    <item>
      <title>Re: String Manipulation-Fetch data in between the string</title>
      <link>https://community.blueprism.com/t5/Product-Forum/String-Manipulation-Fetch-data-in-between-the-string/m-p/97019#M45123</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.blueprism.com/t5/user/viewprofilepage/user-id/69"&gt;@NirbhayMishra&lt;/a&gt;&lt;BR /&gt;&lt;BR /&gt;You can use the "Split Text" action from "Utility - Strings" Object​. If you don't have the object, you can get it from &lt;A href="https://digitalexchange.blueprism.com/dx/entry/3439/solution/utility---strings" target="_blank" rel="noopener"&gt;here.&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It should look like this &lt;span class="lia-inline-image-display-wrapper" image-alt="35256.png"&gt;&lt;img src="https://community.blueprism.com/t5/image/serverpage/image-id/35318i67FBC80FFA4FD2C7/image-size/large?v=v2&amp;amp;px=999" role="button" title="35256.png" alt="35256.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;And your output will be like in a collection like this &lt;span class="lia-inline-image-display-wrapper" image-alt="35257.png"&gt;&lt;img src="https://community.blueprism.com/t5/image/serverpage/image-id/35321iC44A1848105E790A/image-size/large?v=v2&amp;amp;px=999" role="button" title="35257.png" alt="35257.png" /&gt;&lt;/span&gt;&lt;BR /&gt;Alternatively, you can use calculation stage that will look like this, &lt;span class="lia-inline-image-display-wrapper" image-alt="35258.png"&gt;&lt;img src="https://community.blueprism.com/t5/image/serverpage/image-id/35322i5216F91D61A18600/image-size/large?v=v2&amp;amp;px=999" role="button" title="35258.png" alt="35258.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Mid([Data1], InStr(Upper([Data1]), "CONTACT PERSON")+16, InStr(Upper([Data1]), "TELEPHONE")-(InStr(Upper([Data1]), "CONTACT PERSON"))-16)&lt;BR /&gt;&lt;BR /&gt;This exact calculation stage will give you the exact name. The way it works that it gets you everything that is between the words "CONTACT PERSON" and "TELEPHONE".&lt;BR /&gt;You can apply the same logic by changing the words you're searching for and as well the number of digits which is 16 in the previous example. You might want to reduce it or increase it.&lt;BR /&gt;&lt;BR /&gt;Hope that helps.&lt;/P&gt;</description>
      <pubDate>Mon, 09 Jan 2023 13:32:45 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/String-Manipulation-Fetch-data-in-between-the-string/m-p/97019#M45123</guid>
      <dc:creator>EslamGhandour</dc:creator>
      <dc:date>2023-01-09T13:32:45Z</dc:date>
    </item>
    <item>
      <title>Re: String Manipulation-Fetch data in between the string</title>
      <link>https://community.blueprism.com/t5/Product-Forum/String-Manipulation-Fetch-data-in-between-the-string/m-p/97020#M45124</link>
      <description>&lt;a href="https://community.blueprism.com/t5/user/viewprofilepage/user-id/69"&gt;@NirbhayMishra&lt;/a&gt;&lt;BR /&gt;&lt;BR /&gt;The following Regex pattern would probably work for you:&lt;BR /&gt;
&lt;PRE class="language-markup"&gt;&lt;CODE&gt;Contact\sperson:\s(?&amp;lt;ContactPerson&amp;gt;.*)[\r\n]+Telephone\snumber:\s(?&amp;lt;TelephoneNumber&amp;gt;.*)[\r\n]+Number\sof\scartons:\s(?&amp;lt;NumberOfCartons&amp;gt;.*)[\r\n]+​&lt;/CODE&gt;&lt;/PRE&gt;
&lt;BR /&gt;The differences between my pattern and yours is:
&lt;UL&gt;
&lt;LI&gt;The Named Capture Groups "?&amp;lt;&lt;EM&gt;CaptureGroupName&lt;/EM&gt;&amp;gt;" cannot contain spaces. The name can contain an underscore instead of a space but I am a CamelCase person so you never see me using underscores.&lt;/LI&gt;
&lt;LI&gt;The "\s" is a shorthand character class for for white space. Most of the time you can just use a simple space but I have been caught so many times with a tab that I've conditioned myself to use the "\s" instead.&lt;/LI&gt;
&lt;/UL&gt;
&lt;BR /&gt;​</description>
      <pubDate>Mon, 09 Jan 2023 14:00:47 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/String-Manipulation-Fetch-data-in-between-the-string/m-p/97020#M45124</guid>
      <dc:creator>MichealCharron</dc:creator>
      <dc:date>2023-01-09T14:00:47Z</dc:date>
    </item>
  </channel>
</rss>

