Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I am currently using the Stripping HTML Tags using Regular Expressions - 4GuysFromRolla.com VB script module to remove HTML tags from a field. I am then using TextBetween to break out the DESCRIPTION_CLEANED field to 5 separate fields. It works for the first 4 but for Voting Statement, I don't know what to do as the ending string because the data is being truncated and the Analytics string is sometimes not included. Similarly, for Analytics, I don't know what to put as the final string. Is there a function to pull last characters?
Select DEFECT_ID 8816 or 7474 as examples.
stripHTML(DESCRIPTION) as DESCRIPTION_CLEANED,
TextBetween( stripHTML(DESCRIPTION) , 'Current State Summary:' , 'Problem Statement:' ) as CUR_STATE_SUMMARY,
TextBetween( stripHTML(DESCRIPTION) , 'Problem Statement:' , 'Proposed Solution:' ) as PROBLEM_STATEMENT,
TextBetween( stripHTML(DESCRIPTION) , 'Proposed Solution:' , 'Voting Statement:' ) as PROP_SOLUTION,
TextBetween( stripHTML(DESCRIPTION) , 'Voting Statement:' , 'Analytics:' ) as VOTING_STATEMENT,
TextBetween( stripHTML(DESCRIPTION) , 'Analytics:' , 'Analytics' ) as ANALYTICS,
Not sure may be put an empty string like
TextBetween( stripHTML(DESCRIPTION) , 'Analytics:' , '' ) as ANALYTICS,
Anyone?
Maybe some sort of end function?
Would it be possible to provide a sample HTML string (DESCRIPTION) and what all parts from that you are looking for?
Can you share one example ID where we have data for Analytics: delimiter?
The problem is that it changes. Sometimes it is not populated with text and sometimes it's just HTML formatting.
DEFECT_ID: 6753
Current State Summary:
text here
Problem Statement:
text here
Proposed Solution:
text here
Voting Statement:
text here
Analytics:
<td align="left" valign="middle" width="649" height="117" style="border:
Yes, is there any ID which has this Analytics data? I mean for other text you have some text information between right? From the ID's you have, are there any values with the text for Analytics. Just wanted to check the pattern so that we can come up with some other alternative.
Hi Cassandra,
suggesting a different framework is probally not the solution you are actually looking for, but maybe this framework makes it very much easier for you?
http://html-agility-pack.net/?z=codeplex
Html Agility Pack - HTML Attributes
All the best,
Markus
I can't find one off hand.
And my issue is because sometimes there is no data, I don't know what to put here:
TextBetween( stripHTML(DESCRIPTION) , 'Analytics:' , 'Analytics' ) as ANALYTICS,