打开APP
userphoto
未登录

开通VIP,畅享免费电子书等14项超值服

开通VIP
条形码生成方案

1、在要生成条形码的页面中增加Literal作为条形码的载体

2、在后台cs页面中增加方法,code即为要打印的编码

private void FillBarCode(string code)

    {

        IOrgSysParameter orgSysParameter OrgSysParameterManageFactory.Create();

        string ifVisibleBarCode, strBarCodeHeight, strBarCodeWidth;

        int barCodeHeight, barCodeWidth;

        orgSysParameter.GetIfVisibleBarCode(this.curUserRow.ORGID, out ifVisibleBarCode);

        if (ifVisibleBarCode == IfVisibleBarCode.A.ToString())

        {

            orgSysParameter.GetBarCodeHeight(this.curUserRow.ORGID, out strBarCodeHeight);

            orgSysParameter.GetBarCodeWidth(this.curUserRow.ORGID, out strBarCodeWidth);

 

            barCodeHeight int.Parse(strBarCodeHeight);

            barCodeWidth int.Parse(strBarCodeWidth);

            this.Literal1.Text BarCodeToHTML.get39(code, barCodeWidth, barCodeHeight);

            this.Literal2.Text BarCodeToHTML.get39(code, barCodeWidth, barCodeHeight);

            this.Literal3.Text BarCodeToHTML.get39(code, barCodeWidth, barCodeHeight);

        }

}

 

3、在窗体的Page_Load事件中获取到code值之后使用该方法

this.FillBarCode(code);

通过以上3步即可以实现条形码的生成

本站仅提供存储服务,所有内容均由用户发布,如发现有害或侵权内容,请点击举报
打开APP,阅读全文并永久保存 查看更多类似文章
猜你喜欢
类似文章
【热】打开小程序,算一算2024你的财运
怎样用iText导出条形码图片_天津-条形码-条形码制作-条码-条码打印机-条码碳带-条码...
创意无限,众多美图
你会看条形码吗*
条形码
有趣的条形码
这些宝贝最受女性欢迎,只因 || 条 || 形 || 码 || 太过惊艳!
更多类似文章 >>
生活服务
热点新闻
分享 收藏 导长图 关注 下载文章
绑定账号成功
后续可登录账号畅享VIP特权!
如果VIP功能使用有故障,
可点击这里联系客服!

联系客服