Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. how to deploy your software (set up)

how to deploy your software (set up)

Scheduled Pinned Locked Moved C#
databasehelpcsharpsqlitelinq
22 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • L Lost User

    You need to install System.Data.SQLite[^] on the target system.

    A Offline
    A Offline
    ago2486
    wrote on last edited by
    #4

    Thank you thank you and thank you you just relieved me of a problem that tired me for a long time. I followed your advice and walk. But my question is the following, if I will have to burn it on a CD to give it to a friend or mm has everyone how to go about it so that in the course of installatoin the sytem.data.sqlite installs automatically?

    L 1 Reply Last reply
    0
    • A ago2486

      Thank you thank you and thank you you just relieved me of a problem that tired me for a long time. I followed your advice and walk. But my question is the following, if I will have to burn it on a CD to give it to a friend or mm has everyone how to go about it so that in the course of installatoin the sytem.data.sqlite installs automatically?

      L Offline
      L Offline
      Lost User
      wrote on last edited by
      #5

      You need to follow the instructions of your setup builder. I think external libraries need to be added as dependencies.

      A 1 Reply Last reply
      0
      • L Lost User

        You need to follow the instructions of your setup builder. I think external libraries need to be added as dependencies.

        A Offline
        A Offline
        ago2486
        wrote on last edited by
        #6

        I use inno setup. i made a comment when i was installing my program on the pc it asked me the framwork .NET 3.5 which is launching once i have accepted but for the system.data.sqlite no ...

        L 1 Reply Last reply
        0
        • A ago2486

          I use inno setup. i made a comment when i was installing my program on the pc it asked me the framwork .NET 3.5 which is launching once i have accepted but for the system.data.sqlite no ...

          L Offline
          L Offline
          Lost User
          wrote on last edited by
          #7

          SQLite is not part of the standard .NET framework, it must be downloaded from the SQLite website.

          A 1 Reply Last reply
          0
          • L Lost User

            SQLite is not part of the standard .NET framework, it must be downloaded from the SQLite website.

            A Offline
            A Offline
            ago2486
            wrote on last edited by
            #8

            Hello sir and thank you for your answer ...
            I will like some advice about my program. If I want to give it to friends, I have to ask them to install system.data.sqlite on their pc? But is there not another alternative?

            L 1 Reply Last reply
            0
            • A ago2486

              Hello sir and thank you for your answer ...
              I will like some advice about my program. If I want to give it to friends, I have to ask them to install system.data.sqlite on their pc? But is there not another alternative?

              L Offline
              L Offline
              Lost User
              wrote on last edited by
              #9

              The alternative is that you add the requirement to your setup program, so it is automatically installed. Check the documentation for the setup generator that you are using.

              A 2 Replies Last reply
              0
              • L Lost User

                The alternative is that you add the requirement to your setup program, so it is automatically installed. Check the documentation for the setup generator that you are using.

                A Offline
                A Offline
                ago2486
                wrote on last edited by
                #10

                Thank you I use inno setup, I will document and make you a continuation of my research

                1 Reply Last reply
                0
                • L Lost User

                  The alternative is that you add the requirement to your setup program, so it is automatically installed. Check the documentation for the setup generator that you are using.

                  A Offline
                  A Offline
                  ago2486
                  wrote on last edited by
                  #11

                  I just realized that although I managed to connect to my database thanks to you, I can not register ... here is the error message:
                  Failed to connect to the data source attempt to write a readonly database
                  attempt to write a readonly database

                  :wtf: :wtf:

                  L 1 Reply Last reply
                  0
                  • A ago2486

                    I just realized that although I managed to connect to my database thanks to you, I can not register ... here is the error message:
                    Failed to connect to the data source attempt to write a readonly database
                    attempt to write a readonly database

                    :wtf: :wtf:

                    L Offline
                    L Offline
                    Lost User
                    wrote on last edited by
                    #12

                    You need to check your code and your setup. Either the database is in a protected folder, or your open statement needs an extra parameter.

                    A 2 Replies Last reply
                    0
                    • L Lost User

                      You need to check your code and your setup. Either the database is in a protected folder, or your open statement needs an extra parameter.

                      A Offline
                      A Offline
                      ago2486
                      wrote on last edited by
                      #13

                      I send you my code and if possible give me a link or I can send you all the program for inspection on your part

                      1 Reply Last reply
                      0
                      • L Lost User

                        You need to check your code and your setup. Either the database is in a protected folder, or your open statement needs an extra parameter.

                        A Offline
                        A Offline
                        ago2486
                        wrote on last edited by
                        #14

                        using System;
                        using System.Collections.Generic;
                        using System.ComponentModel;
                        using System.Data;
                        using System.Drawing;
                        using System.Linq;
                        using System.Text;
                        using System.Windows.Forms;
                        using System.Data.OleDb;
                        using System.Data.SQLite;

                        namespace Acode
                        {
                        public partial class Form1 : Form
                        {
                        public Form1()
                        {
                        InitializeComponent();

                            }
                            private SQLiteConnection sql\_con;
                            private SQLiteCommand sql\_cmd;
                            private SQLiteDataAdapter DB;
                            private DataSet DS = new DataSet();
                            private DataTable DT = new DataTable();
                        
                            private void setConnection()
                            {
                                //CONNEXION A LA BASE DE DONNEE
                            sql\_con = new SQLiteConnection(@"Data Source=DBcode.db; Version=3;New=;Compress=True;");
                            }
                        
                            private void LoadData()
                            {
                                setConnection();
                                sql\_con.Open();
                                sql\_cmd = sql\_con.CreateCommand();
                                string CommandText = "select \* from InfoCode";
                                DB = new SQLiteDataAdapter(CommandText, sql\_con);
                                DS.Reset();
                                DB.Fill(DS);
                                DT = DS.Tables\[0\];
                                dataGridView1.DataSource = DT;
                                sql\_con.Close();
                            }
                        
                            private void Form1\_Load(object sender, EventArgs e)
                            {
                                LoadData();
                        
                            }
                        
                            private void ExecuteQuery(String txtQuery)
                            {
                            setConnection();
                            sql\_con.Open();
                            sql\_cmd = sql\_con.CreateCommand();
                            sql\_cmd.CommandText = txtQuery;
                            sql\_cmd.ExecuteNonQuery();
                            sql\_con.Close();
                            }
                        
                            public static string randomstring(int length)
                            {
                                const string chars = "ABCDEFGHIJKLMNOPQRSTUVWYZ0123456789";
                                Random random = new Random();
                                return new string(Enumerable.Repeat(chars, length).Select(s => s\[random.Next(s.Length)\]).ToArray());
                            }
                            private void btnGenerer\_Click(object sender, EventArgs e)
                            {
                               
                                lblAffichage.Text = randomstring(4);
                                txtAffichPrix.Text = "100";
                            }
                        
                            private void button1\_Click(object sender, EventArgs e)
                            {
                                lblAffichage.Text = randomstring(5);
                                txtAffichPrix.Text = "300";
                            }
                        
                            private void button2\_Click(object sender, EventArgs e)
                            {
                                lblAffichage.Text = randomstring(6);
                                txtAffichPrix.Text = "500";
                            }
                        
                           
                            private void btnEnregistrer\_Click(object s
                        
                        L 1 Reply Last reply
                        0
                        • A ago2486

                          using System;
                          using System.Collections.Generic;
                          using System.ComponentModel;
                          using System.Data;
                          using System.Drawing;
                          using System.Linq;
                          using System.Text;
                          using System.Windows.Forms;
                          using System.Data.OleDb;
                          using System.Data.SQLite;

                          namespace Acode
                          {
                          public partial class Form1 : Form
                          {
                          public Form1()
                          {
                          InitializeComponent();

                              }
                              private SQLiteConnection sql\_con;
                              private SQLiteCommand sql\_cmd;
                              private SQLiteDataAdapter DB;
                              private DataSet DS = new DataSet();
                              private DataTable DT = new DataTable();
                          
                              private void setConnection()
                              {
                                  //CONNEXION A LA BASE DE DONNEE
                              sql\_con = new SQLiteConnection(@"Data Source=DBcode.db; Version=3;New=;Compress=True;");
                              }
                          
                              private void LoadData()
                              {
                                  setConnection();
                                  sql\_con.Open();
                                  sql\_cmd = sql\_con.CreateCommand();
                                  string CommandText = "select \* from InfoCode";
                                  DB = new SQLiteDataAdapter(CommandText, sql\_con);
                                  DS.Reset();
                                  DB.Fill(DS);
                                  DT = DS.Tables\[0\];
                                  dataGridView1.DataSource = DT;
                                  sql\_con.Close();
                              }
                          
                              private void Form1\_Load(object sender, EventArgs e)
                              {
                                  LoadData();
                          
                              }
                          
                              private void ExecuteQuery(String txtQuery)
                              {
                              setConnection();
                              sql\_con.Open();
                              sql\_cmd = sql\_con.CreateCommand();
                              sql\_cmd.CommandText = txtQuery;
                              sql\_cmd.ExecuteNonQuery();
                              sql\_con.Close();
                              }
                          
                              public static string randomstring(int length)
                              {
                                  const string chars = "ABCDEFGHIJKLMNOPQRSTUVWYZ0123456789";
                                  Random random = new Random();
                                  return new string(Enumerable.Repeat(chars, length).Select(s => s\[random.Next(s.Length)\]).ToArray());
                              }
                              private void btnGenerer\_Click(object sender, EventArgs e)
                              {
                                 
                                  lblAffichage.Text = randomstring(4);
                                  txtAffichPrix.Text = "100";
                              }
                          
                              private void button1\_Click(object sender, EventArgs e)
                              {
                                  lblAffichage.Text = randomstring(5);
                                  txtAffichPrix.Text = "300";
                              }
                          
                              private void button2\_Click(object sender, EventArgs e)
                              {
                                  lblAffichage.Text = randomstring(6);
                                  txtAffichPrix.Text = "500";
                              }
                          
                             
                              private void btnEnregistrer\_Click(object s
                          
                          L Offline
                          L Offline
                          Lost User
                          wrote on last edited by
                          #15

                          Sorry, I have no idea why you have posted all that code. You need to do some investigation and debugging to find out what is happening.

                          A 1 Reply Last reply
                          0
                          • L Lost User

                            Sorry, I have no idea why you have posted all that code. You need to do some investigation and debugging to find out what is happening.

                            A Offline
                            A Offline
                            ago2486
                            wrote on last edited by
                            #16

                            ok sir i'm doing some research and giving you a follow up of my research.
                            Thank you for your patience and your availability

                            1 Reply Last reply
                            0
                            • A ago2486

                              Hi programmer friend, I finished my software that is connected to a SQLite database that works perfectly and I wanted to deploy it on another machine. I have an error message: Can not load file or assembly 'System.Data.SQlite. Version = 1.0.108.0. Culture = neutral. PublicKeyToken = db937bc2d44ff139 ' or one of his dependencies. The specified file can not be found Thank you for bringing me your help here is the connectoin code: ( using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Windows.Forms; using System.Data.OleDb; using System.Data.SQLite; namespace Acode {     public partial class Form1: Form     {         public Form1 ()         {             InitializeComponent ();                                  }         private SQLiteConnection sql_con; private SQLiteCommand sql_cmd;         private SQLiteDataAdapter DB; private DataSet DS = new DataSet (); private DataTable DT = new DataTable ();         private void setConnection () {             // CONNECTING TO THE DATABASE sql_con = new SQLiteConnection (@ "Data Source = DBcode.db; Version = 3; New =; Compress = True;"); }         private void LoadData ()         {             SetConnection ();             sql_con.Open ();             sql_cmd = sql_con.CreateCommand ();             string CommandText = "select * from InfoCode";             DB = new SQLiteDataAdapter (CommandText, sql_con);             DS.Reset ();             DB.Fill (DS);             DT = DS.Tables [0];             dataGridView1.DataSource = DT;             sql_con.Close ();         }         private void Form1_Load (object sender, EventArgs e)         {             LoadData ();         }         private void ExecuteQuery (String txtQuery) {         SetConnection (); sql_con.Open (); sql_cmd = sql_con.CreateCommand (); sql_cmd.CommandText = txtQuery; sql_cmd.ExecuteNonQuery (); sql_con.Close (); }         public static string randomstring (int length)         {             const string chars = "ABCDEFGHIJKLMNOPQRSTUVWYZ0123456789";             Random random = new Random ();             return new string (Enumerable.Repeat (floats, length) .Select (s => s [random.Next (s.Length)]). ToArray ());         }         private void btnGenerer_Click (object sender, EventArgs e)         {                         lblDisplay.Text = randomstring (4);             txtAfficPrice.Text = "100";         }

                              L Offline
                              L Offline
                              Lost User
                              wrote on last edited by
                              #17

                              The files you need to "distribute" are in your "bin\Release" folder. Create your setup and test on your machine. Then "zip it" and send it to your fiends via the "cloud". No "CD burning". DVD/CD drives are "optional" these days ... not the ".NET framework"; unless your friends are running XP.

                              "(I) am amazed to see myself here rather than there ... now rather than then". ― Blaise Pascal

                              A 1 Reply Last reply
                              0
                              • L Lost User

                                The files you need to "distribute" are in your "bin\Release" folder. Create your setup and test on your machine. Then "zip it" and send it to your fiends via the "cloud". No "CD burning". DVD/CD drives are "optional" these days ... not the ".NET framework"; unless your friends are running XP.

                                "(I) am amazed to see myself here rather than there ... now rather than then". ― Blaise Pascal

                                A Offline
                                A Offline
                                ago2486
                                wrote on last edited by
                                #18

                                Thank you sir but I have an error message when I want to make a recording: Failed to connect to the data source
                                attempt to write a readonly database
                                I am looking for documentation to this problem but not in continuation

                                L 1 Reply Last reply
                                0
                                • A ago2486

                                  Thank you sir but I have an error message when I want to make a recording: Failed to connect to the data source
                                  attempt to write a readonly database
                                  I am looking for documentation to this problem but not in continuation

                                  L Offline
                                  L Offline
                                  Lost User
                                  wrote on last edited by
                                  #19

                                  What's "in the database"? Nothing? Then create it on site. Read SQLite goes "read only" with certain installations; nothing to do with C#. Google "sqlite read only" for lots of "answers". Shoulda used SQL Server CE.

                                  "(I) am amazed to see myself here rather than there ... now rather than then". ― Blaise Pascal

                                  A 1 Reply Last reply
                                  0
                                  • L Lost User

                                    What's "in the database"? Nothing? Then create it on site. Read SQLite goes "read only" with certain installations; nothing to do with C#. Google "sqlite read only" for lots of "answers". Shoulda used SQL Server CE.

                                    "(I) am amazed to see myself here rather than there ... now rather than then". ― Blaise Pascal

                                    A Offline
                                    A Offline
                                    ago2486
                                    wrote on last edited by
                                    #20

                                    Hello Gerry Schmitz and thank you for your help, I will document and make you a return, But I would like you to guide me on a code that I saw during but research:
                                    Read only connection
                                    Data Source = c: \ mydb.db; Version = 3; Read Only = True;
                                    I even use this connection but the same error message is displayed ...

                                    L 1 Reply Last reply
                                    0
                                    • A ago2486

                                      Hello Gerry Schmitz and thank you for your help, I will document and make you a return, But I would like you to guide me on a code that I saw during but research:
                                      Read only connection
                                      Data Source = c: \ mydb.db; Version = 3; Read Only = True;
                                      I even use this connection but the same error message is displayed ...

                                      L Offline
                                      L Offline
                                      Lost User
                                      wrote on last edited by
                                      #21

                                      Sorry, don't understand the "question". I said the "install" is the problem; not the "connection string". My "solution" is SQL Server CE; otherwise, you have the internet's "solutions" ... because, I do not use SQLite.

                                      "(I) am amazed to see myself here rather than there ... now rather than then". ― Blaise Pascal

                                      A 1 Reply Last reply
                                      0
                                      • L Lost User

                                        Sorry, don't understand the "question". I said the "install" is the problem; not the "connection string". My "solution" is SQL Server CE; otherwise, you have the internet's "solutions" ... because, I do not use SQLite.

                                        "(I) am amazed to see myself here rather than there ... now rather than then". ― Blaise Pascal

                                        A Offline
                                        A Offline
                                        ago2486
                                        wrote on last edited by
                                        #22

                                        thank you very much I am always looking for the solution of my problem. I hope to escape

                                        1 Reply Last reply
                                        0
                                        Reply
                                        • Reply as topic
                                        Log in to reply
                                        • Oldest to Newest
                                        • Newest to Oldest
                                        • Most Votes


                                        • Login

                                        • Don't have an account? Register

                                        • Login or register to search.
                                        • First post
                                          Last post
                                        0
                                        • Categories
                                        • Recent
                                        • Tags
                                        • Popular
                                        • World
                                        • Users
                                        • Groups