Extracting data from wepage

hello all,

i have a senario where i need to get the count of error word on a web page. i have attached an image in that i have marked in yellow so that i need to count the number of error words after that date and time only the one marked in red should not count.

what i have done is i have extracted all the data using data scrapping method from there how can i get the error count only after that date and time or is there any other method to do.

thank you,


Once you have got the datatable we can get the count of that Error word after Datetime using Regex

  1. First convert that datatable to a string using OUTPUT DATATABLE activity where pass dt as input and get the output as string variable named strdt

  2. Then use a simple assign activity like this

int_count = System. Text.RegularExpressions.Regex.Matches(strdt,“ERROR {} Your error”).Count

Where int_count is a variable of type int32

Cheers @sanjay_gowda

1 Like

Hi @sanjay_gowda
You can read the excel and loop through the each row

then use the following code

error_count= System.Text.RegularExpressions.Regex.Matches(row(columnname).ToString.Trim,".\d±\d±\d+,\s\d+]ERROR.*").Count

Nived N

1 Like

@sanjay_gowda Please find the below sample workflow

Regex.zip (2.5 KB)

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.