Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
WebBrowser control, showing images
Message
From
28/11/2012 09:37:20
 
 
To
26/11/2012 07:16:53
General information
Forum:
Visual FoxPro
Category:
ActiveX controls in VFP
Miscellaneous
Thread ID:
01558038
Message ID:
01558252
Views:
57
>Hi
>
>I'm using the myControl.navigate("C:\MyFile.tif") method to attempt to view a document. However, VFP seems to be using Picture Viewer instead, i.e. opening the tif file outside of the VFP window/myControl. It works fine for .jpg, that is displayed within myControl, but not tifs.
>
>The same issue applies to Word and Excel too, they're both opened externally by VFP and not withing myControl.
>
>Any ideas?
>
>Regards

The file you are accessing needs to be a reference in a HTML format in a physical file. create a temporary file and reference it in the Navigate method.
TEXT TO lcImg NOSHOW TEXTMERGE
	<  HTML><  BODY>
	<Image src="C:\myimage\test.tif" />
	<\BODY><\HTML>
ENDTEXT
lcHTML = "C:\Temp\Img.html"
STRTOFILE(lcImg, lcHTML ,0)
myControl.Navigate(lcHTML)
DO WHILE myControl.ReadyState < 4
	DOEVENTS
ENDDO
ERASE (lcHTML) 
Greg Reichert
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform