Simon K Posted November 22, 2007 Posted November 22, 2007 (edited) Hi everyone I wish to get some data back from a URL...The URL is in the form of a "submission string" and I have correctly formatted the query string parameters to bring back data. The returned data only consists of two lines of text in CSV format - the first being a header. The second is 4 very short fields. On a layout I have a web viewer object named wvmileage If i use a "custom url" ("http" etc as above) it does indeed return the text file into the viewer and if I then (in a script) set variable: $temp = GetLayoutObjectAttribute("wvMileage";"content") then $temp correctly returns the content of text file. So far so good. BUT the URL used is a chargeable web service and I really don't want the web viewer raising the query everytime the window is opened. So I am trying to write a script that only queries the service when a button is clicked ie using the set web viewer script step with "go to URL". It works but now the $temp calc just returns an empty value... Does anyone know why - is it a timing thing - does the web viewer have to show the result data before the GetLayoutObjectAttribute("wvMileage";"content") will work? Many thanks Edited November 22, 2007 by Guest
aholtzapfel Posted November 26, 2007 Posted November 26, 2007 When do it this way you(or any way) you should check if the web page has been loaded into the webviewer before you set your variable. Here is the code I use for html documents (the
Simon K Posted November 27, 2007 Author Posted November 27, 2007 Hi, thanks for that, will test in morning and let you know how i get on.
Recommended Posts
This topic is 6218 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now