का उपयोग करके प्रिंट करने में असमर्थ मेरे पास एक ईपीएसॉन टीएम-यू 220 ए है, मैं रसीद प्रिंट करने के लिए लिख रहा हूं और सी # डेस्कटॉप एप्लिकेशन हूं। लेकिन यह प्रिंटर खोजने में असमर्थ है।ईपीएसन प्वाइंट ऑफ़ सेल प्रिंटर - सी #
प्रिंटर अजीब पात्रों अगर मैं नोटपैड के माध्यम से कुछ भेजने (इस तरह अपनी काम कर रहे)
मैं निम्नलिखित: नेट के लिए
- पीओएस v1.12.exe
- OPOSN1.11.16 (.net के लिए एस्पेन रैपर)
- एस्पेन ड्राइवर
- प्रिंटर पर यूएसबी इंटरफ़ेस स्थापित किया गया।
कोड:
private void FormLoad(object sender, System.EventArgs e)
{
//<<<step1>>>--Start
//Use a Logical Device Name which has been set on the SetupPOS.
string strLogicalName = "PosPrinter";
// string strLogicalName = "ESDPRT001";
try
{
//Create PosExplorer
PosExplorer posExplorer = new PosExplorer();
DeviceInfo deviceInfo = null;
try
{
deviceInfo = posExplorer.GetDevice(DeviceType.PosPrinter, strLogicalName);
m_Printer = (PosPrinter)posExplorer.CreateInstance(deviceInfo);
}
catch (Exception)
{
ChangeButtonStatus();
return;
}
//Open the device
m_Printer.Open();
//Get the exclusive control right for the opened device.
//Then the device is disable from other application.
m_Printer.Claim(1000);
//Enable the device.
m_Printer.DeviceEnabled = true;
}
catch (PosControlException)
{
ChangeButtonStatus();
}
//<<<step1>>>--End
}
त्रुटि: बंदरगाह नाम अवैध है, या डिवाइस से कनेक्ट नहीं हो सका। लाइन पर: m_Printer.Claim (1000);
क्या आपको पता है अपवाद पर फेंक दिया जाता है लाइन की जांच करें? – ZombieSheep
त्रुटि: पोर्ट नाम अवैध है, या डिवाइस से कनेक्ट नहीं किया जा सका। लाइन पर: m_Printer.Claim (1000); –
कौन सा ड्रॉफ़ीयर आप ओपोस या विंडोज ड्राइवर का उपयोग कर रहे हैं? – TutuGeorge