How to Create Auto Numbering in Ms Access that Automatically Reset every year or every month.

  Рет қаралды 11,817

Edcelle John Gulfan

Edcelle John Gulfan

Күн бұрын

Пікірлер: 53
@iammai5404
@iammai5404 Жыл бұрын
Great tutorial, very helpful and very clever.
@EdcelleJohnGulfan
@EdcelleJohnGulfan Жыл бұрын
Thanks for watching
@DonRamonLoco
@DonRamonLoco 2 жыл бұрын
Excellent!!! Keep going! And thank you for this video. Very helpful for me!!
@EdcelleJohnGulfan
@EdcelleJohnGulfan 2 жыл бұрын
Thanks Don.
@56cridwan
@56cridwan 11 ай бұрын
thanks for the video, very helpful
@EdcelleJohnGulfan
@EdcelleJohnGulfan 11 ай бұрын
Thanks for watching
@bck4589
@bck4589 2 жыл бұрын
Thank you sir,❤️ from India
@EdcelleJohnGulfan
@EdcelleJohnGulfan 2 жыл бұрын
Welcome
@boodygarcia5874
@boodygarcia5874 2 жыл бұрын
Thank you you Sir Edcelle!
@EdcelleJohnGulfan
@EdcelleJohnGulfan 2 жыл бұрын
Welcome and thanks for watching Boody
@sheikhobaba
@sheikhobaba Жыл бұрын
Great
@patriknemec6253
@patriknemec6253 10 ай бұрын
Hi Mr Gulfan, what is VBA Code when I delete last invoice and then create new with the same number. For example I delete invoice 2023002 and then create new with number 2023002. 🙏
@EdcelleJohnGulfan
@EdcelleJohnGulfan 10 ай бұрын
Why not delete only the records inside that invoice?
@japmanumbali8001
@japmanumbali8001 2 жыл бұрын
How to create invoicenumber and seriesnumber in to 4 digits like 0001. Thanks
@EdcelleJohnGulfan
@EdcelleJohnGulfan 2 жыл бұрын
Try this. kzbin.info/www/bejne/q6mbeqGagtp0bK8
@bajront66
@bajront66 Жыл бұрын
Greetings. Sir, you explained this really professionally, but I can't do what I need and that's why I need your help. Namely, the Invoice number must be reset annually, but it should contain the first and last letter of the month, then the Invoice number and at the end the year, for example: JY-1/2021, JY-2/2021; FY-3/2021, FY-4/2021, FY-5/2021; MH-6/2021 etc. JY-1/2022, JY-2/2022; FY-3/2022... Can you help me with this please?
@EdcelleJohnGulfan
@EdcelleJohnGulfan Жыл бұрын
Actually same procedure but you have to add the LEFT and RIGHT FUNCTION. It's a complex process so i will create a video about this soon.
@naughtynaughty6453
@naughtynaughty6453 2 жыл бұрын
Hi Sir, I am currently working on a project similar to this, it's just that I'm using ms excel as my front-end and ms access as the back-end. My challenge is that there are multiple users simultaneously creating record/tickets. Do you have any suggestions how it can be implemented? Thank you.
@EdcelleJohnGulfan
@EdcelleJohnGulfan 2 жыл бұрын
Multiple-user at the same time in excel is not doable. Either you work in a Read Only Mode or the one who can save record is the last user. Why not use Access instead of excel?
@naughtynaughty6453
@naughtynaughty6453 2 жыл бұрын
@@EdcelleJohnGulfan I am not used to in ms access forms...all my previous projects are in excel - access set up since it is much more like the old VB6.0 and ms access tandem. I was able to create something but it's a hit and miss. I have 4 users creating tickets simultaneously. We are all trying to click the command button at the same time and after a couple of attempts (5 to 6 entries each users) one would encounter an error with the database connection which I couldn't properly troubleshoot...To give you a background the functions invoked when the command button is clicked: 1.) It will make a query to retrieve the max id (auto_number primary key) and the max series (indexed - no duplicate) and store them in variables: max_id and max_series 2.) It will insert a record just to create an initial entry to the table in the database and to determine the order of the auto_number generated. This is my work-around for the multi-user simultaneously creating record. 3.) It will query the last record created and then compare it to the max id. Ex. the max_id is 10 and the last id stored in step 2 is 14 then it means I'll be needing to add 4 in my step 4 to generate the ticket number based on the max_series. 4.) Update the series by adding the difference of the last id stored and the max id to the max_series... Not sure if I explained it clearly. But like I said it's a hit and miss. I know it's not the best approach and I'm still trying to make a work around and hopefully I sort it out.
@toutypasse44000
@toutypasse44000 2 жыл бұрын
salut je suis content de la solution
@EdcelleJohnGulfan
@EdcelleJohnGulfan 2 жыл бұрын
Thanks for watching.
@amrelnaggar4509
@amrelnaggar4509 2 жыл бұрын
I need your help, if I have a table with data entry form. This table contains fields (Order date, Total cost, first payment, second payment, Rest and paid date). Rest= Total cost - first payment - second payment. what I need is to have the paid date (now date when the order is paid) filled automatically under only two conditions, when the Total cost > 0 and Rest =0 (which means that the order is paid). Also how to prevent order modification after it is paid. Would you help me with that , please.
@seshadrisrikant
@seshadrisrikant 2 жыл бұрын
When i am running the form for the new year its showing invalid use of null (Error 94) . How to solve this
@EdcelleJohnGulfan
@EdcelleJohnGulfan 2 жыл бұрын
If That's the error, you are using or referring the null or empty field. To fixed it. Put NZ FUNCTION to the code that has an error.
@Raffaely1021
@Raffaely1021 Жыл бұрын
hello, I tried this but unfortunately it stops at 10...error after 10 input datas...may I ask why? Can you please check the vba, Thank you
@EdcelleJohnGulfan
@EdcelleJohnGulfan 6 ай бұрын
I have mistake in my coding. 1:14 series number, the data type must be Number not a short text.
@patriknemec6253
@patriknemec6253 Жыл бұрын
Hi Mr Gulfan, I would like to set my invoice number like 2023001, …and I do not know hot to set three numbers at the end of invoice number. Now I have 20231,…numbering. I have tried your another video. But it does not work. Please help. 🙏🙏 Many thanks.
@EdcelleJohnGulfan
@EdcelleJohnGulfan Жыл бұрын
Have you seen this video? kzbin.info/www/bejne/q6mbeqGagtp0bK8si=thKrnyQWNLVynxwu Well, if not, watch the video and apply this format. sample: Me.Invoice_Number= Format(Date, "yyyy") & Format(Your_autonumber, "000")
@murealnoauy
@murealnoauy 8 ай бұрын
From the example you did, it was very good. But I would like to add the ID number to 0001, 0002. What should I do? 2023-04-1 to 2023-04-0001 2023-04-2 to 2023-04-0002 2022-01-1 to 2022-01-0001
@TheOrangeGecko
@TheOrangeGecko 7 ай бұрын
Change the line "Me.SeriesNumber = InvNext" to Me.SeriesNumber = Format(InvNext, "0000")
@admiralrichvi
@admiralrichvi 2 жыл бұрын
How to make it reset each fiscal year ?
@EdcelleJohnGulfan
@EdcelleJohnGulfan 2 жыл бұрын
Hi thanks for asking. Same procedure but you need to set up first your fiscal date as your variable (September + Year)
@admiralrichvi
@admiralrichvi Жыл бұрын
If you going to use max ID for the series number, how to rest the numbering for the new fiscal? I have 101-2023, combined series with year.@@EdcelleJohnGulfan
@moyal3455
@moyal3455 2 жыл бұрын
This method does not work when records go above 10. System error that value has been duplicated.
@EdcelleJohnGulfan
@EdcelleJohnGulfan 2 жыл бұрын
Thanks for the info but im using this since 2013 and i don't have problem. You can avoid the duplicate values if you combine the year+month+series number.
@moyal3455
@moyal3455 2 жыл бұрын
@@EdcelleJohnGulfan This actually resolved the error: vlast = DMax("Val([SeriesNumber])", "invoice", "InvYear='" & Me!invyear.Value & "'").
@admiralrichvi
@admiralrichvi 2 жыл бұрын
This happening to me as well
@MaraingMuong168
@MaraingMuong168 2 жыл бұрын
@@moyal3455 Thank you very much thank you
@NoumanAzam01
@NoumanAzam01 2 жыл бұрын
@@moyal3455 So great of u Moya L
@kidsworld7459
@kidsworld7459 Жыл бұрын
Hi sir, I want to create unique index number for customers. I want to get first letter of Coustomer name with number such as A001, A002, B001, C001, C002 etc. Please help me.
@elvesreis2235
@elvesreis2235 2 жыл бұрын
I tried this but it does not increment :Private Sub Form_BeforeInsert(Cancel As Integer) Dim Vlast As Variant Dim InvNext As Integer Me.Invyear = Format(Date, " YYYY ") & "-" & Format(Date, "mm") Vlast = DMax("SeriesNumber", "Invoice ", " InvYear =' " & Me.Invyear.Value & "'") If IsNull(Vlast) Then InvNext = 1 Else InvNext = Vlast + 1 End If Me.SeriesNumber = InvNext End Sub
@EdcelleJohnGulfan
@EdcelleJohnGulfan 2 жыл бұрын
Send me your file and I'll to check.
@kiranarana7274
@kiranarana7274 2 жыл бұрын
Please help I get aan Syntax error (missing operator) in query expression InvYear=*2023* Private Sub Form_BeforeInsert(Cancel As Integer) Dim vLast As Variant Dim InvNext As Integer Me.InvYear = Format(Date, "YYYY") vLast = DMax("SeriesNumber", "Invoice", "InvYear=*" & Me.InvYear.Value & "*") If IsNull(vLast) Then InvNext = 1 Else InvNext = vLast + 1 End If Me.SeriesNumber = InvNext End Sub
@yasirkhan-mw1zr
@yasirkhan-mw1zr Жыл бұрын
Me.InvYear = Format(Date, "YYYY") vLast = DMax("SeriesNumber", "Invoice", "InvYear='" & Me.InvYear.Value & "'")
@Stache987
@Stache987 2 жыл бұрын
Auto numbers used for keys are NOT for you, no need to reset them, it only opens up corruption
@EdcelleJohnGulfan
@EdcelleJohnGulfan 2 жыл бұрын
YES I ABSOLUTELY UNDERSTAND. Let's say... You have a database under testing and after you finalize it, client wants to start from 0, what will you do?
@EdcelleJohnGulfan
@EdcelleJohnGulfan 2 жыл бұрын
But this method is resetting the numbering variables and not the auto numbers.
@patriknemec6253
@patriknemec6253 10 ай бұрын
⁠​​⁠@EdcelleJohnGulfan because it is made for wrong customer.
@Raffaely1021
@Raffaely1021 Жыл бұрын
hello, I tried this but unfortunately it stops at 10...error after 10 input datas...may I ask why? Can you please check the vba, Thank you
@Raffaely1021
@Raffaely1021 Жыл бұрын
I wish to create a field that shows, mm-"9999"-yyyy, the "9999" is the unique ID autonumber, please help thank you!
@EdcelleJohnGulfan
@EdcelleJohnGulfan 6 ай бұрын
I have mistake in my coding. 1:14 series number, the data type must be Number not a short text.
How to Create AUTO BACKUP in Microsoft Access
11:10
Edcelle John Gulfan
Рет қаралды 11 М.
5 Ways to PROTECT Ms Access Database
9:36
Edcelle John Gulfan
Рет қаралды 15 М.
Chain Game Strong ⛓️
00:21
Anwar Jibawi
Рет қаралды 41 МЛН
Арыстанның айқасы, Тәуіржанның шайқасы!
25:51
QosLike / ҚосЛайк / Косылайық
Рет қаралды 700 М.
Cat mode and a glass of water #family #humor #fun
00:22
Kotiki_Z
Рет қаралды 42 МЛН
99.9% IMPOSSIBLE
00:24
STORROR
Рет қаралды 31 МЛН
Create a Database Launcher that Opens Other Microsoft Access Databases
14:34
Computer Learning Zone
Рет қаралды 6 М.
Search & Autofill | Microsoft Access Tips
16:49
LoopLearnings
Рет қаралды 2,2 М.
How to Manually Enter Values into an Autonumber Field in MS Access
12:27
Sean MacKenzie Data Engineering
Рет қаралды 9 М.
Customize Auto Numbering in Ms Access
15:07
Edcelle John Gulfan
Рет қаралды 1,3 М.
Microsoft Access - Customizable Autonumbering Field
28:50
Design and Deploy
Рет қаралды 31 М.
Auto numbering in ms access
13:09
Ag tech
Рет қаралды 1,9 М.
How to Filter the Data in a Combo Box or List Box as you Type in Microsoft Access
22:53
SEARCHING WHILE TYPING | Multi Field Search Form in Ms Access
17:07
Edcelle John Gulfan
Рет қаралды 41 М.
Chain Game Strong ⛓️
00:21
Anwar Jibawi
Рет қаралды 41 МЛН