Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Reply
Developer
testinz
Posts: 173
Registered: ‎09-03-2012
My Device: Blackberry 10
Accepted Solution

Filepicker example does not compile

I downloaded the filepicker example and it doesn't compile with the following error:

 

MAKEFILE_GENERATORC:\bbndk\host_10_0_9_52\win32\x86\usr\bin\ntox86-ld: cannot find -lfilepicker

 


Just wondering how do you fix that error?

Please use plain text.
Developer
testinz
Posts: 173
Registered: ‎09-03-2012
My Device: Blackberry 10

Re: Filepicker example does not compile

Compiled now. Someone need to update the documentation and the example

 

Change from ViewMode to FilePickerViewMode

 

The library reference should be LIBS   += -lbbcascadespickers instead of -lfilepicker

Please use plain text.
Developer
testinz
Posts: 173
Registered: ‎09-03-2012
My Device: Blackberry 10

Re: Filepicker example does not compile

BAH, both the filepicker example and the Filepicker example on the API documentation do not work in the Simulator.

picker.open() doesn't show anything.
Please use plain text.
Developer
peter9477
Posts: 6,473
Registered: ‎12-08-2010
My Device: PlayBook, Z10
My Carrier: none

Re: Filepicker example does not compile

The example should be fixed now.

Peter Hansen -- (BB10 and dev-related blog posts at http://peterhansen.ca.)
Author of White Noise and Battery Guru for BB10 and for PlayBook | Get more from your battery!
Please use plain text.
Developer
testinz
Posts: 173
Registered: ‎09-03-2012
My Device: Blackberry 10

Re: Filepicker example does not compile

Thanks! FilePIcker and Camera both work in Simulator now!

Please use plain text.
Contributor
maheshkumar1990
Posts: 44
Registered: ‎01-07-2013
My Device: 9300
My Carrier: blackberry

Re: Filepicker example does not compile

Hi can anyone send some sample codes  for implementing filepicker in bb10 cascades ,i jhave already gone to this link https://github.com/blackberry/Cascades-Samples/tree/master/filepicker but its not working showing me error

thanks

 

Please use plain text.
Developer
peter9477
Posts: 6,473
Registered: ‎12-08-2010
My Device: PlayBook, Z10
My Carrier: none

Re: Filepicker example does not compile

If it's showing an error, show US the error so we can actually help you! It's probably a minor thing...

Peter Hansen -- (BB10 and dev-related blog posts at http://peterhansen.ca.)
Author of White Noise and Battery Guru for BB10 and for PlayBook | Get more from your battery!
Please use plain text.
Contributor
maheshkumar1990
Posts: 44
Registered: ‎01-07-2013
My Device: 9300
My Carrier: blackberry

Re: Filepicker example does not compile

Thanks for reply sir

 i can able to access the file picker using the code,i can able to get the image path from the toast message,now i want to set the path image to an image view (as like profile image )

Button {
                   
                   text: "Set Profile Image"
               
                    onClicked: {
                        filePicker.open();
                    }
                    attachedObjects: [
                        FilePicker {
                            id: filePicker
                            property string selectedFile
                            title: qsTr("Choose photo")
                            type: FileType.Picture
                           
                             
                            
                            onFileSelected: {
                                selectedFile = selectedFiles[0]
                                settings.showToast("sccc"+selectedFile);
                            }
                        }
                    ]
                    //                }
                }

 

Please use plain text.
Developer
peter9477
Posts: 6,473
Registered: ‎12-08-2010
My Device: PlayBook, Z10
My Carrier: none

Re: Filepicker example does not compile

You mentioned an error. I don't see one in your post. Did you resolve that problem and are asking about a new one?

If this issue isn't related to the topic of this thread (building the Filepicker example code itself) please start a new thread. That will help save others time wasted reading it, and will get you more attention for your own issue.

Peter Hansen -- (BB10 and dev-related blog posts at http://peterhansen.ca.)
Author of White Noise and Battery Guru for BB10 and for PlayBook | Get more from your battery!
Please use plain text.
Developer
borceg
Posts: 670
Registered: ‎03-21-2012
My Device: BlackBerry PlayBook 16GB
My Carrier: Vip

Re: Filepicker example does not compile

This error is logged when using FilePicker in simulator

 

Jan 12 06:54:16.419    com.example.bb10samples.pickers.filepicker.testDev__filepicker2.112685171    default    9000    INFO        FilePickerPrivate::onCardInvokeRequestFinished()  . error= 6 
Jan 12 06:54:16.419    com.example.bb10samples.pickers.filepicker.testDev__filepicker2.112685171    default    9000    INFO        "Unable to open File Picker/Saver Card" 
Jan 12 06:54:16.419    com.example.bb10samples.pickers.filepicker.testDev__filepicker2.112685171    default    9000    INFO        InvokeReply::Error= "6" 
Jan 12 06:54:16.614    com.example.bb10samples.pickers.filepicker.testDev__filepicker2.112685171    default    0    INFO        NavigatorEventHandler::Received - BPS - NAVIGATOR_CHILD_CARD_CLOSED

 

Please use plain text.