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
ekke
Posts: 1,563
Registered: ‎04-08-2010
My Device: Z10 (red Limited Edition), Q10, Z30
My Carrier: Telekom.de, O2, Vodafone

Re: BBM, Facebook, Twitter, FourSquare Integration and Invocation


kylefowler wrote:
Foursquare has a bunch of invocation support that we will be documenting closer to launch date.

really looking forward to this informations and also a preview app

want to integrate Foursquare into my Conference2Go-Applications which will also come to BB10

 

-------------------------------------------------------------------------------
ekke (independent software architect, rosenheim, germany)

BlackBerry Elite Developer
BlackBerry Platinum Enterprise Partner
International Development Mobile Apps BlackBerry 10 Cascades
Cascades - Workshops / Trainings / Bootcamps

blog: http://ekkes-corner.org videos: http://www.youtube.com/user/ekkescorner http://vimeo.com/ekkescorner/videos
bb10-development: http://appbus.org Twitter: @ekkescorner
Contributor
hishamBakr
Posts: 45
Registered: ‎04-11-2012
My Device: Z10 Limited Edition

Re: BBM, Facebook, Twitter, FourSquare Integration and Invocation

Although it says "type mismatch" but I ignored the error and started the application. it runs fine. it seems that it is a bug in the QML editor

When you are young, work to learn. Not to earn !
Regular Contributor
CrozyBB
Posts: 83
Registered: ‎07-19-2012
My Device: Bold 9790, Dev Alpha A

Re: BBM, Facebook, Twitter, FourSquare Integration and Invocation

Oh thanks, that works great!

 

Any idea why I can't send text from a property variant? Let's say I'm sending data to my QML page in the form "item.title"

 

I can display this text in a label like so,

Label{
     id: testLabel
     text: item.title
}

 if I set the data parameter in the InvokeActionItem to item.title I get nothing being sent to BBM. I've also tried converting it to a string using qsTr(item.title).

InvokeActionItem {
        id: invokeTextBBM
	query {
                mimeType: "text/plain"
                invokeTargetId: "sys.bbm.sharehandler"
                invokeActionId: "bb.action.SHARE"
                data: item.title
            }
        }
}

 Any thoughts?

 

BlackBerry Development Advisor
MSohm
Posts: 14,753
Registered: ‎07-09-2008
My Device: BlackBerry Passport

Re: BBM, Facebook, Twitter, FourSquare Integration and Invocation

[ Edited ]

Values in the query are not dynamic.  Use the onTriggered method to set values from runtime like this.

 

InvokeActionItem {
    title: "Share Text Over BBM"
    query {
        mimeType: "text/plain"
        invokeTargetId: "sys.bbm.sharehandler"
        invokeActionId: "bb.action.SHARE"
        data: "This is some text to share."
    }
    onTriggered: {
        data = "Some new text"
    }
}

 

This would cause "Some new text" to be sent.  You can specify a variable or control in its place.

Mark Sohm
BlackBerry Development Advisor

Please refrain from posting new questions in solved threads.
Problem solved? Click the Accept As Solution button.
Found a bug? Report it using Issue Tracker
Regular Contributor
CrozyBB
Posts: 83
Registered: ‎07-19-2012
My Device: Bold 9790, Dev Alpha A

Re: BBM, Facebook, Twitter, FourSquare Integration and Invocation

Thanks! That works great for text data :smileyhappy:

 

...not having the same luck with pictures and the uri parameter. Is it possible to set that as well using the onTriggered method? I've tried using this:

InvokeActionItem {
	        title: "Share "
	        query {
		        mimeType: "image/jpg"
		        invokeTargetId: "sys.bbm.sharehandler"
		        uri: "file:///accounts/1000/shared/camera/IMG_00000006.jpg"
		        invokeActionId: "bb.action.SHARE"
	        }
	        onTriggered: {
	            uri = "file:///accounts/1000/shared/camera/IMG_00000003.jpg"
	        }
        }

 And it tries sending IMG_00000006.jpg

Developer
bbquincar
Posts: 304
Registered: ‎08-14-2012
My Device: PlayBook, Z10, Dev C

Re: BBM, Facebook, Twitter, FourSquare Integration and Invocation

If i wanted to copy and image or text in application and share via bbm. is there a way to do it instaed of actual going to the particual item.

 

eg

i copy a some text in my app say a web from a web page

and then press bbm share text 

instead of the below meassage i want the copied item

data: "This is some text to share."

 

BlackBerry 10 game reviews for the unknown, small and indie developers. Little games with big dreams. VeryBerryGames.com | Follow @VeryBerryGames | TwoCasualCoders.com | never casual on quality
BlackBerry Development Advisor
MSohm
Posts: 14,753
Registered: ‎07-09-2008
My Device: BlackBerry Passport

Re: BBM, Facebook, Twitter, FourSquare Integration and Invocation

That looks like a bug to me.  I've logged the issue of the data element not updating here.

 

InvokeActionItem onTriggered doesn't update URI

Mark Sohm
BlackBerry Development Advisor

Please refrain from posting new questions in solved threads.
Problem solved? Click the Accept As Solution button.
Found a bug? Report it using Issue Tracker
Developer
shahumang8
Posts: 671
Registered: ‎08-09-2010
My Device: Not Specified

Re: BBM, Facebook, Twitter, FourSquare Integration and Invocation

Hello MSohm,

 

       Thanks for sharing it.Very usefull.

 

       One more query about PDF.So how to PDF Reader Invoke.

 

        I try like this

     

  "application/pdf
    application/x-pdf"

 

 

        But not get any sucess.So if any update or any mistake just sloved it asap.

 

Thanks.       

     

Developer
shahumang8
Posts: 671
Registered: ‎08-09-2010
My Device: Not Specified

Re: BBM, Facebook, Twitter, FourSquare Integration and Invocation

Any Update?