View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
Dick Kusleika[_4_] Dick Kusleika[_4_] is offline
external usenet poster
 
Posts: 595
Default Foto Slide Show...

MESTRELLA29 wrote:
Has anyone done a Macro that displays diferant pictures of fotos?


You can use a userform with a WebBrowser control on it. Then use code like
this

Private Sub UserForm_Click()

Dim pthPictures As String
Dim fleCurrPic As String

pthPictures = "C:\Documents and Settings\All Users\Documents\My
Pictures\Sample Pictures\"

fleCurrPic = Dir(pthPictures & "*.jpg")

Do While Len(fleCurrPic) 0
Me.WebBrowser1.Navigate pthPictures & fleCurrPic
Do
DoEvents
Loop Until Me.WebBrowser1.ReadyState = READYSTATE_COMPLETE
Application.Wait Now + TimeValue("00:00:02")
fleCurrPic = Dir
Loop

MsgBox "Done"

End Sub

See here for more on the WebBrowser control
http://www.dicks-blog.com/archives/2...owser-control/

--
Dick Kusleika
Excel MVP
Daily Dose of Excel
www.dicks-blog.com