AnsweredAssumed Answered

Obtain infor from html and check values to compare

Question asked by hjvanes on Feb 1, 2014
Latest reply on Feb 5, 2014 by hjvanes

dear Filemake PPL,

 

I was wondering is there a way to ctmompare and check off values from a website to a value stored in a sollution.

 

That is my solition will have a values such as 102-103 as an example.

 

The website html will store values after

<html>

102-101

102-102

102-103

102-104

102-15

</html>

 

 

The idea is for the solution to do a check I believe maybe with webviewwer all before </html> and a loop thorugh the values. I do know how I can do this if there were only one value stored in the html and compare.

 

Set webviewer [object name.....

set variable [$html ; value getlayoutobjectattribute (VW ; "Content")]

Set variable [web$; value: Let ( [t1 = "<body>" ;t2 = "</body>" ;p1 = Position ( $HTML ; t1 ; 1 ; 1 ) ;p2 = Position ( $HTML ; t2 ; 1 ; 1 ) ;HTML = Middle ( $HTML ; p1 + Length ( t1 ) ; p2 - p1 - Length ( t1 ) )] ; Filter ( HTML ; "-0123456789" ))

Set variable [$local; value: "102-103"

set variable [$message;value (Isempty($web); "problem with web"; $web =$local; "No problem"; " Number is not inrecords"

Show Custom Dialog ["Message"; $messsage]

 

This I know would work if only one number existed between <html> and </html>.

 

How Can I go about it that it would loop th

 

 

 

I am not sure how I would script it to loop through every line and p[erform a check against my $local variable as it were to provide a message.

 

Any person have any advice for me on this please or what I would need to change. Thank you in advance and much appreciated for any replies.

 

regards,

HJ

Outcomes