排序Facebook好友生日列表月明智的安卓明智、好友、生日、列表

由网友(念旧人)分享简介:可能重复: Hackbook样品code到取当月名单的Facebook好友生日 我已经作出了计划,对此我的撷取的列表我所有的的Facebook好友 .. 现在我想我模块的更多的自定义用户的,并希望让用户看到自己的好友列表月明智问: 如何排序的Facebook好友列表中的当前月或周只有那些生日...code获取所有好友...

可能重复:   Hackbook样品code到取当月名单的Facebook好友生日

我已经作出了计划,对此我的撷取的列表我所有的的Facebook好友 ..

现在我想我模块的更多的自定义用户的,并希望让用户看到自己的好友列表月明智

问:

 如何排序的Facebook好友列表中的当前月或周只有那些生日...
 

code获取所有好友的列表:

 公共静态无效requestFriends(FacebookRequest facebookRequest){
Log.d(LOG_TAGrequestFriends(+));
字符串查询=选择姓名,生日,UID,从用户pic_square其中uid中(从朋友选择UID2那里UID1 =我()),以便通过birthday_date;
捆绑PARAMS =新包();
params.putString(法,fql.query);
params.putString(查询,查询);
FacebookUtility.asyncRunner.request(NULL,则params,
新FacebookRequestListener(FacebookRequestListener.FRIENDS,facebookRequest));
}
 
关于QQ好友排列问题

code,以获取好友列表那些生日在一月月:

 字符串查询=选择姓名,生日,UID,pic_square从用户那里UID的(从朋友选择UID2那里UID1 =我())和birthday_date> = '01 / 01 与birthday_date< = '01 / 31'ORDER BY birthday_date ASC;
 

解决方案

据我所知,你已经知道了如何从具体月份得到朋友。 虽然我不知道android的,我相信你只需要获得当前月份和FQL插入。

 日历C = Calendar.getInstance();
INT月= c.get(Calendar.MONTH)
字符串查询=选择姓名,生日,UID,pic_square从用户那里UID的(从朋友选择UID2那里UID1 =我())和birthday_date> ='+月+/ 01和birthday_date< ='+月+/ 31ORDER BY birthday_date ASC;
 

或者类似的东西。

Possible Duplicate: Hackbook sample code to Fetch List of Current Month Facebook Friends Birthdays

I have made a program in which i am Fetching list of my all Facebook Friends..

Now i want to make my module more custom for users and want to allow user to see their Friends List Month Wise

Question:

How to sort Facebook Friends List those birthdays in Current Month or Week only...

Code to Fetch List of all Friends:

 public static void requestFriends(FacebookRequest facebookRequest) {
Log.d(LOG_TAG, "requestFriends(" + ")");
String query = "select name, birthday, uid, pic_square from user where uid in (select uid2 from friend where uid1=me()) order by birthday_date";
Bundle params = new Bundle();
params.putString("method", "fql.query");
params.putString("query", query);
FacebookUtility.asyncRunner.request(null, params, 
new   FacebookRequestListener(FacebookRequestListener.FRIENDS, facebookRequest));
}

Code to Fetch List of Friends those birthdays in January Month:

String query = "select name, birthday, uid, pic_square from user where uid in (select uid2 from friend where uid1=me())AND birthday_date >= '01/01' AND birthday_date <= '01/31' ORDER BY birthday_date ASC";

解决方案

From what I understand you already know how to get friends from a specific month. While I don't know android I believe you just need to get the current month and insert it in the fql.

Calendar c = Calendar.getInstance(); 
int month = c.get(Calendar.MONTH)
String query = "select name, birthday, uid, pic_square from user where uid in (select uid2 from friend where uid1=me())AND birthday_date >= '" + month+ "/01' AND birthday_date <= '" + month+ "/31' ORDER BY birthday_date ASC";

Or something similar.

阅读全文

相关推荐

最新文章