跳到主要内容

如何在Excel中自动生成发票编号?

众所周知,发票号是连续的。 如果我们手动输入发票编号,我们可能会忘记上次使用的发票编号,而在Excel中会得到新发票的重叠编号。 在本文中,我将介绍两种在Excel中轻松自动生成发票编号的方法。


在Excel中添加自动发票编号生成器

1。 创建一个新的工作簿,或打开工作簿,您将自动添加发票编号。

2。 查找一个空白单元格,然后输入发票编号的起始编号。 在我们的例子中,在单元格D10000中输入2。

3。 通过按打开“ Microsoft Visual Basic for Applications”对话框。 其他 + F11 同时键,然后展开 VBAProject(当前工作簿),然后双击 的ThisWorkbook。 见左截图:
请注意: 在我们的例子中,我们双击 的ThisWorkbook 在下面 VBAProject(书1).

4。 将以下代码粘贴到打开的窗口中。

VBA:语音号码生成器

Private Sub Workbook_Open()
Range("D2").Value = Range("D2").Value + 1
End Sub

请注意: 更改 D2 到您在其中输入发票编号的起始编号的指定单元格中 .

5。 除了将整数作为发票编号之外,我们还可以使用以下公式来验证我们的发票编号:

没有 公式 发票编号
1 =“ CompanyName”&TEXT(TODAY(),“ yymmdd”)&D2 公司名称141209100000
2 =“ CompanyName”&TEXT(TODAY(),“ 0”)&D2 公司名称41982100000
3 =“ CompanyName”&TEXT(NOW(),“ MMDDHHMMSS”)&D2 公司名称1209095819100000
4 =“ CompanyName”&TEXT(NOW(),“ 0”)&D2 公司名称41982100000
5 =“ CompanyName”&RANDBETWEEN(100000,999999)&D2 公司名称448685100000
注意丝带 公式太难记了吗? 将公式另存为自动文本条目,以供日后再次使用!
阅读全文...     免费试用

:
(1)更改 D2 到您在上述公式中输入发票起始编号的单元格,然后更改 公司名 要显示在发票编号中的文本。
(2)在单元格中输入上述公式之一,您将自动获得发票编号,然后按 输入 键。

6。 保存当前工作簿:
在Excel 2013中,单击 文件 > 保存 (或 另存为)> 电脑> 浏览;
B.在Excel 2007和2010中,单击 文件 / 办公按钮 > 保存 (或 另存为).

7。 在即将出现的“另存为”对话框中,请执行以下操作:

(1)在 文件名 框;
(2)点击 保存类型 框并指定 Excel启用宏的工作簿(* .xlsm) 从下拉列表中;
(3)单击打开一个文件夹,您将在其中保存此工作簿;
(4)点击 保存 按钮。

 

从现在开始,每次打开“发票号生成器”工作簿时,发票号比上次打开工作簿时大1。 请注意,您必须在每次关闭之前保存工作簿。


使用KTE的插入序列号功能添加发票号

您可能会注意到,第一种方法要求您仅在指定的工作簿中获取发票编号。 更糟糕的是,一旦您忘记在关闭前保存指定的工作簿,发票号就会重叠。 但是随着 Kutools for Excel插入序列号 功能,无论您使用哪个工作簿,都可以插入唯一且连续的发票编号。

Kutools for Excel - 使用 300 多种基本工具增强 Excel 功能。 享受全功能 30 天免费试用,无需信用卡! 立即行动吧!

1。 选择您将获得发票编号的单元格,然后单击 库工具 > 插页 > 插入序列号.

2。 在“插入序列号”对话框中,单击 全新 按钮,然后在展开的序列号编辑区域中执行以下操作(请参见上面的屏幕截图):
(1)在 序列名称 框中输入新序列名称的名称,例如 发票号码.
(2)在 增量 框中输入 1;
(3)在 前缀(可选) 在方框中,输入您的公司名称或其他要求发票编号的文字;
(4)在 起始号码 框输入发票编号的起始编号,例如 10000 or 1;
(5)在 位数 框中,指定数字,例如 6;
(6)点击 地址 按钮。

3。 保持选择新创建的序列,然后单击 填充范围 按钮,然后单击 关闭 按钮。

无论您在哪个工作簿中应用此内容 插入序列号 功能,它将生成比上次应用此功能大1的发票编号。 点击了解更多有关此的信息 Kutools for Excel 的插入序列号功能

Kutools for Excel - 使用 300 多种基本工具增强 Excel 功能。 享受全功能 30 天免费试用,无需信用卡! 立即行动吧!


演示:使用KTE的插入序列号功能添加发票号


Kutools for Excel:超过 300 个方便的工具触手可及! 立即开始 30 天免费试用,没有任何功能限制。 立即下载!

在多个工作簿中插入唯一且连续的发票编号

大多数时候,我们只能通过公式或其他方法在一张纸或一张工作簿中插入连续的发票编号。 但是,随着强大 插入序列号 Kutools for Excel 的功能,您可以轻松地在多个工作簿中插入唯一且连续的发票号码。


广告插入序列发票编号

在Excel的列表中轻松查找并插入所有缺少的序列号(发票编号)

众所周知,发票号码通常是连续的。但有时一些发票号码可能会因错误而丢失。 Excel 的 Kutools 查找丢失的序列号 实用程序可以帮助您查找并插入所有缺失的发票号,并在遇到缺失的发票号时突出显示行或插入空白行。


广告发现缺少序列号2

最佳办公生产力工具

🤖 Kutools 人工智能助手:基于以下内容彻底改变数据分析: 智能执行   |  生成代码  |  创建自定义公式  |  分析数据并生成图表  |  调用 Kutools 函数...
热门特色: 查找、突出显示或识别重复项   |  删除空白行   |  合并列或单元格而不丢失数据   |   不使用公式进行四舍五入 ...
超级查询: 多条件VLookup    多值VLookup  |   跨多个工作表的 VLookup   |   模糊查询 ....
高级下拉列表: 快速创建下拉列表   |  依赖下拉列表   |  多选下拉列表 ....
列管理器: 添加特定数量的列  |  移动列  |  切换隐藏列的可见性状态  |  比较范围和列 ...
特色功能: 网格焦点   |  设计图   |   大方程式酒吧    工作簿和工作表管理器   |  资源库 (自动文本)   |  日期选择器   |  合并工作表   |  加密/解密单元格    按列表发送电子邮件   |  超级筛选   |   特殊过滤器 (过滤粗体/斜体/删除线...)...
前 15 个工具集12 文本 工具 (添加文本, 删除字符,...)   |   50+ 图表 类型 (甘特图,...)   |   40+ 实用 公式 (根据生日计算年龄,...)   |   19 插入 工具 (插入二维码, 从路径插入图片,...)   |   12 转化 工具 (小写金额转大写, 货币兑换,...)   |   7 合并与拆分 工具 (高级组合行, 分裂细胞,...)   |   ... 和更多

使用 Kutools for Excel 增强您的 Excel 技能,体验前所未有的效率。 Kutools for Excel 提供了 300 多种高级功能来提高生产力并节省时间。  单击此处获取您最需要的功能...

产品描述


Office Tab 为 Office 带来选项卡式界面,让您的工作更加轻松

  • 在Word,Excel,PowerPoint中启用选项卡式编辑和阅读,发布者,Access,Visio和Project。
  • 在同一窗口的新选项卡中而不是在新窗口中打开并创建多个文档。
  • 每天将您的工作效率提高50%,并减少数百次鼠标单击!
Comments (7)
No ratings yet. Be the first to rate!
This comment was minimized by the moderator on the site
I am a cleark in a school. In excel sheet student list is their. I cut the bill student wise via mail merge and give bill no manually so sometimes some bill no skipped. so I want a rule, when I skipped no give some instruction and stop. we use data validation, but its work only unique no or duplicate no. so please help us, Student name Bill no. Rahul 1 shyam 4 Atal Shivani 2 Ram Pratima 3 thank you.
This comment was minimized by the moderator on the site
How do I use this insert to auto generate the number without having to run it every time....Say, every time I open the Quote template it auto fills the cell that I inserted this number generator in?
This comment was minimized by the moderator on the site
Very helpful the automatic numbering of invoices. But how do i keep record of these invoices separately form my template ? I would appreciate your help. thanks L
This comment was minimized by the moderator on the site
jgljkasdf asjkfg asd asdf agh fajlsd fads ga df f fdadf afd adf
This comment was minimized by the moderator on the site
this is also useful for me, but i need some modification in that xxx/yy-yy/LAA XXX = number yy-yy = financial year LAA = Text Here Financial year from May-13 to April-14 So need as per Example: For Financial Year 2013-2014 001/13-14/LAA 002/13-14/LAA 003/13-14/LAA 004/13-14/LAA And for next Financial Year 2014-2015 001/14-15/LAA 002/14-15/LAA 003/14-15/LAA 004/14-15/LAA Thanks a lot. hadoop training in chennai | informatica training in chennai
This comment was minimized by the moderator on the site
The First formula uses the =IF(ISERROR( functions This has been available in all Excel versions. The Second formula uses the =IFERROR( Function Iferror was only introduced in Excel 2007 and hence cannot be used in older versions of Excel. Both formulas return the same result except that the second formula is more efficient. But unless you have many thousands of these cells with similar formulas you will not notice a speed difference. [url]VMware Training in Chennai[/url] | [url]Pega Training in Chennai[/url]
This comment was minimized by the moderator on the site
I need your help. I tried data validation for description column. But the values are wrong. If I click on the coats category, description should display all the items under the coats category but its displaying the other categories description too. Kindly help me in the formula to display the respective descriptions for the category chosen. How to activate the other buttons like filter, create invoice, clear data etc? There is no video for that. Kindly help me. I am trying this program since I wanna create a program using all these options. http://www.traininginsholinganallur.in/dot-net-training-in-chennai.html
There are no comments posted here yet
Please leave your comments in English
Posting as Guest
×
Rate this post:
0   Characters
Suggested Locations