Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to automate web forms?
Message
 
To
02/05/2007 18:07:48
Peter Easson
Catalina Trading
Sydney, Australia
General information
Forum:
Visual FoxPro
Category:
Internet applications
Environment versions
Visual FoxPro:
VFP 8 SP1
Miscellaneous
Thread ID:
01221858
Message ID:
01222295
Views:
22
I follow some the links suggested and I found this:
FUNCTION PageCatalog
	LPARA oIE
	CREATE CURSOR PageCatalog (ItemIndex i, InnerText M, InnerHTML M)
	FOR i = 0 TO oIE.Document.Body.All.Length - 1
		m.ItemIndex = i
		m.InnerText = oIE.Document.Body.All(i).InnerText
		m.InnerHTML = oIE.Document.Body.All(i).InnerHTML
		INSERT INTO PageCatalog FROM MEMVAR
	ENDFOR
ENDFUNC
This will return a cursor with the page catalog; I’d like to do something similar to get the forms catalog and the Fields names associated with each form.

Any ideas?

Thanks!!!





>It's simpler than you think.
>
>cValue = "JA0000165801"
>oIE = CREATEOBJECT("InternetExplorer.Application")
>oIE.Navigate("http://www.fastway.com.au")
>IF WaitForReadyState(oIE)
>        oIE.Document.FTrace.TAG.value = ALLTRIM(cValue)
>        oIE.Document.FTrace.Submit()
>        oIE.Visible = .t.
>ELSE
>        MESSAGEBOX("Internet Connection timed out",64,"Apparently no Internet Connection")
>ENDIF
>
>oIE = null
>
>The WaitForReadyState function can be found by searching for SmartSMS on the fox wikis.
>Basically, this code opens up an instance of IE. Waits for it to be ready. Inserts the value in the field and then submits the form. Normally, cValue should come from another source (not hard coded :-))
>To understand this fully, you should 'view' the source on that website page.
>
>Hope this helps
>
>Peter Easson
B.D.H.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform