-
VB6 WebBrowser control
In the vb6 form web browser and default web page open, in this web page contain one textbox where user input the some id number to retrieve information, is there way when we press button from vb from so some number filed in the textbox and execute to retrieve information. This button may act like barcode scanner (filed data in focued field and trigerd).
Thanks for help
Last edited by kafsar; 04-24-2009 at 10:30 AM.
-
Are you talking about a VB textbox on a VB form that also has a VB webbrowser control on it?
I don't answer coding questions via PM or Email. Please post a thread in the appropriate forum section.
Please use [Code]your code goes in here[/Code] tags when posting code.
Before posting your question, did you look here?
Got a question on Linux? Visit our Linux sister site.
Modifications Required For VB6 Apps To Work On Vista
-
here is explanation:
opened web page by VB6 WebBrowser contol, this web page cantain textbox call textbox1 but there no submit button, so when inout the number in the textbox end press enter page retrive informatin from the database. I have the following code which place input data (number or text) in textbox and triger the bubmit button to retrive information automatically, but sine the page have no submit button and only press enter in the textbox to retrive information, please some one look the code and advise how can trigger the input textbox.
code: THIS CODE WORKED FINE IF PAGE HAVE SUBMIT BUTTON.
Private Sub Command1_Click()
Dim htmlSearchButton As HTMLButtonElement
Set docCurrentHTML = WebBrowser1.Document.documentElement.All
' This field the value in web page textbox1
For Each Item In docCurrentHTML
If Item.tagName = "INPUT" Then
If Item.Name = "textbox1" Then
Item.Value = "1148"
Exit For
End If
End If
Next Item
' The data is in. Now find the button and click it,
' HERE IS I HAVE PROBLEM, SINCE THERE IS NO SUBMIT BUTTON THE COSE SHOULS CLICK TEXTBOX1
For Each Item In docCurrentHTML
If Item.tagName = "INPUT" Then
If Item.Name = "textbox1" Then
Set htmlSearchButton = Item
htmlSearchButton.Click
Exit For
End If
End If
Next Item
Thanks
Similar Threads
-
By ehrlich in forum VB Classic
Replies: 1
Last Post: 09-20-2007, 11:12 AM
-
Replies: 0
Last Post: 07-23-2007, 02:26 PM
-
By el__sid in forum VB Classic
Replies: 5
Last Post: 06-24-2005, 10:05 PM
-
By Phil N. in forum VB Classic
Replies: 3
Last Post: 10-30-2001, 09:57 AM
-
By FLD in forum Enterprise
Replies: 2
Last Post: 11-20-2000, 11:34 AM
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
Forum Rules
|
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL
|
Bookmarks