3 Replies Latest reply on Jun 29, 2016 11:20 AM by Billie Hecox

    Datawedge API / Reading out Datawedge profile programmatically

    Marian Moron

      Just a quick question to the userbase:


      We are currently relying on the EMDK (for Android v3.1) barcode scanning component for scanning barcodes in one of the applications that we're developing.


      Because the EMDK profile manager has no settings interface available to the end-user (or at least not one that we know of!), we are currently considering two options:

      either switch entirely to using Datawedge’s barcode scan functionality or (preferably) at least be able to read out the DataWedge profile so that we can use those settings to alter the EMDK-based scan settings on-the-fly.


      1. Is there a currently supported or unsupported way of reading out a Datawedge profile programmatically?

      2a. If we were to have to follow an unsupported route... are the profile settings stored in a physical file for which we could eventually write our own parser/importer for reading out the settings and then applying them?

      2b. Or would our only resolve be to try to programmatically export the current datawedge settings and then import them into the application logic and apply them to the EMDK settings?


      Thanks in advance.

        • Re: Datawedge API / Reading out Datawedge profile programmatically
          Billie Hecox

          Hello Marian, To my knowledge, there is no programmatic way to read DataWedge profiles.  The Profiles can be manually configured and exported, and then the profile can be imported back in when placed in the DataWedge auto-import folder.  DataWedge stores the profile and values in a private SQLite database and is not made available to end developers.


          All that being said, How granular are the changes you are making to the profile. Are you needing to turn on/off individual settings, or could you build a set of profiles for specific use cases, and copy one of those profiles into the auto-import folder when needed?  

            • Re: Datawedge API / Reading out Datawedge profile programmatically
              Marian Moron

              Hi Bill,


              you see, the thing is that we don't want to control/manipulate/add onto the Datawedge profiles themselves. We just want to inherit their profile settings for use in our application to alter the application's EMDK profile. From that point onwards we no longer require Datawedge or its profiles. So, in our specific case, the end-user will be able to change some settings at their will. Ofcourse, we might in the longer term override some more critical settings with those that the application itself absolutely requires, but there will always be a degree of freedom for the end-user.


              We chose the EMDK over Datawedge, because it seems to be more powerful and feels more "natural" to use in an application (we have the EMDK scanner working as a barcode scan fragment).

              If the EMDK had a profile editor available to the end-user (instead of the one only accessible to the developer in Android Studio), we wouldn't even be having this discussion. We would certainly like to avoid having to make our own front-end EMDK profile editor app, so that's why we're asking around about the datawedge profiles.


              If the current Datawedge profiles are kept in private SQLite databases, does this mean that the exported profiles are in a similar database (or easily readable) format ? I haven't had the opportunity to export one yet (but will soon), so maybe if someone has, they can quickly confirm this. If this is the case, then 2b) becomes a viable option, I suppose? If we could read from that export, then all that would be left for us to do, is figure out how to automate an export of the current DW profile at the launch of our application...