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

Web and WebWorks Development

Reply
New Contributor
mmk236
Posts: 7
Registered: ‎05-13-2013
My Device: Blackberry 10

Blackberry Webworks extension to fetch email id configured on Blackberry 10

I am trying to write a Blackberry webworks extension to fetch a email id (email account) configured on Blackberry 10 device.

But i am not able to implement that. Kindly help me how can i proceed with this although i have checked the sample "Memory" extension but for email not getting anything. Thanks in Advance. 

Retired
astanley
Posts: 1,382
Registered: ‎07-02-2009
My Device: BlackBerry Bold 9900
My Carrier: Bell

Re: Blackberry Webworks extension to fetch email id configured on Blackberry 10

Can I confirm that you are having issues with packaging the pieces of a WebWorks extension?

 

Or are you trying to figure out the native C/C++ code that goes inside of the extension?

Follow me on Twitter: @n_adam_stanley
-------------------------------------------------------------------------------------------------------------------------
Your app doesn't work? Use BlackBerry remote web inspector to find out why.
New Contributor
mmk236
Posts: 7
Registered: ‎05-13-2013
My Device: Blackberry 10

Re: Blackberry Webworks extension to fetch email id configured on Blackberry 10

Yeah, i am trying to figure out the native C++ part to use in webworks extension, which i am not able to do so.

Developer
peardox
Posts: 1,229
Registered: ‎03-20-2011
My Device: Playbook, Z10 LE, Dev Alpha B, 2x Dev Alpha C

Re: Blackberry Webworks extension to fetch email id configured on Blackberry 10

I can think of no situation or app other than a spam whereby you would need that information

 

Prove me wrong




Click the like button if you find my posts useful!
New Contributor
mmk236
Posts: 7
Registered: ‎05-13-2013
My Device: Blackberry 10

Re: Blackberry Webworks extension to fetch email id configured on Blackberry 10

This is our enterprise application scenario where we require the email id of the account configured on Blackberry device and also the device IMEI number.

 

For your information, we have already implemented this for Android and Blackberry 7 devices.

New Contributor
mmk236
Posts: 7
Registered: ‎05-13-2013
My Device: Blackberry 10

Re: Blackberry Webworks extension to fetch email id configured on Blackberry 10

For Blackberry 10 we are able to fetch device IMEI number using Blackberry Weborks. But we are facing issues with Email.
Developer
peardox
Posts: 1,229
Registered: ‎03-20-2011
My Device: Playbook, Z10 LE, Dev Alpha B, 2x Dev Alpha C

Re: Blackberry Webworks extension to fetch email id configured on Blackberry 10

OK - good answer

 

IMEI is easy - that's in deviceinfo

 

Can't be sure unless I try it myself

 

I would  start @ NDK -> BPS as this is where most things stem from

 

Pay attention to deviceinfo




Click the like button if you find my posts useful!
Developer
peardox
Posts: 1,229
Registered: ‎03-20-2011
My Device: Playbook, Z10 LE, Dev Alpha B, 2x Dev Alpha C

Re: Blackberry Webworks extension to fetch email id configured on Blackberry 10

[ Edited ]

IMEI - built in

 

function getBBDeviceInfo() {
	devcaps = new Object();

	devcaps.aver = blackberry.app.version;	
	devcaps.hwid = blackberry.system.hardwareId;
	devcaps.uuid = blackberry.identity.uuid;

	devcaps.name = blackberry.system.name;
	devcaps.osver = blackberry.system.softwareVersion;
	
	devcaps.imei = blackberry.identity.IMEI;
	devcaps.gps = blackberry.system.hasCapability("location.gps");
	
	devcaps.sdcard = blackberry.system.hasCapability("storage.memorycard");
	devcaps.touch = blackberry.system.hasCapability("input.touch");

	devcaps.lang = blackberry.system.language;
	devcaps.regn = blackberry.system.region;
	
return devcaps;

}

 

Soz - bad JS - cut, paste, delete but you can get the idea from this




Click the like button if you find my posts useful!
Developer
peardox
Posts: 1,229
Registered: ‎03-20-2011
My Device: Playbook, Z10 LE, Dev Alpha B, 2x Dev Alpha C

Re: Blackberry Webworks extension to fetch email id configured on Blackberry 10

Oops - config.xml needs [some] of this

 

	<rim:permissions> 
	<!-- Location -->
		<rim:permit>read_geolocation</rim:permit> 
		<rim:permit>access_location_services</rim:permit>
		
	<!-- Keep server connection available in background -->
		<rim:permit>run_when_backgrounded</rim:permit>
		
	<!-- uuid + IMEI -->
		<rim:permit>read_device_identifying_information</rim:permit>
	</rim:permissions>
	
	<!-- Basic App stuff -->
	<feature id="blackberry.app" required="true" version="1.0.0.0"/>

	<!-- Compass -->
	<feature id="blackberry.sensors" />

	<!-- uuid + IMEI -->
	<feature id="blackberry.identity" />
	
	<!-- Device Caps -->
	<feature id="blackberry.system" />

 




Click the like button if you find my posts useful!
New Contributor
mmk236
Posts: 7
Registered: ‎05-13-2013
My Device: Blackberry 10

Re: Blackberry Webworks extension to fetch email id configured on Blackberry 10

Thanks for your reply...

Yeah using Blackberry.Identitity we can fetch IMEI number that is running perfectly fine on all blackberry devices but what about email thats my main issue on blackberry10.

If anyone suggest me what all APIs or anything in webworks that can be used on Backberry 10 to fetch email id.

Thanks in Advance.