473,405 Members | 2,379 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

Autonumber generation in VB

Sir/madam,
I am doing a project on admission procedure using VB6. I am facing certain problems regarding that.....

1) Problem that i am facing is to generate alphanumeric auto numbers in two columns(Rollno. & Reg no.) in same table, in access.
Jul 27 '11 #1
1 1784
You can generate numbers in a VB method and then pass them to DB via INSERT or UPDATE SQL query.

The simplest way is to create a string constant or an array of chars which contains allowed symbols (0-9, A-Z for example), and to take one by one element by random indexes.
Jul 27 '11 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Ed Havelaar | last post by:
Hi, Hope someone can help. Here's the scenario: I have two MSAccess tables MainTab and SubTab. MainTab has an autonumber 'id' column as primary key. Subtab has this id column as a foreign...
7
by: Bob | last post by:
Hi Everybody I have a query that is based on table that I need to have some sort of Unique ID # for. I can't have a unique ID in the table, but the table DOES have a date field and I'm working...
35
by: Traci | last post by:
If I have a table with an autonumber primary key and 100 records and I delete the last 50 records, the next record added would have a primary key of 101. Is there any way to have the primary key...
2
by: Steve | last post by:
I have a database where I want to use an autonumber field to make SKUs for a new product when it is entered. Is there a way I can make the field zero fill to a certain length? For instance, if I...
5
by: ndn_24_7 | last post by:
Hello all, I'm designing a incident reporting program that allows our security department to record incidents. The problem i'm having is on a form, when ever a user is going to add a new...
1
by: arthure212 | last post by:
Access 97: Help on coding an incrementing ID number as part of a larger table. I manage research support for a hospital and we get grants from companies. We issues subcontracts (more than one) to...
11
by: Alan Mailer | last post by:
A project I'm working on is going to use VB6 as a front end. The back end is going to be pre-existing MS Access 2002 database tables which already have records in them *but do not have any...
4
by: kalaisri | last post by:
i would like to generate a report in VB using data report where the back end is MS access.In that report i want 2 generate serial number separately where that column is not available in the table
6
by: mallz | last post by:
hi, i need to automatically generate a sequential number for each record that i insert into the database from my jsp page. how do i do this? im using oracle as my database.
6
by: ashes | last post by:
Hi, I am creating an ecommerce website using Microsoft Visual Studio, VB.Net and MS Access 2003. I am new to VB.Net When someone wants to register on the website, they fill out a form and the...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.