• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 185
  • Last Modified:

CAPTURING INFORMATION TO A WEBSITE

As a part of our routine work, I need to fill up forms in various goverment websites. This involves mostly details of our clients, such as the passport no, d o birth, etc.. These data we have in a local database (we have an application to save this data locally)

To simplify this task, I have been asked to develop a system that can read the data from our internal database and then post the relevant fields in the government websites.  We have all the required information in our database and we have a  vb form for the staff to fill in the required information.. So the task for me is to map the relevant fields from our form and then post the data to the government website.

Is there a way I can do this with VB coding ?

Kindly advise. An immediate reply would be highly appreciated..

Thanks and regards,

Sree
0
sreejithm
Asked:
sreejithm
  • 2
1 Solution
 
NBSO_ISSCommented:
We use a control callec Mabry HTTPX.  This control will even allow you to send certificate information along with the data to a web page that accepts POST data.  This is an ActiveX control and should run in VB.NET (although we are using it an old application written in VB6)

http://www.ellsworthband.com/index.php?target=desc&progid=2115
0
 
sreejithmAuthor Commented:
Hi,

I managed to passon the user-id and password to the corresponding fields.. But I am unable to call the method to click the "Login" button.

Please find attached,  the section of the source of the website

function submit1_onclick()
{
      if (CreateUserForm.txtLoginID.value == "")
      {
            alert ("Please enter username, username should be at least 4 alphanumeric characters");
            CreateUserForm.txtLoginID.focus();
            return (false);
      }
      // if empty  
      if (CreateUserForm.txtPassword.value == "")
      {
            alert ("Please enter password, password should be at least 4 alphanumeric characters");
            CreateUserForm.txtPassword.focus();
            return (false);
      }

    // password lessthan 4
      if (CreateUserForm.txtPassword.size < 4)
      {
            alert ("Please enter password, password should be at least 4 alphanumeric characters");
            CreateUserForm.txtPassword.focus();
            return (false);
      }
}

-----

I am using a web browser component and the subroutine that I use for posting i

 Private Sub submit(ByRef obj As WebBrowser, ByVal mis As String)
        Dim stat As Boolean

        stat = obj.Document IsNot Nothing

        If stat Then
            obj.Document.Forms(0).InvokeMember(mis)
         End If

End Sub

Kindly help

Thanks and best regards,

0
 
NBSO_ISSCommented:
What about something like this...

MyWebbrowser.Document.Forms(0).Item(2).InvokeMember("Click")
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now