You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Windows10/11下Dymo 450/550打印机初始化报错求助

Dymo 450/550打印机初始化报错:找不到PrintingSupportLibrary.dll入口点及NullReferenceException解决

问题详情

在Windows 10/11系统中使用Dymo 450/550标签打印机时,初始化打印机类出现以下错误:

EntryPointNotFoundException: Kan ingangspunt met de naam SpoolMon_AddListener niet vinden in DLL PrintingSupportLibrary.dll.
(荷兰语译文:无法在DLL PrintingSupportLibrary.dll中找到名为SpoolMon_AddListener的入口点)

调用栈:

DymoSDK.dll!DymoSDK.Implementations.DymoPrinter.GetPrinters()   Unknown
VoorraadBeheer.exe!VoorraadBeheer.Classes.DymoPrinters.Initialize() Line 22 C#
VoorraadBeheer.exe!VoorraadBeheer.DymoBarcodePrinter.DymoBarcodePrinter_Load(object sender, System.EventArgs e) Line 51 C#

调试时执行DymoSDK.App.Init();还抛出:

Exception thrown: 'System.NullReferenceException' in DYMO.LabelAPI.PlatformSpecific.dll

出错类代码:

using DymoSDK.Implementations;
using DymoSDK.Interfaces;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace VoorraadBeheer.Classes
{
    public class DymoPrinters
    {
        public List<IPrinter> DymoPrinterList;

        private IDymoPrinter tmpIDymoPrinter;
        private IDymoLabel tmpIDymoLabel;
        public void Initialize()
        {
            DymoSDK.App.Init();
            tmpIDymoPrinter = DymoPrinter.Instance;
            tmpIDymoLabel = DymoLabel.Instance;
            DymoPrinterList = tmpIDymoPrinter.GetPrinters().Result.ToList();// ERROR here
        }

        public string LoadLabelXml(string LabelPath)
        {
            tmpIDymoLabel.LoadLabelFromFilePath(LabelPath);
            return tmpIDymoLabel.XMLContent;
        }

        public IDymoLabel MakeLabelFromXml(string LabelXml)
        {
            tmpIDymoLabel.LoadLabelFromXML(LabelXml);
            return tmpIDymoLabel;
        }
        public bool PrintLabel(IDymoLabel label, string PrinterName, int amount = 1)
        {
            return tmpIDymoPrinter.PrintLabel(label, PrinterName, amount).Result;
        }
    }
}

已尝试启用/禁用引用,问题未解决。


解决方案

1. 匹配SDK与驱动版本

卸载现有Dymo SDK和打印机驱动,从官方渠道下载适配Windows 10/11的最新版本驱动+SDK包,按顺序安装驱动、SDK,确保版本完全兼容。旧版SDK无法适配新系统的PrintingSupportLibrary.dll结构,是常见触发原因。

2. 修复PrintingSupportLibrary.dll文件

  • 检查系统对应目录(32位程序看C:\Windows\SysWOW64,64位看C:\Windows\System32)是否存在该文件,缺失则从SDK安装包中提取对应版本复制到目录。
  • 打开管理员命令提示符,注册该DLL:
    regsvr32 "C:\Windows\System32\PrintingSupportLibrary.dll"
    
    (32位程序替换为SysWOW64路径)

3. 修正异步方法调用逻辑

代码中直接用.Result阻塞获取异步结果,易引发死锁或异常,改为异步调用模式:

public async Task InitializeAsync()
{
    DymoSDK.App.Init();
    tmpIDymoPrinter = DymoPrinter.Instance;
    tmpIDymoLabel = DymoLabel.Instance;
    DymoPrinterList = (await tmpIDymoPrinter.GetPrinters()).ToList();
}

调用处改为await InitializeAsync();,避免同步阻塞问题。

4. 统一程序平台目标

确保项目的平台目标(x86/x64/Any CPU)与安装的Dymo SDK位数一致。比如SDK是32位,项目必须设为x86,否则会加载错误版本的DLL。

5. 重新管理SDK引用

移除项目中所有Dymo相关引用,手动从SDK安装目录(通常为C:\Program Files (x86)\DYMO\DYMO Label Framework\SDK\DotNet\)添加对应版本的DLL引用,并将引用的「复制本地」属性设为True。


内容的提问来源于stack exchange,提问作者rinaldo Visscher

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.06.29 08:13:20