leandro3s
04-10-2012, 08:41 AM
Hello,
I'm newbie in VBA and i'm with a problem related internet explorer.
i'm trying to acess site pdftoexcelonline + .com, click on botton "Browse" (html name ctl00$body$filePDF), select the path and file by variable in the plan1, click ok in the window Change File, fill email with innertext by variable and click in "Convert to Excel".
At moment, i just got to acess the site and click in "Browse" and... nothing more ¬¬.
I'm struggling to interact with the window "Change file" that appears after click on botton "Browse"
Somebody can help me pls ??
thanks
sorry for mistakes language. i'm brazilian.
code:
Sub AcessaPagina()
Dim d1, M2, A1, Wd As String
'local/caminho do arquivo:
d1 = Sheets("Apoio").Range("c3").Value
'arquivo pdf:
M2 = Sheets("Apoio").Range("c4").Value
'email:
A1 = Sheets("Apoio").Range("c5").Value
'local & arquivo:
Wd = d1 & M2
Dim ie As Object
Set ie = CreateObject("InternetExplorer.Application")
ie.Navigate "site pdftoexcel"
While ie.Busy
Wend
ie.Document.getElementsByName("ctl00$body$filePDF").Item.Click
While ie.Busy
Wend
'ie.Document.getElementsByName("ctl00$body$txtEmail").Item.innerText = A1
While ie.Busy
Wend
ie.Visible = True
End Sub
I'm newbie in VBA and i'm with a problem related internet explorer.
i'm trying to acess site pdftoexcelonline + .com, click on botton "Browse" (html name ctl00$body$filePDF), select the path and file by variable in the plan1, click ok in the window Change File, fill email with innertext by variable and click in "Convert to Excel".
At moment, i just got to acess the site and click in "Browse" and... nothing more ¬¬.
I'm struggling to interact with the window "Change file" that appears after click on botton "Browse"
Somebody can help me pls ??
thanks
sorry for mistakes language. i'm brazilian.
code:
Sub AcessaPagina()
Dim d1, M2, A1, Wd As String
'local/caminho do arquivo:
d1 = Sheets("Apoio").Range("c3").Value
'arquivo pdf:
M2 = Sheets("Apoio").Range("c4").Value
'email:
A1 = Sheets("Apoio").Range("c5").Value
'local & arquivo:
Wd = d1 & M2
Dim ie As Object
Set ie = CreateObject("InternetExplorer.Application")
ie.Navigate "site pdftoexcel"
While ie.Busy
Wend
ie.Document.getElementsByName("ctl00$body$filePDF").Item.Click
While ie.Busy
Wend
'ie.Document.getElementsByName("ctl00$body$txtEmail").Item.innerText = A1
While ie.Busy
Wend
ie.Visible = True
End Sub