Darkmatter5's Profile User Rating: -----

Reputation: 0 Apprentice
Group:
New Members
Active Posts:
4 (0 per day)
Joined:
28-January 10
Profile Views:
418
Last Active:
User is offline Dec 06 2012 12:56 PM
Currently:
Offline

Previous Fields

Dream Kudos:
0

Latest Visitors

Icon   Darkmatter5 has not set their status

Posts I've Made

  1. In Topic: DbConnectionBuilder and class question

    Posted 6 Dec 2012

    Perfect it worked, however it had to be "BldrLocalDB.ConnectionString = XenoManager.Properties.Settings.Default.csLocalDB;"

    Thanks!
  2. In Topic: DbConnectionBuilder and class question

    Posted 6 Dec 2012

    Thank you for the reply, but I'm still trying to learn these concepts. Can you post some example code?
  3. In Topic: SQL Basics in C#

    Posted 7 Aug 2012

    I'm getting an error in the GetBindingsource function.

    It gets to the try/catch at da.Get(dtGet);

    The error says, "Error in GetBindingSource" "Fill: SelectCommand.Connection property has not been initialized."

    Here's my GetBindingSource code.

    public static BindingSource GetBindingSource(SqlCommand cmdSql)
    {
      BindingSource oBindingSource = new BindingSource();
      SqlDataAdapter daGet = new SqlDataAdapter(cmdSql);
      DataTable dtGet = new DataTable();
      cmdSql.CommandTimeout = 240;
      dtGet.Locale = System.Globalization.CultureInfo.InvariantCulture;
      try
      {
        daGet.Fill(dtGet);
      }
      catch (Exception ex)
      {
        MessageBox.Show(ex.Message, "Error in GetBindingSource");
        return null;
      }
      oBindingSource.DataSource = dtGet;
      return oBindingSource;
    }
    
    


    Any ideas?

My Information

Member Title:
New D.I.C Head
Age:
Age Unknown
Birthday:
Birthday Unknown
Gender:

Contact Information

E-mail:
Click here to e-mail me

Friends

Darkmatter5 hasn't added any friends yet.

Comments

Darkmatter5 has no profile comments yet. Why not say hello?