+ Reply to Thread
Results 1 to 4 of 4

Auto Serial Number

  1. #1
    Forum Contributor
    Join Date
    04-18-2014
    Location
    Pune, India
    MS-Off Ver
    Excel 2021
    Posts
    121

    Auto Serial Number

    Dear Sir,

    i have the formula for auto serial number with auto insert row.

    i m getting problem when i click on insert new row button serial number getting changes.

    please help me, and see the below formula and code for the same.

    IF(COUNTA(C4:O4)>0,"01"&ROW(B4)-2,"")

    Please Login or Register  to view this content.
    Attached Files Attached Files
    Last edited by Fotis1991; 04-23-2014 at 02:30 AM. Reason: pls use code tags for your codes!

  2. #2
    Forum Expert
    Join Date
    04-22-2013
    Location
    .
    MS-Off Ver
    .
    Posts
    4,418

    Re: Auto Serial Number

    Try changing your macro to:
    Please Login or Register  to view this content.

  3. #3
    Forum Contributor
    Join Date
    04-18-2014
    Location
    Pune, India
    MS-Off Ver
    Excel 2021
    Posts
    121

    Re: Auto Serial Number

    Dear Sir,

    thank you for your quick reply, but column P and column Q formula not updating!!!!

    Private Sub Worksheet_Change(ByVal Target As Range)
    Dim O As Range
    Set O = Range("O:O")
    If Intersect(Target, O) Is Nothing Then Exit Sub
    Application.EnableEvents = False
    roow = Target.Row
    Cells(roow + 1, 1).Value = Cells(roow, 1).Value + 1
    Cells(roow + 1, 2).Select
    Rows(Target.Row + 2).Insert
    Application.EnableEvents = True
    End Sub
    Attached Files Attached Files

  4. #4
    Forum Expert
    Join Date
    04-22-2013
    Location
    .
    MS-Off Ver
    .
    Posts
    4,418

    Re: Auto Serial Number

    Sorry, this looks like a different problem to what you had in the first post - could you explain what is supposed to happen with the new workbook?

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Auto Serial Number Using VBA
    By LoveCandle in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-21-2022, 09:24 PM
  2. Shortcyt key for auto serial number
    By dingdang in forum Excel General
    Replies: 1
    Last Post: 07-16-2013, 02:17 AM
  3. VBA to Get Auto Serial Number As Per Defined Pattern
    By Rajeshkumar R in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 12-24-2012, 08:46 AM
  4. [SOLVED] Unable to make a auto serial number column.
    By Jeetu_pa84 in forum Excel General
    Replies: 3
    Last Post: 05-22-2012, 06:11 AM
  5. Auto Fill the serial Number
    By anwitha in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 10-23-2010, 02:11 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1