Click here to Skip to main content
15,896,557 members
Home / Discussions / C#
   

C#

 
AnswerRe: Random numbers Pin
Abhinav S3-Apr-10 0:26
Abhinav S3-Apr-10 0:26 
GeneralRe: Random numbers Pin
Som Shekhar3-Apr-10 1:13
Som Shekhar3-Apr-10 1:13 
GeneralRe: Random numbers Pin
Abhinav S3-Apr-10 1:24
Abhinav S3-Apr-10 1:24 
GeneralRe: Random numbers Pin
harold aptroot3-Apr-10 1:47
harold aptroot3-Apr-10 1:47 
GeneralRe: Random numbers Pin
Abhinav S3-Apr-10 1:52
Abhinav S3-Apr-10 1:52 
GeneralRe: Random numbers Pin
Som Shekhar3-Apr-10 1:58
Som Shekhar3-Apr-10 1:58 
GeneralRe: Random numbers Pin
Abhinav S3-Apr-10 2:01
Abhinav S3-Apr-10 2:01 
QuestionConnexion with my database .sdf with c# smart device project Pin
Tunisien862-Apr-10 23:32
Tunisien862-Apr-10 23:32 
Hi,
My ConnexionForm contains 2 fields Login and Password.The user types his parameters.The system must verify the existance of this user in its database .sdf.So,I am blocked in relating my database with my interface.
First,Iwanna ask if ADO.NET is installed by default with Visual Studio 2008 or should i install it.
Second,this is my ConnexionForm's code that i haven't got any result with it:
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using System.Data.SqlServerCe;
using System.Configuration;
using System.Text.RegularExpressions; 

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

        private void pictureBox1_Click(object sender, EventArgs e)
        {

        }

        private void button1_Click(object sender, EventArgs e)
        {
           MenuPrincipal f = new MenuPrincipal();
            f.Show();
           
        }

        private void Form1_Load(object sender, EventArgs e)
        {
            String connectionString = null;
            try
            {
                connectionString = ConfigurationManager.ConnectionStrings["boutique"].ConnectionString;
            }
            catch (Exception e1)
            {
                Console.WriteLine("Erreur de configuration : {0}", e1.Message);
                return;
            }

            Console.WriteLine("Chaîne de connexion à la base : [{0}]\n", connectionString);
            try
            {
                using (SqlCeConnection connexion = new SqlCeConnection(connectionString))
                {
                    // ouverture connexion
                    connexion.Open();
                    MessageBox.Show("success");

                }
            }

            catch (Exception ex)
            {

                Console.WriteLine("Erreur d'accès à la base de données (" + ex.Message + ")");
            } 
        }
    }
}

Thanks a lot for u contribution
Question(Xml) Reading a Selected Node Attributes [modified] Pin
xEvOx2-Apr-10 22:58
xEvOx2-Apr-10 22:58 
Questionloged in user Pin
netJP12L2-Apr-10 16:46
netJP12L2-Apr-10 16:46 
AnswerRe: loged in user Pin
Eddy Vluggen3-Apr-10 14:32
professionalEddy Vluggen3-Apr-10 14:32 
QuestionDownload Video from YouTube Pin
harsimranb2-Apr-10 14:32
harsimranb2-Apr-10 14:32 
AnswerRe: Download Video from YouTube Pin
AspDotNetDev2-Apr-10 14:57
protectorAspDotNetDev2-Apr-10 14:57 
GeneralRe: Download Video from YouTube Pin
harsimranb2-Apr-10 15:13
harsimranb2-Apr-10 15:13 
GeneralRe: Captuing JSON Pin
harsimranb2-Apr-10 18:00
harsimranb2-Apr-10 18:00 
Questionsound card Pin
FlavioAR2-Apr-10 12:30
FlavioAR2-Apr-10 12:30 
AnswerRe: sound card Pin
DaveyM693-Apr-10 3:23
professionalDaveyM693-Apr-10 3:23 
QuestionCtrl+Z character in C# Pin
Kujtim Hyseni2-Apr-10 8:43
Kujtim Hyseni2-Apr-10 8:43 
AnswerRe: Ctrl+Z character in C# PinPopular
Ravi Bhavnani2-Apr-10 9:13
professionalRavi Bhavnani2-Apr-10 9:13 
GeneralRe: Ctrl+Z character in C# Pin
PIEBALDconsult2-Apr-10 10:03
mvePIEBALDconsult2-Apr-10 10:03 
GeneralRe: Ctrl+Z character in C# Pin
Ravi Bhavnani2-Apr-10 10:07
professionalRavi Bhavnani2-Apr-10 10:07 
GeneralRe: Ctrl+Z character in C# Pin
The Man from U.N.C.L.E.2-Apr-10 10:47
The Man from U.N.C.L.E.2-Apr-10 10:47 
GeneralRe: Ctrl+Z character in C# Pin
Khaniya2-Apr-10 18:33
professionalKhaniya2-Apr-10 18:33 
GeneralRe: Ctrl+Z character in C# Pin
Rajesh Anuhya2-Apr-10 22:23
professionalRajesh Anuhya2-Apr-10 22:23 
AnswerRe: Ctrl+Z character in C# Pin
Richard MacCutchan2-Apr-10 23:26
mveRichard MacCutchan2-Apr-10 23:26 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.