Example #1
0
 private void btnOpenSQLite_Click(object sender, EventArgs e)
 {
     if (this.openFileDialog1.ShowDialog() == DialogResult.OK)
     {
         this.txtSQLitePath.Text = openFileDialog1.FileName;
         sqler = new SQLiteHelper("Data source=" + this.txtSQLitePath.Text);
     }
 }
Example #2
0
        private void btnBulidJSONDic_Click(object sender, EventArgs e)
        {
            if (sqler == null)
            {
                if (string.IsNullOrEmpty(txtSQLitePath.Text))
                    sqler = new SQLiteHelper("Data source=" + this.txtSQLitePath.Text + ";");
            }

            if (!Directory.Exists(targetDirectory))
            {
                Directory.CreateDirectory(targetDirectory);
            }

            BulidBookJSON();
            MessageBox.Show("生成完成");
        }