ITeye博客

AndLi

AndLi · 共 228 篇文章

底部菜单

<LinearLayout android:id="@+id/main_radio" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_alignParentBottom="true" android:layout_gravity="bottom" android:background="@drawable/toolbar2_bg" android:gravity="center_vertical" android:orientation="horizontal" > …

2012-05-15 12:06 · 评论(0)

对话框菜单

/** * * @author lilin * @date 2012-5-18 下午2:21:14 * @annotation 对话框菜单 */ public static void showAlertMenu(Context con, String title, String menuitems[], DialogInterface.OnClickListener listener) { AlertDialog.Builder builder = new AlertDialog.Builder(con); builder.setTitle(title); builder.setItems(…

2012-05-10 22:21 · Dialog · 评论(0)

如何同model匹配

注意表名是model的类名,不是数据库的表名 sql = "from FrameAttachInfo where CLIENGGUID='" + rowguid + "'"; 执行方法: List<FrameAttachStorage> list0 = em.createQuery(sql0).getResultList(); Model类生成注意: 1.注意有下划线的字段: @Column(name = "DETAIL_ADDRESS") private String DETAIL_ADDRESS; 2.注意全部大写,可以因为是Oracle数据库吧

2012-05-04 09:44 · JWeb · 评论(0)

蓝牙常用方法

打开蓝牙: 有提示: Intent enableIntent = new Intent( BluetoothAdapter.ACTION_REQUEST_ENABLE); startActivityForResult(enableIntent, REQUEST_ENABLE_BT); 无提示: mBluetoothAdp = BluetoothAdapter.getDefaultAdapter();// 获取本地蓝牙适配器 mBluetoothAdp.enable(); 关闭蓝牙: mBluetoothAdp.disenable();

2012-05-03 21:57 · 评论(0)

HandlerThread的使用

package com.lilin.looper; import android.app.Activity; import android.os.Bundle; import android.os.Handler; import android.os.HandlerThread; import android.os.Looper; import android.os.Message; /** * 使用Looper来处理消息队列 * * @author lilin * @date 2011-8-10 上午09:03:32 * @ClassName: HandlerTest2 * @Descri…

2012-05-03 08:21 · Handler_Thread · 评论(0)

通过Runnable来实现普通线程和Handler

package com.andli.handlerandthread; import android.app.Activity; import android.os.Bundle; import android.os.Handler; import android.util.Log; public class HandlerAndThreadDemo extends Activity { private String tag = "andli"; public void onCreate(Bundle savedInstanceState) { super.onCreate(savedIns…

2012-05-03 08:20 · Handler_Thread · 评论(0)

handler处理message

package com.lilin.handler; import android.app.Activity; import android.os.Bundle; import android.os.Handler; import android.os.Message; import android.widget.ImageView; /** * 通过Handler实现2秒自动换图 * * @author lilin * @date 2011-8-10 上午08:51:27 * @ClassName: Main * @Description: TODO */ public class Han…

2012-05-03 08:19 · Handler_Thread · 评论(0)

android 更新ADT之后 报java.lang.NoClassDefFound

android 更新ADT之后 报java.lang.NoClassDefFound 选中工-->Java Build Path --> 选中标签 Order and Export -->选中 没有找到的class 的jar包 或者 包含的工程 -->点击OK

2012-04-21 09:21 · 评论(0)

AutoCompleteTextView记录历史记录

package org.yaoming.read_his; import android.app.Activity; import android.content.SharedPreferences; import android.os.Bundle; import android.view.View; import android.view.View.OnClickListener; import android.widget.ArrayAdapter; import android.widget.AutoCompleteTextView; public class AutoTextVie…

2012-04-20 23:26 · AutoCompleteTextView · 评论(0)

Handler实现2秒自动切图

package com.lilin.handler; import android.app.Activity; import android.os.Bundle; import android.os.Handler; import android.os.Message; import android.widget.ImageView; /** * 通过Handler实现2秒自动换图 * * @author lilin * @date 2011-8-10 上午08:51:27 * @ClassName: Main * @Description: TODO */ public class Mai…

2012-04-18 23:26 · 评论(0)

Handler和线程

package com.andli.handlerandthread; import android.app.Activity; import android.os.Bundle; import android.os.Handler; import android.util.Log; public class HandlerAndThreadActivity extends Activity { private String tag = "andli"; public void onCreate(Bundle savedInstanceState) { super.onCreate(save…

2012-04-18 23:17 · 评论(0)

进度条对话框:通过Handler实现

package com.lilin.progressdialog; //声明包语句 import android.app.Activity; import android.app.Dialog; import android.app.ProgressDialog; import android.os.Bundle; import android.os.Handler; import android.os.Message; import android.util.Log; import android.view.View; import android.view.View.OnClickLis…

2012-04-18 22:29 · Dialog · 评论(0)

HellC

一个简单C程序: #define PRICE 30;//使用 #define来定义符号常量 //一般为大写,在其作用域里不能被改变,不能被赋值 #include <stdio.h> int main() { // int a,b; // scanf("%d,%d",&a,&b); //输入a,b scanf是输入函数 // // &a 意思是:取地址 将2个值分别输入a,b对应的地址中 // // printf("sum = %d \n ",a+b);//格式字符串 %d 表示:以十进制整数类型 // // int maxNum(int a,int b);//被调用函数的声明 :因为maxN…

2012-04-16 22:47 · 评论(0)

如何激活word2010

1111111111111111111

2012-04-13 10:13 · 工具的使用 · 评论(0)

PLSQL连接远程数据库配置

1111111111111111111111111111111

2012-04-10 19:54 · 工具的使用 · 评论(0)