Import framework library in xojo mac

I am new in XOJO, and developing desktop app, I need to print label on seiko label printer , I got SDK(".framework") and example (written in objective C),
So I have tried to use “Declare”.

Here is the problem:
I want to create class for ".framework " file to make label print easy. But I run project it get crashed every time.

Would you mind posting a code example of one of your declares?
Did you try to address “.framework” literally? If so, this would be part of the problem. There’s the framework name missing.

declare function SIISLP_Open lib "SIISmartLabelPrinter.framework" selector "SIISLP_Open" (printer as ptr) as Ptr return SIISLP_Open(printer)

I have put “SIISmartLabelPrinter.framework” on same folder where xojo binary project is present

Thank you! What does Console tell you: Is it framework not found or a different error?

Maybe you have to copy (via copy step) the framework in the resource folder

[code]Check with the developer to make sure LabelPrinter.debug works with this version of OS X. You may need to reinstall the application. Be sure to install any available updates for the application and OS X.

Click Report to see more detailed information and send a report to Apple.[/code]

And have 2 buttons “Ignore” and “Report”

My app can not started because of this issue

As Ulrich suggested, open the console app and find the crash report.
At the beginning of this report you will find the reason (can’t find the framework, can’t find the selector and so on)

Thank you, How do I do this “open the console app and find the crash report.”???

it’s in utility folder within application folder or simply search for console and open it from the search result

If you never opened the console app, you have to take your time to find the report link in the long console report… but don’t worry it will be there

[quote=267548:@Akshay Patil] declare function SIISLP_Open lib "SIISmartLabelPrinter.framework" selector "SIISLP_Open" (printer as ptr) as Ptr return SIISLP_Open(printer)

I have put “SIISmartLabelPrinter.framework” on same folder where xojo binary project is present[/quote]

Use a copy files build step to place the framework in the application bundle’s Frameworks directory. Then change your declare library to be “@executable_path/…/Frameworks/SIISmartLabelPrinter.framework”.

Library not loaded: /System/Library/Frameworks/SIISmartLabelPrinter.framework/SIISmartLabelPrinter

Ok thank you I got this, I need to install drivers, Can I put that in /System/Library/Frameworks???

You don’t need to install the library in the system
Joe reply is the correct one
I forgot to tell you to change the path to the library

So:
copy the framework with a copy set in the app framework library
in the declare change the lib name to “@executable_path/…/Frameworks/SIISmartLabelPrinter.framework”.

It is worked THANK YOU

NOW
Please suggest
can I continue with this conversation or create new conversation for " I want to create class for ".framework " file to make label print easy ". Do I need to create my own class file or there is any tool to get functions and procedure from library.

This forum is an archive of solutions too, so it’s often better to open a new thread when the original topic has been answered – makes it easier for others with a similar problem to spot the solution.

But about your question: Do you mean if there is any tool that does the declares for you? There are some, but usually optimized for certain framework documentations. Look for example for “DeclareMaker” by Jason King here on this forum.

In general, I found the external declares save a lot of typing time. After you have created a few for the most common data types, it’s often just a case of copy & paste.

Thank you for reply.
Please check this , I have posted new conversation