如何自动增加标签中的值,该值在添加新记录时递增 [英] how to auto increament a value in a label which increment when a new record added

查看:112
本文介绍了如何自动增加标签中的值,该值在添加新记录时递增的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我只想要如何自动增加标签中的值,当一个新记录添加到数据库中时,会增加数据绑定在vb.net中



i希望此模式为发票号码= NEU-001-dd / mm / yy



请尽快帮我解决这个问题谢谢等待你的答案

i just want how to auto increament a value in a label which increment when a new record added to databas eusing databinding in vb.net

i want this pattern as invoice number=NEU-001-dd/mm/yy

please help me on this code soon thanks waiting for your answers

推荐答案

我认为你需要在每次插入数据库后编辑标签的文本,

创建一个变量并在每次插入完成后递增它ex:int inc;

并在标签中放置label1.Text = NEU-inc(整数)-dd / mm / yy
i think you need to edit the text of the label after every insert in database,
Create a variable and increment it after each insert done ex: int inc;
and in the label put label1.Text = NEU-inc(the integer)-dd/mm/yy


这篇关于如何自动增加标签中的值,该值在添加新记录时递增的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆