String apiKey = context.getResources().getString(R.string.api_key);
String secret = context.getResources().getString(R.string.api_secret);;
DoubanService myService = new DoubanService(context.getResources().getString(R.string.app_name), apiKey, secret);
String url = myService.getAuthorizationUrl(“http://www.douban.com”);
执行以上最后一句的时候,报出错误com.google.gdata.client.douban.DoubanService.getAuthorizationUrl(Unknown Source) 有哪个大神知道这是怎么回事吗?
在注册应用的时候我写的callback地址为:http://www.douban.com
现在将这个地址传递回去是错误的。 后来我看大多数写的是String url = myService.getAuthorizationUrl(null);
但是这样写还是有错。 最后从eoe上查看,有的说在调用这个Util的activity的注册信息中加入
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category
android:name="android.intent.category.DEFAULT" />
<category
android:name="android.intent.category.BROWSABLE" />
<data android:scheme="http://www.douban.com" />
</intent-filter> 但是仍然不行。
我彻底是找不到解决办法了,大神们帮帮忙啊。好几天了,纠结死了
String secret = context.getResources().getString(R.string.api_secret);;
DoubanService myService = new DoubanService(context.getResources().getString(R.string.app_name), apiKey, secret);
String url = myService.getAuthorizationUrl(“http://www.douban.com”);
执行以上最后一句的时候,报出错误com.google.gdata.client.douban.DoubanService.getAuthorizationUrl(Unknown Source) 有哪个大神知道这是怎么回事吗?
在注册应用的时候我写的callback地址为:http://www.douban.com
现在将这个地址传递回去是错误的。 后来我看大多数写的是String url = myService.getAuthorizationUrl(null);
但是这样写还是有错。 最后从eoe上查看,有的说在调用这个Util的activity的注册信息中加入
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category
android:name="android.intent.category.DEFAULT" />
<category
android:name="android.intent.category.BROWSABLE" />
<data android:scheme="http://www.douban.com" />
</intent-filter> 但是仍然不行。
我彻底是找不到解决办法了,大神们帮帮忙啊。好几天了,纠结死了
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货