November 29, 200718 yr Hi all I want to extract information from the web viewer. Stock prices to be exact. Following info from previous posts I've used GetLayoutObjectAttribute ("Webviewer" ; "Content") to put the content into a calc field (text). I was hoping to find and extract the numbers I wanted with another calc. like a filter or something. Any suggestions for how to get the 58.29 out of this... ......'>CBA58.290 and into my field? Thanks, Phil
November 29, 200718 yr It may depend on what comes before. Is there anything in the quoted string that uniquely identifies the "58.290" value as the one you want?
November 30, 200718 yr Author Yes, the three letter code (in this case CBA) is the variable that should identify it as the right number. In this case I want to extract the 27th to 32nd characters following the occurrence of the unique three letter stock code.
November 30, 200718 yr Well, if you can count on the website keeping it always in the exact same format, it can be simply: Let ( [ HTML = GetLayoutObjectAttribute ( "Webviewer" ; "Content" ) ; pos = Position ( HTML ; "CBA" ; 1 ; 1 ) ] ; Middle ( HTML ; pos + 30 ; 6 ) )
Create an account or sign in to comment