1. Welcome to Tacoma World!

    You are currently viewing as a guest! To get full-access, you need to register for a FREE account.

    As a registered member, you’ll be able to:
    • Participate in all Tacoma discussion topics
    • Communicate privately with other Tacoma owners from around the world
    • Post your own photos in our Members Gallery
    • Access all special features of the site

VB.net question

Discussion in 'Technology' started by SuperTacoma, Jun 20, 2011.

  1. Jun 20, 2011 at 9:20 AM
    #1
    SuperTacoma

    SuperTacoma [OP] Well-Known Member

    Joined:
    Sep 12, 2010
    Member:
    #43118
    Messages:
    644
    Gender:
    Male
    First Name:
    Clint
    Tennessee
    Vehicle:
    11 Toyota Prerunner TRD PKG
    Factory Mods Ventshades Bug Deflector Magnaflow Muffler Solid Fold Extang Cover Pop Lock Helix Power Tower Westin Brush Guard Westin Nerf Bars color match Scoop Hood
    I am looking to increment a field automatically starting at 1000.
    So when they first logon the field will be 1000 then after they print it will go to 1001 etc.
    Anyone got any ideas?
    Thanks
     
  2. Jun 20, 2011 at 9:51 AM
    #2
    nomad_archer

    nomad_archer Well-Known Member

    Joined:
    Apr 14, 2010
    Member:
    #35243
    Messages:
    514
    Gender:
    Male
    First Name:
    Trevor
    Brickerville (Lititz), PA
    Vehicle:
    08 DC Tacoma V6 SR5
    Gonna need more info.
    Is this the code behind for an asp page or a windows form?
    What data type is your "field"?
    What is print doing? Is it send a document to a printer?
    How is that action triggered? a button or event?

    From the little info you gave it sounds like you have an int value that gets initialized at 1000 and after the print action then number goes to itself +1

    Im a c# guy so I dont know the syntax for vb.net
    but this should be easy enough to translate

    int field;

    constructor ()
    {
    field = 1000;
    }

    private void print()
    {
    // do whatever print is here
    field++;
    }
     
To Top