Using enumerations in Basic4ppc

Discussion in 'Questions (Windows Mobile)' started by rossj, Feb 25, 2008.

  1. rossj

    rossj New Member Licensed User

    How do you access enumeration values in external dll's ? I am trialling the FieldSoftware PrinterCE program which uses Enumerations in some of the properties. For example: the "PrOrientation" property uses ORIENTATION.PORTRAIT or ORIENTATION.LANDSCAPE - the example they give is: PrinterCE1.PrOrientation = PrinterCE.ORIENTATION.LANDSCAPE <-this is the issue.:sign0085:
  2. Erel

    Erel Administrator Staff Member Licensed User

    I'm not sure if it will work but you can try to pass the enum value instead.
    PORTRAIT = 1
  3. rossj

    rossj New Member Licensed User

    Thanks Erel, but I had already tried that option. It causes an "ArgumentException".
    I contacted Field Software by email and they sent me a link to download a list of their global user definitions (prceuser.h). That does give a list of the value of each enumeration instead of trying to guess the value - but it doesn't solve the probelm.
    I have responded to their email advising there must be something in their code causing the exception. I'll advise you if they have a solution.
  4. Erel

    Erel Administrator Staff Member Licensed User

    I don't think that they will be able to solve this problem.

    You will need to use a custom wrapper.
    It should be a pretty simple wrapper. I may build one in the future.
  5. dzt

    dzt Active Member Licensed User


    This is a simple b4ppc PrinterCE wrapper, written in VB.NET in the past for my own needs. Source code and SharpDevelop solution included.

    Needs also PrCE_NetCF.DLL and PrinterCE.NETCF.DLL form FieldSoftware.

    Attached Files:

  6. rossj

    rossj New Member Licensed User

    Hi Guys,

    The repsonse from Field Software was "We have not used Basic4ppc, so you will need to contact their support to determine how to accomplish what you are seeking."

    I will download your wrapper - thanks for your assistance. :)
  7. manu

    manu Active Member Licensed User

    Hi friends

    You have any example of how to use Printerce with Basic4ppc?

    Thank you
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice