Form

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • jw01
    New Member
    • Dec 2006
    • 19

    #1

    Form

    Hello,

    I am creating a form using Visual basic (includes text boxes & Radio Buttons)e.g
    Name:
    Adress:
    Age:

    The user will fill it out and when sumbit is hit, all the items entered by the user should be filled up in a CSV file.

    Can someone guide me as to how this process goes about in VB.

    Thank you
  • Killer42
    Recognized Expert Expert
    • Oct 2006
    • 8429

    #2
    Originally posted by jw01
    I am creating a form using Visual basic (includes text boxes & Radio Buttons)e.g
    ...
    The user will fill it out and when sumbit is hit, all the items entered by the user should be filled up in a CSV file.
    Can someone guide me as to how this process goes about in VB.
    VB is a largely event-driven language. Once you've placed controls on the form, Windows will generate calls to specific procedures when certain events happen. So for instance, when the user clicks the "submit" button, the click event procedure for that control will be executed.

    What you need to do is go to the Click event procedure for the button, and write some code in there to open a file (with .CSV extension), print/write your fields to it, and close it.

    For more detail, you really should check your documentation. Here are some key terms you can search for:
    • Open
    • Close
    • Print #

      another option - much more functionality, but more complex to use...

    • FileSystemObjec t

    Comment

    Working...