Fill a web form using C#

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • nfollmer
    New Member
    • May 2007
    • 10

    Fill a web form using C#

    Hi,

    After getting so much help from this site, I decided to join! But thats beside the point....

    I'm fairly experienced in C#, but never did anything web related, so I need some help.

    What I want to do, is have a drivers license be scanned by our card readers, take all the information we need (dl number, state, address, name, date of birth) and place it into a form on another website, (autofill the information basically). I wrote the part of the program that gets all the info off the card and formats it in all the variables I have for the names and such, now i need to know how to move it to the form.

    I may be mistaking, but what I get from the form, the front end is just a simple html form, then it runs a javascript app to move all the data to their server. I got all the textbox names with firefox's web developer add on. Is there anyway to send all my variables to the textboxes they belong in. Sorry for the long post, and thanks for all the previous help!
  • Frinavale
    Recognized Expert Expert
    • Oct 2006
    • 9749

    #2
    Originally posted by nfollmer
    Hi,

    After getting so much help from this site, I decided to join! But thats beside the point....

    I'm fairly experienced in C#, but never did anything web related, so I need some help.

    What I want to do, is have a drivers license be scanned by our card readers, take all the information we need (dl number, state, address, name, date of birth) and place it into a form on another website, (autofill the information basically). I wrote the part of the program that gets all the info off the card and formats it in all the variables I have for the names and such, now i need to know how to move it to the form.

    I may be mistaking, but what I get from the form, the front end is just a simple html form, then it runs a javascript app to move all the data to their server. I got all the textbox names with firefox's web developer add on. Is there anyway to send all my variables to the textboxes they belong in. Sorry for the long post, and thanks for all the previous help!
    Is the form already created on the server?
    Is your application that reads the drivers licenses a web based system?

    If it's a Windows application, have you thought about implementing it so that it generates a web-form with in the information...s etting the submit to call the web application you need to submit to?...Just a thought.

    Cheers!

    -Frinny

    Comment

    • nfollmer
      New Member
      • May 2007
      • 10

      #3
      Originally posted by Frinavale
      Is the form already created on the server?
      Is your application that reads the drivers licenses a web based system?

      If it's a Windows application, have you thought about implementing it so that it generates a web-form with in the information...s etting the submit to call the web application you need to submit to?...Just a thought.

      Cheers!

      -Frinny
      The form is actually used to do cell phone activations, I wanted to make a small program that sent all the data to whatever service provider we were running credit for. And no, its not a web based app, its windows. I was going to install in on all the people who want to use it. Through further research on both websites I want to use, they are both using javascript and only one (cingular if your wondering) uses an html form and then passes that data to the javascript. Verizons form is strictly javascript.
      Thanks for the reply!

      Comment

      • Frinavale
        Recognized Expert Expert
        • Oct 2006
        • 9749

        #4
        Originally posted by nfollmer
        The form is actually used to do cell phone activations, I wanted to make a small program that sent all the data to whatever service provider we were running credit for. And no, its not a web based app, its windows. I was going to install in on all the people who want to use it. Through further research on both websites I want to use, they are both using javascript and only one (cingular if your wondering) uses an html form and then passes that data to the javascript. Verizons form is strictly javascript.
        Thanks for the reply!

        I'm confused about what you're talking about the other web pages using JavaScript.

        In order to submit a web-form you have to fill out a form. Web forms are HTML. JavaScript maybe used to validate the information, do some visual effects, or be called to submit the form on the click of a button.

        Anyways, while I was browsing theScripts just now I came across a thread in which someone else is trying to do something similar. They posted this link and I was wondering if it could help you. I know that it has a lot to do with web programming but the one component covered on that site might be helpful.

        Cheers!

        -Frinny

        Comment

        • Motoma
          Recognized Expert Specialist
          • Jan 2007
          • 3236

          #5
          You should take a look at the HTTP specification side by side with the website's source code. Fire up Wireshark and take a look at the data that is getting sent back and forth from the website to your browser. Pay attention to the POSTs, GETs, and COOKIE data.

          You will need to establish a TCP connection to the webserver, and intelligently emulate a web browser (i.e. perform all of the actions that your browser does when it continues through the site).

          Your best bet, however, would be to contact the site and see if there is a better way you could work this out, perhaps set up an API for passing and receiving information with XML.

          Comment

          • nfollmer
            New Member
            • May 2007
            • 10

            #6
            Originally posted by Frinavale
            I'm confused about what you're talking about the other web pages using JavaScript.

            In order to submit a web-form you have to fill out a form. Web forms are HTML. JavaScript maybe used to validate the information, do some visual effects, or be called to submit the form on the click of a button.

            Anyways, while I was browsing theScripts just now I came across a thread in which someone else is trying to do something similar. They posted this link and I was wondering if it could help you. I know that it has a lot to do with web programming but the one component covered on that site might be helpful.

            Cheers!

            -Frinny
            That did the trick, thats alot! I knew someone here could help me. If anyone else needs to see how this is done, (I did mine just a little different) I'll post the code once I have all the bugs worked out :)

            Comment

            Working...