검색결과 리스트
안드로이드/android에 해당되는 글 27건
- 2013.01.09 특정 전화 번호로 주소록에 등록 되어 있는지 체크하기
- 2013.01.04 Dialog Fullscreen theme
- 2012.12.27 setOnClickListener 온 클릭 이벤트 리스너 listener 사용법 1
- 2012.12.14 전화번호로 CONTACT_ID와 RAW_CONTACT_ID 아이디 알아내기
- 2012.12.12 문자 String 인지 숫자 Integer 인지 체크
글
특정 전화 번호로 주소록에 등록 되어 있는지 체크하기
Uri lookupUri = Uri.withAppendedPath(PhoneLookup.CONTENT_FILTER_URI, Uri.encode("010-2542-1452"));
Cursor is_c = getContentResolver().query(lookupUri, new String[]{ContactsContract.Contacts._ID},null,null,null);
try {
is_c.moveToFirst();
Log.i("fddd","사람이 있넹");
// is_c.moveToNext();
} catch (Exception e) {}
finally{is_c.close();}
'안드로이드 > android' 카테고리의 다른 글
배경 이미지 repeat 시키기 (0) | 2013.01.25 |
---|---|
통화이력 목록으로 뽑아내기 (0) | 2013.01.23 |
Dialog Fullscreen theme (0) | 2013.01.04 |
setOnClickListener 온 클릭 이벤트 리스너 listener 사용법 (1) | 2012.12.27 |
전화번호로 CONTACT_ID와 RAW_CONTACT_ID 아이디 알아내기 (0) | 2012.12.14 |
설정
트랙백
댓글
글
Dialog Fullscreen theme
res/values/theme.xml
------------------------------------------------------------------------------
<style name="Theme.DialogFullScreen" parent="@android:style/Theme.Dialog">
<item name="android:windowFullscreen">true</item>
<item name="android:windowFrame">@null</item>
<item name="android:windowNoTitle">true</item>
<item name="android:windowIsFloating">true</item>
<item name="android:windowContentOverlay">@null</item>
<item name="android:windowBackground">@color/transparent</item>
</style>
AndroidManifest.xml
------------------------------------------------------------------------------
<activity android:name=".test" android:label="@string/savecontactswithg_msg" android:screenOrientation="portrait" android:theme="@style/Theme.DialogFullScreen" />
'안드로이드 > android' 카테고리의 다른 글
통화이력 목록으로 뽑아내기 (0) | 2013.01.23 |
---|---|
특정 전화 번호로 주소록에 등록 되어 있는지 체크하기 (0) | 2013.01.09 |
setOnClickListener 온 클릭 이벤트 리스너 listener 사용법 (1) | 2012.12.27 |
전화번호로 CONTACT_ID와 RAW_CONTACT_ID 아이디 알아내기 (0) | 2012.12.14 |
문자 String 인지 숫자 Integer 인지 체크 (0) | 2012.12.12 |
설정
트랙백
댓글
글
setOnClickListener 온 클릭 이벤트 리스너 listener 사용법
// button
ImageButton lay_btn_back=(ImageButton) findViewById(R.id.btn_back);
ImageButton lay_btn_save=(ImageButton) findViewById(R.id.btn_save);
lay_btn_back.setOnClickListener(clickListener);
lay_btn_save.setOnClickListener(clickListener);
View.OnClickListener clickListener = new View.OnClickListener() {
public void onClick(View v) {
switch (v.getId()) {
case R.id.btn_back:
finish();
break;
case R.id.btn_save:
Toast.makeText(act,"저장",Toast.LENGTH_SHORT).show();
break;
}
}
};
'안드로이드 > android' 카테고리의 다른 글
특정 전화 번호로 주소록에 등록 되어 있는지 체크하기 (0) | 2013.01.09 |
---|---|
Dialog Fullscreen theme (0) | 2013.01.04 |
전화번호로 CONTACT_ID와 RAW_CONTACT_ID 아이디 알아내기 (0) | 2012.12.14 |
문자 String 인지 숫자 Integer 인지 체크 (0) | 2012.12.12 |
문자중 특정 문자가 있는지 체크 하기 (0) | 2012.12.11 |
설정
트랙백
댓글
글
전화번호로 CONTACT_ID와 RAW_CONTACT_ID 아이디 알아내기
String _id = "";
String raw_id="";
final Uri uri = ContactsContract.CommonDataKinds.Phone.CONTENT_URI;
String[] projection = new String[] {
ContactsContract.CommonDataKinds.Phone.CONTACT_ID,
ContactsContract.CommonDataKinds.Phone.RAW_CONTACT_ID
};
String selection = ContactsContract.CommonDataKinds.Phone.NUMBER + "=?";
String[] select_args={"010123456"};
Cursor is_c = getContentResolver().query(
uri,projection,selection,select_args,null
);
try {
is_c.moveToFirst();
_id=is_c.getString(0);
raw_id=is_c.getString(1);
} catch (Exception e) {}
finally{
is_c.close();
}
'안드로이드 > android' 카테고리의 다른 글
Dialog Fullscreen theme (0) | 2013.01.04 |
---|---|
setOnClickListener 온 클릭 이벤트 리스너 listener 사용법 (1) | 2012.12.27 |
문자 String 인지 숫자 Integer 인지 체크 (0) | 2012.12.12 |
문자중 특정 문자가 있는지 체크 하기 (0) | 2012.12.11 |
HashMap while문 (key=>Value) 돌리기 (0) | 2012.12.11 |
설정
트랙백
댓글
글
문자 String 인지 숫자 Integer 인지 체크
public static boolean isNumber(String str) {
boolean check = true;
for(int i = 0; i < str.length(); i++) {
if(!Character.isDigit(str.charAt(i))) {
check = false;
break;
}
}
return check;
}
'안드로이드 > android' 카테고리의 다른 글
setOnClickListener 온 클릭 이벤트 리스너 listener 사용법 (1) | 2012.12.27 |
---|---|
전화번호로 CONTACT_ID와 RAW_CONTACT_ID 아이디 알아내기 (0) | 2012.12.14 |
문자중 특정 문자가 있는지 체크 하기 (0) | 2012.12.11 |
HashMap while문 (key=>Value) 돌리기 (0) | 2012.12.11 |
[주소록]그룹 카운팅 하기 (0) | 2012.12.10 |