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

Posts: 19
Registered: ‎11-18-2010
My Device: touch 9800,9700

Import phone contact Detail in application.





     I m new in blackberry application developement. and i have task to develop the module to add contact name and email address and phone number in my application.


     I want to develop the modul it has 3 field like:


         1 . name

         2.  phone number

         3.  email add


   i have to fill this information in the application  dynamically from my phone book of which i have stored the contact .


   I am using blackberry web tool for eclipse. and i am creating application with html and javascript.



   Please help me and give any code to import contact detail which is stored in my phone book.

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

Re: Import phone contact Detail in application.



To accomplish this requirement, you will need to learn about the BlackBerry WebWorks JavaScript APIs, specifically the FilterExpression object that is part of the blackberry.find feature.  


The API reference guide contains the following sample code that demonstrates how to retrieve contact info from the address book:



<script type="text/javascript">  
  // Find all appointments with "start" date later than current time   
  var d = new Date();
  var fe1 = new blackberry.find.FilterExpression("start", ">", d);  
  var appt = blackberry.pim.Appointment.find(fe1, 10);   

  // Find all contacts with "firstName" lead by "Eric"   
  var fe2 = new blackberry.find.FilterExpression("firstName", "REGEX", "Eric[a-zA-Z_0-9 ]*");  
  var result = blackberry.pim.Contact.find(fe2);
  for (i = 0; i < result.length; i++)


If you need more assistance, check out the following learning resources:






Hope that helps,




Follow me on Twitter: @n_adam_stanley
Your app doesn't work? Use BlackBerry remote web inspector to find out why.
Posts: 19
Registered: ‎11-18-2010
My Device: touch 9800,9700

Re: Import phone contact Detail in application.


Thanks ,

           For the reply but i want to open the contact list so that user can select the contact from that list.

I have got for the search of contact but i want to get the contact in the subwindow .


                And i am using widget for the developement of my application .


so Please help me.