نمایش نتایج 1 تا 10 از 10

نام تاپیک: برنامه اندرویدی با زامارین و استفاده از SQLite

  1. #1
    کاربر دائمی آواتار ghasem110deh
    تاریخ عضویت
    اردیبهشت 1393
    محل زندگی
    تهران
    پست
    1,148

    Post برنامه اندرویدی با زامارین و استفاده از SQLite

    بنام خدا
    سلام به همه :-)
    در خدمت دوستان هستیم با آموزش استفاده از زامارین و دیتابیس اسکیوال لایت ...
    توجه: فقط از طریق NuGet کامپوننت sqlit.net-pcl رو به پروژه اضافه کنید !

    بریم سر اصل مطلب :
    خوب طبیعتا مثل برنامه نویسی با اندروید استودیو باید اول لایه های نمایشی (layout) رو ایجاد کرد !

    لایه اصلی برنامه که بعد از اجرا به کاربر نمایش داده میشه (لانچر)

    کد HTML:
    <?xml version="1.0" encoding="utf-8"?>
    <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
        android:orientation="vertical"
        android:layout_width="fill_parent"
        android:layout_height="fill_parent"
        android:minWidth="25px"
        android:minHeight="25px"
        android:background="#3498DB">
        <LinearLayout
            android:orientation="vertical"
            android:minWidth="25px"
            android:minHeight="25px"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:id="@+id/linearLayout1"
            android:layout_gravity="fill"
            android:layout_margin="5dp">
            <EditText
                android:hint="نام کاربری"
                android:gravity="center"
                android:inputType="textPersonName"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:id="@+id/edtName"
                android:textColor="#ffffff" />
            <EditText
                android:hint="کلمه عبور"
                android:gravity="center"
                android:inputType="numberPassword"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:id="@+id/edtPass"
                android:textColor="#ffffff" />
            <Button
                android:gravity="center"
                android:text="ورود"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:id="@+id/btnLogin"
                android:layout_margin="5dp" />
            <Button
                android:gravity="center"
                android:text="ایجاد حساب"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:id="@+id/btnRegisterPage"
                android:layout_margin="5dp" />
            <Button
                android:gravity="center"
                android:text="نمایش کاربران"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:id="@+id/btnShow"
                android:layout_margin="5dp" />
        </LinearLayout>
        <ListView
            android:minWidth="25px"
            android:minHeight="25px"
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:id="@+id/listVIEW" />
    </LinearLayout>
    این در واقع صفحه آبی رنگ توی تصاویر ضمیمه هست !

    و اینم لایه رجیستر (یا همون ثبت نام و ورود اطلاعات توسط کاربر)

    کد HTML:
    <?xml version="1.0" encoding="utf-8"?>
    <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
        android:orientation="vertical"
        android:layout_width="fill_parent"
        android:layout_height="fill_parent"
        android:minWidth="25px"
        android:minHeight="25px">
        <ImageView
            android:src="@android:drawable/ic_menu_gallery"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:id="@+id/imageView" />
        <Button
            android:text="انتخاب تصویر"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:id="@+id/btnSelectPic" />
        <EditText
            android:hint="نام کاربری"
            android:gravity="center"
            android:inputType="textPersonName"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:id="@+id/edtName" />
        <EditText
            android:hint="کلمه عبور"
            android:gravity="center"
            android:inputType="numberPassword"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:id="@+id/edtPass" />
        <EditText
            android:hint="توضیحات"
            android:gravity="center"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:id="@+id/edtDescription" />
        <CheckBox
            android:text="خانم هستید؟"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:id="@+id/checkGender" />
        <Button
            android:text="ثبت و ادامه"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:id="@+id/btnCreatAccunt" />
    </LinearLayout>
    نکته : اینجا یه لایه خالی داریم که به هیچ اکتیویتی ای مربوط نمیشه و در واقع ایجاد یک لیست ویو سفارشی هست ش

    کد HTML:
    <?xml version="1.0" encoding="utf-8"?>
    <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
        android:orientation="vertical"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:minWidth="25px"
        android:minHeight="25px">
        <TextView
            android:text="نام کاربری"
            android:textAppearance="?android:attr/textAppearanceLarge"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:id="@+id/txtName" />
        <TextView
            android:text="جنسیت"
            android:textAppearance="?android:attr/textAppearanceSmall"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:id="@+id/txtGender" />
        <TextView
            android:text="توضیحات"
            android:textAppearance="?android:attr/textAppearanceSmall"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:id="@+id/txtDescription" />
    </LinearLayout>
    این لایه نمایشی توی یک لایه که مربوط به اکتیویتی نمایش لیست اعضا هست نمایش داده میشه
    لایه لیست اعضا تنها حاوی یه لیست ویو هست !
    عکس های ضمیمه عکس های ضمیمه

  2. #2
    کاربر دائمی آواتار ghasem110deh
    تاریخ عضویت
    اردیبهشت 1393
    محل زندگی
    تهران
    پست
    1,148

    نقل قول: برنامه اندرویدی با زامارین و استفاده از SQLite

    خوب حالا بیام سراغ کار با دیتابیس و سی شارپ :-)

    اول دیتابیس رو توی پوشه Assets پروژه اضافه کنید ... و یه کلاس ایجاد کنید به اسم Database یا هر اسم دیگه ای که دوست دارین :

    using Android.App;
    using Android.Util;
    using SQLite;
    using System;
    using System.Collections.Generic;
    using System.IO;
    using System.Linq;

    namespace ExistingSqliteSample.Resources.Model
    {
    public class DataBase
    {
    #region copy and create database and tables
    public string sqliteCon()
    {
    try
    {
    string path = Environment.GetFolderPath(Environment.SpecialFolde r.Personal);
    string dbPath = Path.Combine(path, "fitnessDBupdate.db");
    CopyDatabase("fitnessDBupdate.db");
    string conn = dbPath;
    return conn;
    }
    catch (SQLiteException ex)
    {
    Log.Info("SQLite Ex", ex.ToString());
    return null;
    }
    }

    private void CopyDatabase(string dataBaseName)
    {
    try
    {
    var dbPath = Path.Combine(Environment.GetFolderPath(Environment .SpecialFolder.Personal), dataBaseName);
    if (!File.Exists(dbPath))
    {
    var dbAssetStream = Application.Context.Assets.Open(dataBaseName);
    var dbFileStream = new FileStream(dbPath, FileMode.OpenOrCreate);
    var buffer = new byte[1024];
    int b = buffer.Length;
    int length;
    while ((length = dbAssetStream.Read(buffer, 0, b)) > 0)
    {
    dbFileStream.Write(buffer, 0, length);
    }
    dbFileStream.Flush();
    dbFileStream.Close();
    dbAssetStream.Close();
    }
    }
    catch (SQLiteException ex)
    {
    Log.Info("SQLite Ex", ex.ToString());
    }
    }

    public void createTables()
    {
    try
    {
    using (var conn = new SQLiteConnection(sqliteCon()))
    {
    conn.CreateTable<Members>();
    }
    }
    catch (SQLiteException ex)
    {
    Log.Info("SQLite Ex", ex.ToString());
    }
    }
    #endregion

    #region tbl Members
    public bool insertMembers(Members members)
    {
    try
    {
    using (var conn = new SQLiteConnection(sqliteCon()))
    {
    conn.Insert(members);
    }
    return true;
    }
    catch (SQLiteException ex)
    {
    Log.Info("SQLite EX", ex.ToString());
    return false;
    }
    }

    public bool updateMembers(Members members)
    {
    try
    {
    using (var conn = new SQLiteConnection(sqliteCon()))
    {
    conn.Query<Members>("Update tblMembers Set fullName=?, gender=?, memDescription=?, pic=?, password=? Where id=?",
    members.fullName, members.gender, members.memDescription, members.pic, members.password, members.id);
    }
    return true;
    }
    catch (SQLiteException ex)
    {
    Log.Info("SQLite EX", ex.ToString());
    return false;
    }
    }

    public bool deleteMembers(Members members)
    {
    try
    {
    using (var conn = new SQLiteConnection(sqliteCon()))
    {
    conn.Delete(members);
    }
    return true;
    }
    catch (SQLiteException ex)
    {
    Log.Info("SQLite EX", ex.ToString());
    return false;
    }
    }

    public bool selectMembers(int id)
    {
    try
    {
    using (var conn = new SQLiteConnection(sqliteCon()))
    {
    conn.Query<Members>("Select * From tblMembers Where id=?", id);
    }
    return true;
    }
    catch (SQLiteException ex)
    {
    Log.Info("SQLite EX", ex.ToString());
    return false;
    }
    }

    public bool loginMembers(string fullName, string password)
    {
    try
    {
    using (var conn = new SQLiteConnection(sqliteCon()))
    {
    conn.Query<Members>("Select * From tblMembers Where (fullName=? And password=?)", fullName, password);
    }
    return true;
    }
    catch (SQLiteException ex)
    {
    Log.Info("SQLite EX", ex.ToString());
    return false;
    }
    }

    public List<Members> listMembers()
    {
    try
    {
    using (var conn = new SQLiteConnection(sqliteCon()))
    {
    return conn.Table<Members>().ToList();
    }
    }
    catch (SQLiteException ex)
    {
    Log.Info("SQLite EX", ex.ToString());
    return null;
    }
    }
    #endregion
    }
    }


    چون دوستان سی شارپ کار میکنید دیگه توضیحی در مورد کد ها نمیدم ... فقط اگه سوالی بود بپرسین !
    اگه بتونم جواب میدم :-)
    آخرین ویرایش به وسیله ghasem110deh : شنبه 27 آذر 1395 در 20:26 عصر

  3. #3
    کاربر دائمی آواتار ghasem110deh
    تاریخ عضویت
    اردیبهشت 1393
    محل زندگی
    تهران
    پست
    1,148

    نقل قول: برنامه اندرویدی با زامارین و استفاده از SQLite

    کلاسی برای تعریف فیلد های جدول و ...
    یه پوشه به اسم model اضافه کنید و داخل اون کلاس رو ایجاد کنید :


    using SQLite;

    namespace ExistingSqliteSample.Resources.Model
    {
    [Table("tblMembers")]
    public class Members
    {
    [PrimaryKey, AutoIncrement, Column("id")]
    public int id { get; set; }

    [MaxLength(50), Column("fullName")]
    public string fullName { get; set; }

    [Column("gender")]
    public bool gender { get; set; }

    [MaxLength(100), Column("memDescription")]
    public string memDescription { get; set; }

    [Column("pic")]
    public byte[] pic { get; set; }

    [MaxLength(16), Column("password")]
    public string password { get; set; }
    }
    }
    آخرین ویرایش به وسیله ghasem110deh : شنبه 27 آذر 1395 در 20:27 عصر

  4. #4
    کاربر دائمی آواتار ghasem110deh
    تاریخ عضویت
    اردیبهشت 1393
    محل زندگی
    تهران
    پست
    1,148

    نقل قول: برنامه اندرویدی با زامارین و استفاده از SQLite

    ایجاد کلاس آداپتر برای خوندن اطلاعات جدول و نمایش در لیست ویو ...


    using Android.App;
    using Android.Views;
    using Android.Widget;
    using ExistingSqliteSample.Resources.Model;
    using System.Collections.Generic;

    namespace ExistingSqliteSample.Resources
    {
    public class ViewHolder : Java.Lang.Object
    {
    public TextView txtName { get; set; }
    public TextView txtGender { get; set; }
    public TextView txtDescription { get; set; }
    }

    public class ListViewAdapter : BaseAdapter
    {
    private Activity activity;
    private List<Members> lstmem;

    public ListViewAdapter(Activity activity, List<Members> lstmem)
    {
    this.activity = activity;
    this.lstmem = lstmem;
    }

    public override int Count
    {
    get
    {
    return lstmem.Count;
    }
    }

    public override Java.Lang.Object GetItem(int position)
    {
    return null;
    }

    public override long GetItemId(int position)
    {
    return lstmem[position].id;
    }

    public override View GetView(int position, View convertView, ViewGroup parent)
    {
    var view = convertView ?? activity.LayoutInflater.Inflate(Resource.Layout.us er_listview, parent, false);
    var txtName = view.FindViewById<TextView>(Resource.Id.txtName);
    var txtGender = view.FindViewById<TextView>(Resource.Id.txtGender) ;
    var txtDescription = view.FindViewById<TextView>(Resource.Id.txtDescrip tion);
    txtName.Text = lstmem[position].fullName;
    if (lstmem[position].gender)
    txtGender.Text = "آقا";
    else
    txtGender.Text = "خانم";
    txtDescription.Text = lstmem[position].memDescription;
    return view;
    }
    }
    }

  5. #5
    کاربر دائمی آواتار ghasem110deh
    تاریخ عضویت
    اردیبهشت 1393
    محل زندگی
    تهران
    پست
    1,148

    نقل قول: برنامه اندرویدی با زامارین و استفاده از SQLite

    اکتیوی اصلی :


    using Android.App;
    using Android.OS;
    using Android.Widget;
    using ExistingSqliteSample.Resources;
    using ExistingSqliteSample.Resources.Model;
    using System;
    using System.Collections.Generic;

    namespace ExistingSqliteSample
    {
    [Activity(Label = "ExistingSqliteSample", MainLauncher = true, Icon = "@drawable/icon")]
    public class MainActivity : Activity
    {

    Button btnRegister;
    Button btnLog;
    Button btnDisplay;
    EditText edtName;
    EditText edtPass;

    protected override void OnCreate(Bundle bundle)
    {
    base.OnCreate(bundle);
    SetContentView(Resource.Layout.Main);

    // معرفی کنترل ها
    btnRegister = FindViewById<Button>(Resource.Id.btnRegisterPage);
    btnLog = FindViewById<Button>(Resource.Id.btnLogin);
    btnDisplay = FindViewById<Button>(Resource.Id.btnShow);
    edtName = FindViewById<EditText>(Resource.Id.edtName);
    edtPass = FindViewById<EditText>(Resource.Id.edtPass);

    // رویدادها
    btnLog.Click += delegate
    {

    };

    btnRegister.Click += delegate
    {
    StartActivity(typeof(RgisterActivity));
    };

    btnDisplay.Click += delegate
    {
    StartActivity(typeof(UserinfoActivity));
    };
    }
    }
    }

  6. #6
    کاربر دائمی آواتار ghasem110deh
    تاریخ عضویت
    اردیبهشت 1393
    محل زندگی
    تهران
    پست
    1,148

    نقل قول: برنامه اندرویدی با زامارین و استفاده از SQLite

    رجیستر اکتیوتی :


    using Android.App;
    using Android.Content;
    using Android.Graphics;
    using Android.OS;
    using Android.Util;
    using Android.Widget;
    using ExistingSqliteSample.Resources.Model;
    using SQLite;
    using System;
    using System.IO;

    namespace ExistingSqliteSample
    {
    [Activity(Label = "RgisterActivity")]
    public class RgisterActivity : Activity
    {
    Button btnselectImage;
    Button btnCreateAcount;
    EditText edtuserName;
    EditText edtpassword;
    EditText edtdescription;
    CheckBox checkGender;
    ImageView userImg;

    public static readonly int PickImageId = 1000;
    bool gender = false;

    DataBase db;

    protected override void OnCreate(Bundle savedInstanceState)
    {
    base.OnCreate(savedInstanceState);
    SetContentView(Resource.Layout.Register);
    // Create your application here

    btnselectImage = FindViewById<Button>(Resource.Id.btnSelectPic);
    btnCreateAcount = FindViewById<Button>(Resource.Id.btnCreatAccunt);
    edtpassword = FindViewById<EditText>(Resource.Id.edtPass);
    edtuserName = FindViewById<EditText>(Resource.Id.edtName);
    edtdescription = FindViewById<EditText>(Resource.Id.edtDescription) ;
    userImg = FindViewById<ImageView>(Resource.Id.imageView);
    checkGender = FindViewById<CheckBox>(Resource.Id.checkGender);

    checkGender.CheckedChange += delegate
    {
    if (checkGender.Checked)
    gender = true;
    else
    gender = false;
    };

    btnCreateAcount.Click += delegate
    {
    try
    {
    userImg.DrawingCacheEnabled = true;
    userImg.BuildDrawingCache();
    Bitmap bm = userImg.GetDrawingCache(true);
    MemoryStream stream = new MemoryStream();
    bm.Compress(Bitmap.CompressFormat.Png, 0, stream);
    byte[] byteArray = stream.ToArray();
    Members mem = new Members()
    {
    fullName = edtuserName.Text.Trim(),
    password = edtpassword.Text.Trim(),
    memDescription = edtdescription.Text.Trim(),
    gender = gender,
    pic = byteArray
    };
    db = new DataBase();
    db.insertMembers(mem);
    Toast.MakeText(this, "کاربر جدید ثبت شد", ToastLength.Short).Show();
    }
    catch (Exception ex)
    {
    Toast.MakeText(this, ex.ToString(), ToastLength.Short).Show();
    }
    };

    btnselectImage.Click += delegate
    {
    try
    {
    Intent = new Intent();
    Intent.SetType("*.Png");
    Intent.SetAction(Intent.ActionGetContent);
    StartActivityForResult(Intent.CreateChooser(Intent , "انتخاب عکس"), PickImageId);
    }
    catch (SQLiteException ex)
    {
    Log.Info("SQLite Ex", ex.ToString());
    }
    };
    }

    protected override void OnActivityResult(int requestCode, Result resultCode, Intent data)
    {
    try
    {
    if ((requestCode == PickImageId) && (resultCode == Result.Ok) && (data != null))
    {
    Android.Net.Uri uri = data.Data;
    userImg.SetImageURI(uri);
    }
    }
    catch (SQLiteException ex)
    {
    Log.Info("SQLite Ex", ex.ToString());
    }
    }
    }
    }

  7. #7
    کاربر دائمی آواتار ghasem110deh
    تاریخ عضویت
    اردیبهشت 1393
    محل زندگی
    تهران
    پست
    1,148

    نقل قول: برنامه اندرویدی با زامارین و استفاده از SQLite

    آپدیت اکتیویتی :


    using Android.App;
    using Android.Content;
    using Android.Graphics;
    using Android.OS;
    using Android.Util;
    using Android.Widget;
    using ExistingSqliteSample.Resources.Model;
    using SQLite;
    using System;
    using System.IO;

    namespace ExistingSqliteSample
    {
    [Activity(Label = "UpdateActivity")]
    public class UpdateActivity : Activity
    {
    Button selectImage;
    Button upadte;
    Button delete;
    ImageView imgUser;
    public EditText edtName;
    EditText edtPass;
    public EditText edtDesc;
    public CheckBox checkGender;

    public static readonly int PickImageId = 1000;
    bool gender = false;

    DataBase db;

    protected override void OnCreate(Bundle savedInstanceState)
    {
    base.OnCreate(savedInstanceState);
    SetContentView(Resource.Layout.Update);

    selectImage = FindViewById<Button>(Resource.Id.UDbtnSelectImage) ;
    upadte = FindViewById<Button>(Resource.Id.UDbtnUpdate);
    delete = FindViewById<Button>(Resource.Id.UDbtnInsert);
    edtName = FindViewById<EditText>(Resource.Id.UDedtName);
    edtPass = FindViewById<EditText>(Resource.Id.UDedtPass);
    edtDesc = FindViewById<EditText>(Resource.Id.UDedtDescriptio n);
    checkGender = FindViewById<CheckBox>(Resource.Id.UDcheck);

    selectImage.Click += delegate
    {
    try
    {
    Intent = new Intent();
    Intent.SetType("*.Png");
    Intent.SetAction(Intent.ActionGetContent);
    StartActivityForResult(Intent.CreateChooser(Intent , "انتخاب عکس"), PickImageId);
    }
    catch (SQLiteException ex)
    {
    Log.Info("SQLite Ex", ex.ToString());
    }
    };

    upadte.Click += delegate
    {
    try
    {
    imgUser.DrawingCacheEnabled = true;
    imgUser.BuildDrawingCache();
    Bitmap bm = imgUser.GetDrawingCache(true);
    MemoryStream stream = new MemoryStream();
    bm.Compress(Bitmap.CompressFormat.Png, 0, stream);
    byte[] byteArray = stream.ToArray();
    Members mem = new Members()
    {
    id = int.Parse(edtName.Tag.ToString()),
    fullName = edtName.Text.Trim(),
    password = edtPass.Text.Trim(),
    memDescription = edtDesc.Text.Trim(),
    gender = gender,
    pic = byteArray
    };
    db = new DataBase();
    db.updateMembers(mem);
    Toast.MakeText(this, "کاربر ویرایش شد", ToastLength.Short).Show();
    }
    catch (Exception ex)
    {
    Toast.MakeText(this, ex.ToString(), ToastLength.Short).Show();
    }
    };

    delete.Click += delegate
    {
    try
    {
    imgUser.DrawingCacheEnabled = true;
    imgUser.BuildDrawingCache();
    Bitmap bm = imgUser.GetDrawingCache(true);
    MemoryStream stream = new MemoryStream();
    bm.Compress(Bitmap.CompressFormat.Png, 0, stream);
    byte[] byteArray = stream.ToArray();
    Members mem = new Members()
    {
    id = int.Parse(edtName.Tag.ToString()),
    fullName = edtName.Text.Trim(),
    password = edtPass.Text.Trim(),
    memDescription = edtDesc.Text.Trim(),
    gender = gender,
    pic = byteArray
    };
    db = new DataBase();
    db.deleteMembers(mem);
    Toast.MakeText(this, "کاربر حذف شد", ToastLength.Short).Show();
    }
    catch (Exception ex)
    {
    Toast.MakeText(this, ex.ToString(), ToastLength.Short).Show();
    }
    };

    checkGender.CheckedChange += delegate
    {
    if (checkGender.Checked)
    gender = true;
    else
    gender = false;
    };
    }

    protected override void OnActivityResult(int requestCode, Result resultCode, Intent data)
    {
    try
    {
    if ((requestCode == PickImageId) && (resultCode == Result.Ok) && (data != null))
    {
    Android.Net.Uri uri = data.Data;
    imgUser.SetImageURI(uri);
    }
    }
    catch (SQLiteException ex)
    {
    Log.Info("SQLite Ex", ex.ToString());
    }
    }
    }
    }

  8. #8
    کاربر دائمی آواتار ghasem110deh
    تاریخ عضویت
    اردیبهشت 1393
    محل زندگی
    تهران
    پست
    1,148

    نقل قول: برنامه اندرویدی با زامارین و استفاده از SQLite

    یوزر اینفو اکتیوتی :
    (نمایش اطلاعات دیتابیس با لیست ویو)


    using Android.App;
    using Android.OS;
    using Android.Util;
    using Android.Widget;
    using ExistingSqliteSample.Resources;
    using ExistingSqliteSample.Resources.Model;
    using SQLite;
    using System.Collections.Generic;

    namespace ExistingSqliteSample
    {
    [Activity(Label = "UserinfoActivity")]
    public class UserinfoActivity : Activity
    {
    ListView lslmem;
    List<Members> lsltable = new List<Members>();
    DataBase db;

    protected override void OnCreate(Bundle savedInstanceState)
    {
    base.OnCreate(savedInstanceState);
    SetContentView(Resource.Layout.Userinfo);
    db = new DataBase();
    lslmem = FindViewById<ListView>(Resource.Id.listView);
    LoadData();
    lslmem.ItemSelected += delegate
    {
    lslmem.GetChildAt(0).SetBackgroundColor(Android.Gr aphics.Color.DarkGray);
    };

    lslmem.ItemLongClick += (s, e) =>
    {
    StartActivity(typeof(UpdateActivity));

    };
    }

    private void LoadData()
    {
    try
    {
    lsltable = db.listMembers();
    var adapter = new ListViewAdapter(this, lsltable);
    lslmem.Adapter = adapter;
    }
    catch (SQLiteException ex)
    {
    Log.Info("SQLite Ex", ex.ToString());
    }
    }
    }
    }

  9. #9
    کاربر دائمی آواتار ghasem110deh
    تاریخ عضویت
    اردیبهشت 1393
    محل زندگی
    تهران
    پست
    1,148

    نقل قول: برنامه اندرویدی با زامارین و استفاده از SQLite

    دوستان ببخشید اگه زیادی مختصر و مفید شد :-)
    سوالی بود بپرسین ...

    یه نکته هم حیفم میاد نگم : خودم شخصا ترجیح دادم برم سراغ اندروید استودیو !
    ولی به این معنی نیست که زامارین جواب نمیده .

  10. #10

    نقل قول: برنامه اندرویدی با زامارین و استفاده از SQLite

    سلام
    دوستانی که دوست دارن آموزشی برای کار با زامارین ببینند می تونند به مرجع فارسی آموزش زامارین مراجعه کنند .

تاپیک های مشابه

  1. سوال: طریقه استفاده از SQLite در برنامه
    نوشته شده توسط gilas1368 در بخش C#‎‎
    پاسخ: 4
    آخرین پست: جمعه 05 اردیبهشت 1393, 15:38 عصر
  2. اشكال در استفاده از sqlite در برنامه با دات نت 4
    نوشته شده توسط m110_110 در بخش C#‎‎
    پاسخ: 4
    آخرین پست: پنج شنبه 28 دی 1391, 08:47 صبح
  3. حرفه ای: ارتباط سایت با برنامه ی تحت ویندوز بدون استفاده از پایگاه داده
    نوشته شده توسط mohsen-unique در بخش ASP.NET Web Forms
    پاسخ: 7
    آخرین پست: شنبه 09 اردیبهشت 1391, 14:58 عصر
  4. نصب برنامه فقط با dll های استفاده شده از فریم ورک
    نوشته شده توسط smaill در بخش Setup و Deployment
    پاسخ: 5
    آخرین پست: پنج شنبه 27 خرداد 1389, 11:43 صبح
  5. یادگیری SQL استاندارد با استفاده از SQLite
    نوشته شده توسط rezaTavak در بخش Foxpro
    پاسخ: 50
    آخرین پست: چهارشنبه 26 فروردین 1388, 08:41 صبح

برچسب های این تاپیک

قوانین ایجاد تاپیک در تالار

  • شما نمی توانید تاپیک جدید ایجاد کنید
  • شما نمی توانید به تاپیک ها پاسخ دهید
  • شما نمی توانید ضمیمه ارسال کنید
  • شما نمی توانید پاسخ هایتان را ویرایش کنید
  •