dymosoftware / DCD-SDK-Sample

DYMO Connect SDK Samples
Other
60 stars 26 forks source link

Safari rendering label failed #52

Open LowKeeBit opened 2 years ago

LowKeeBit commented 2 years ago

I encountered an issue with the JS-Lib.

I wasn't able to preview nor print labels, that have been freshly created with demo connect (v.1.4.3.103).

If you like to preview my label the following error occurs: Error: The 'Rows' start tag on line 1 position 2256 does not match the end tag of 'Color'. Line 1, position 2264.

Upon further investigation of demo.connect.framework.full.js there has been a 'fix' to replace all tags with tags using this regex: '/<Color (.+)\/>/g'. This will cause an issue replace EVERYTHING after the Color name. Use something like this to replace empty tags without crushing the whole xml: '/<Color ((?!\/Color).)*\/>/g'

the labelxml: <?xml version="1.0" encoding="utf-8"?>

DYMO Label Landscape LargeAddressS0722400 0 SolidLine 0.2233333 0.06 3.203333 1.306666 1 False ClearObjects Surname Rotation0 1 False SolidLine Center Middle AlwaysFit False AlwaysFit Center Middle False Surname Helvetica 29.6 False False False 0.2325 0.3783335 3.079585 0.6533331 Blank
dymosoftware commented 2 years ago

DCD will provide the fixed version on next release. However you can comment out the code, and the xml file will need to have those closure tag along with like that.