By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
425,940 Members | 611 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 425,940 IT Pros & Developers. It's quick & easy.

Numbering start with 1 each month for each Department

P: 22
I have a form name form 1 with combo box name combo1 which contain list of Departments e.g. Dept A, Dept B, Dept C etc.
And I also have table named cashbook with date, Pv no, name of beneficiary and amount

I want to start numbering from 1 each month for each department when adding new record to the table. Pv no is the field for the numbering. Please help.
Feb 7 '18 #1
Share this Question
Share on Google+
4 Replies

P: 214
Mafi, welcome to Bytes! We would love to guide you to a solution, but need some clarification. When are you trying to number the records? What would a sample table look like with the information filled in? Are you saying that the first day of each month, the numbering for each record for each department starts over at 1 then increments by 1 (1,2,3,...) for each additional record that month?

Help us get a better idea of what you're trying to do and we'll be glad to work with you toward a solution.
Feb 8 '18 #2

P: 22
Ok thanks for the reply

Yes I want to start the numbering first day of each month of the year, the numbering for each record for each department starts over at 1 then increments by 1 (1,2,3,...) for each additional record that month with out duplicate.

The Table name is cashbook1 and it’s format is

Date, Pv no i.e the number field, Name of Beneficiacy and Amount paid

Form1 format is

Combo1 at the form header which contain the Department list that lookup in department table

Then payment command that open payment form that I will be entering the payment detail which is a query generated from Cashbook1. Thanks
Feb 8 '18 #3

Expert Mod 2.5K+
P: 3,205
My initial thought would be that whenever you create a new record, you search to see if any records exist for the current month. If so, then the current record would have an ID which increments the count of those records by one.

Relatively simple in concept, but without greater details, this is just theory.
Feb 8 '18 #4

Expert Mod 15k+
P: 31,419
Try this article (Item Numbering Within a Group). It deals with exactly the sort of thing you're after I believe.
Feb 9 '18 #5

Post your reply

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