Oct 072011
 

A new version of DYMO Label Framework JavaScript library is available.

This version adds support for Opera 11.51 on Mac and Windows.

The js script file is available from http://labelwriter.com/software/dls/sdk/js/DYMO.Label.Framework.1.2.4.js.

The http://labelwriter.com/software/dls/sdk/js/DYMO.Label.Framework.latest.js has been updated to version 1.2.4 as well.

  28 Responses to “DYMO Label Framework JavaScript Library 1.2.4”

  1. Can you provide a secure link to the javascript framework? I link to the lastest version (http://labelwriter.com/software/dls/sdk/js/DYMO.Label.Framework.latest.js) in a secure area and i get a mixed content warning. I know i can just download it and link to my server, but i would rather link to a CDN so that i don’t need to continually update the version on my server.

    • Sorry, we don’t provide https hosting. Also, I would discourage you from usage the .latest version and load it from labelwriter.com as well. We are doing a lot of testing before we publish the next release, but it still might be undiscovered bugs can break your application. It will be much safer for you to manually grab the new version, test your app with it and then use it on production. Also, our hosting server, labelwriter.com, is not 100% fault tolerant. If you host the js on your site, you don’t have an external dependency.

  2. I’m having trouble getting the SDK to work in Chrome. It works in Firefox and IE on the same computer, but when I try Chrome, I get two messages: one that no DYMO printers are installed and the second one says I don’t have the framework installed.

    • Figured it out. Although I was restarting Chrome, it was leaving a process open in the background. Once I got all processes closed and restarted Chrome, it worked. Now down to developing!

  3. I have an issue with creating a carriage return. I’m using .net and in the code behind page I generate the text that will be used to print the label. to get a carriage return i use Environment.NewLine. This works in most situations, but sometimes the newline is just ignored. i haven’t been able to figure out why. is anyone aware of this issue? is there a better way to do a carriage return? when i use n, the characters “n” are printed instead of a carriage return.

    • Could you provide the code you are using?

      Any line end combinations should work, ‘n’, ‘r’, or ‘rn’. Here is the sample

      label.SetObjectText(“Address”, “DYMOn828 San Pablo AvenAlbany CA 94706”);
      label.Print(“DYMO LabelWriter 450 Turbo”);
      

      Three lines will be printed:

      DYMO
      828 San Pablo Ave
      Albany CA 94706

      • i have an aspx page that dynamically generates text for a receipt. i store that text in a hidden field. then when the print receipt button is selected, i call the javascript function that sends the information to the dymo printer (LabelWriter 450 Turbo). in the aspx code page i use environment.newline for a carriage return (which according to microsoft’s site should just convert to “rn”).

        The javascript code I am using is:

        var label = dymo.label.framework.openLabelXml(getLabelTemplate());
        var labelSet = new dymo.label.framework.LabelSetBuilder();
        var record = labelSet.addRecord();

        record.setTextMarkup(‘TEXT’, ‘text here’);

        var printers = dymo.label.framework.getPrinters();

        if (printers.length == 0)
        throw “No DYMO printers are installed. Install DYMO printers.”;

        var printerName = “”;
        for (var j = 0; j < printers.length; ++j) {
        var printer = printers[j];
        if (printer.printerType == "LabelWriterPrinter") {
        printerName = printer.name;
        break;
        }
        }

        label.print(printerName, null, labelSet.toString());

        After more testing i discovered that the problem seems to be related to when i use "” to change the font size. when i use these tags back to back (two paragraphs that need different font sizes), the problem occurs. if i remove one set of font tags, then the problem goes away.

  4. I can’t seem to find any documentation on this so I apologize for a newbie-ness that follows.

    I have a web app (LAMP/AJAX driven) for our company that tracks boxes of product for internal use. I have a page where I add a box to a category. That box gets a unique ID. I would like to print a barcode label for a box where the barcode is the unique ID. I currently have a PHP script that takes the number and creates a JPG of a barcode based on any number that you give it. i was hoping to be able to use this to generate an image that would be put onto a label for printing.

    I know how to pull the ID from the database and display it, store it, do whatever with it. But I don’t know how to get the image into the Dymo javascript library. I’m new to this library. Allmost all of the examples are all about displaying/formatting text. I think I could handle sending the script some text. But the parameters for sending it an image are a mystery to me. Unless the script can take a number and dynamically generate the barcode image all by itself…

    Thanks in advance.

  5. Is there not a website or page that has up to date information on the JavaScript API and usage information?

  6. There’s a small bug between the Mac and Windows implementation. I have a template file with an Image placeholder, but I deleted the image data between the image tags in the XML file so as not to take up space for an image that may or may not be set with setBase64Image(). On Mac this is no problem. On windows it complains that the template file could not be loaded. The solution is to insert a 1 x1 pixel transparent image as a place holder. It won’t show if printed and can be replaced with setBase64Image when a real image is needed.

  7. What’s the best way to insert an image from a website? Here’s my example linking to the Google logo. When I print it out it just shows blank. Am I missing something?

    Landscape
    Address
    30252 Address

    Image

    Rotation0
    False
    False
    http://www.google.com/intl/en_ALL/images/logo.gif
    Uniform
    0

    Left
    Top

  8. Hi there,

    What would cause labels to print out like this?

    All my other customers have been able to print fine using the same software. Could it be the type of label they’re using?

    Thanks

    Ben

  9. Hi guys,

    I’m experiencing some Dymo printer detection with Windows 8 (and FF16 but work on W7/FF16)
    Do anyone get printer detection problems since migrating to W8 ?

    Many Thanks !

Leave a Reply to Jeremy H. Cancel reply

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

(required)

(required)