Notifications
Clear all

[Closed] Get url contents

 MZ1

how we can get content of an url as string?

something like this:


try(destroydialog webbrowser_rollout)catch()
rollout webbrowser_rollout "Web Test" width:600 height:600
(
 dotNetControl wb "System.Windows.forms.WebBrowser" pos:[10,22] width:580 height:200

 on webbrowser_rollout open do 
 (	 
	(wb.url = dotNetObject "System.Uri" "http://www.google.com/" )
	print (wb.text as string)
 )
)
createdialog webbrowser_rollout
1 Reply

Use this(the http link is not valid.):

webStr = ((dotNetObject "System.Net.WebClient").downloadString "http://dl.dropbox.com/fileWithStringData.dat")