Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default filling web forms from excel

Hi,

I need to develope a solution which will fill up web forms directly
from excel. Sub should loop trough cells and automatically submit each
data input. I found an earlier post "Filling out usernames in IE", but
when I try to use it with google.com for example within this code
posted by 6/10/2006 9:30:22 AM by: Randy Harmelink, quote:

Sub google_search()
Set oForm = oIE.Document.forms(0)
For Each oCell In Sheets(1).Range("A1:A500")
If oCell.Value = "" Then Exit For
oForm("f").Value = oCell.Offset(0, 0)
oForm(".save2").Click
Do: DoEvents: Loop While oIE.Busy
Do: DoEvents: Loop Until oIE.ReadyState = READYSTATE_COMPLETE
Set oForm = oIE.Document.forms(0)
Next oCell
oForm(".cancel").Click
End Sub


I've changed it a bit to suit my needs. When i run this it displays
error msg "Object required" on line "Set oForm =
oIE.Document.forms(0)". I have references set to minrosoft internet
controls. I don't know what else to do. Please advise on this. Thanks.

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,588
Default filling web forms from excel

You haven't set the oIE variable.

Tim


"iCalculate" wrote in message
oups.com...
Hi,

I need to develope a solution which will fill up web forms directly
from excel. Sub should loop trough cells and automatically submit each
data input. I found an earlier post "Filling out usernames in IE", but
when I try to use it with google.com for example within this code
posted by 6/10/2006 9:30:22 AM by: Randy Harmelink, quote:

Sub google_search()
Set oForm = oIE.Document.forms(0)
For Each oCell In Sheets(1).Range("A1:A500")
If oCell.Value = "" Then Exit For
oForm("f").Value = oCell.Offset(0, 0)
oForm(".save2").Click
Do: DoEvents: Loop While oIE.Busy
Do: DoEvents: Loop Until oIE.ReadyState = READYSTATE_COMPLETE
Set oForm = oIE.Document.forms(0)
Next oCell
oForm(".cancel").Click
End Sub


I've changed it a bit to suit my needs. When i run this it displays
error msg "Object required" on line "Set oForm =
oIE.Document.forms(0)". I have references set to minrosoft internet
controls. I don't know what else to do. Please advise on this. Thanks.



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Auto filling Forms ClintN Excel Worksheet Functions 1 June 1st 09 12:30 PM
Filling up Forms tc Excel Discussion (Misc queries) 1 September 10th 07 03:20 PM
filling combox box with same logic in 2 < forms François Excel Programming 0 March 31st 06 12:07 PM
Where do I find a template for filling out 1099-MISC forms? Anne Troy Excel Discussion (Misc queries) 0 February 13th 06 06:59 AM


All times are GMT +1. The time now is 08:37 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"