Dymo címkenyomtató 400-as hibaüzenet

Dymo címkenyomtató 400-as hibaüzenet
2017-06-12T15:16:44+02:00
2017-06-13T10:49:25+02:00
2022-12-04T15:10:38+01:00
almarem
Hello!

Böngészőből szeretnék nyomtatni egy dymo labalwriter 450-re. A developers.dymo.com -ról elérhető test oldalról tudok nyomtatni. Viszont wamp64-en és a szerveren sem megy. Hibaüzenet: Failed to execute webservice command: 400: Bad Request. Az alábbi kód az XML tartalmát leszámítva dymo oldaláról van.

(function() { // called when the document completly loaded function onload() { //var textTextArea1 = document.getElementById('textTextArea1'); //var textTextArea2 = document.getElementById('textTextArea2'); var printButton = document.getElementById('printButton'); // prints the label printButton.onclick = function() { //alert('ddsa'); try { var labelXml = '<?xml version="1.0" encoding="utf-8"?>\ <DieCutLabel Version="8.0" Units="twips">\ <PaperOrientation>Landscape</PaperOrientation>\ <Id>Address</Id>\ <PaperName>30252 Address</PaperName>\ <DrawCommands/>\ <ObjectInfo>\ <TextObject>\ <Name>ValamiText</Name>\ <ForeColor Alpha="255" Red="0" Green="0" Blue="0" />\ <BackColor Alpha="0" Red="255" Green="255" Blue="255" />\ <LinkedObjectName></LinkedObjectName>\ <Rotation>Rotation0</Rotation>\ <IsMirrored>False</IsMirrored>\ <IsVariable>False</IsVariable>\ <HorizontalAlignment>Left</HorizontalAlignment>\ <VerticalAlignment>Top</VerticalAlignment>\ <TextFitMode>AlwaysFit</TextFitMode>\ <UseFullFontHeight>False</UseFullFontHeight>\ <Verticalized>False</Verticalized>\ <StyledText>\ <Element>\ <String>Valami</String>\ <Attributes>\ <Font Family="Arial" Size="12" Bold="False" Italic="False" Underline="False" Strikeout="False" />\ <ForeColor Alpha="255" Red="0" Green="0" Blue="0" />\ </Attributes>\ </Element>\ </StyledText>\ </TextObject>\ <Bounds X="332" Y="150" Width="4455" Height="1260" />\ </ObjectInfo>\ </DieCutLabel>'; var label = dymo.label.framework.openLabelXml(labelXml); // create label set to print data var labelSetBuilder = new dymo.label.framework.LabelSetBuilder(); var printers = dymo.label.framework.getPrinters(); if (printers.length == 0) throw "No DYMO printers are installed. Install DYMO printers."; var printerName = ""; for (var i = 0; i < printers.length; ++i) { var printer = printers[i]; if (printer.printerType == "LabelWriterPrinter") { printerName = printer.name; break; } } if (printerName == "") throw "No LabelWriter printers found. Install LabelWriter printer"; // finally print the label with default print params label.print(printerName, "", labelSetBuilder); } catch(e) { alert(e.message || e); } }; } function initTests() { if(dymo.label.framework.init) { dymo.label.framework.trace = true; dymo.label.framework.init(onload); } else { onload(); } } // register onload event if (window.addEventListener) window.addEventListener("load", initTests, false); else if (window.attachEvent) window.attachEvent("onload", initTests); else window.onload = initTests; } ());
 A segítséget előre is köszi

Mutasd a teljes hozzászólást!

Tetszett amit olvastál? Szeretnél a jövőben is értesülni a hasonló érdekességekről?
abcd