Showing posts with label windows. Show all posts
Showing posts with label windows. Show all posts

Thursday, March 29, 2012

error for sending(saving) data to database

Hi,

I’m using VS2005 and I’m trying to link the C# windows form to MSSQL. I used BindingNavigator Control to read the data. After that I add sqlcommand and sqldataadapter to send the data to the database. My code is this

sqlDataAdapter1.InsertCommand.CommandText =

"INSERT INTO SUDENT (" +

"S_ID, S_NAME, S_ADDRESS, S_PHONE" +

") VALUES ('" +

S_IDComboBox.Text +"', '" +

S_NAMETextBox.Text +"', '" +

S_ADDRESSTextBox.Text +"', '" +

S_PHONETextBox.Text +"')";

sqlDataAdapter1.InsertCommand.ExecuteNonQuery();

It gave me this error

NulleferenceException was Unhandled”and “ Object refrence not set to an instance of an object” so I add this line

sqlCommand1 = ("INSERT INTO STUDENT (S_ID,S_NAME,S_ADDRESS,S_PHONE) VALUES (@.S_ID,@.S_NAME,@.S_ADDRESS,@.S_PHONE)" ,sqlConnection1);

Then it gave me some stupid error. By the way it didn’t make a new object of SqlCommand although I tried ….

So can u help me to solve my problem ? Thank you

the first thing i noticed is "INSERT INTO SUDENT (" +

Spelling mistake

Madhu

|||Hi,

could you please send your whole code. As of now it seems that you did not initialize the DataAdapter object.

HTH, Jens K. Suessmeyer.

http://www.sqlserver2005.de
|||

Form1.designer.cs

namespace student

{

partialclassForm1

{

/// <summary>

/// Required designer variable.

/// </summary>

private System.ComponentModel.IContainer components = null;

/// <summary>

/// Clean up any resources being used.

/// </summary>

/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>

protectedoverridevoid Dispose(bool disposing)

{

if (disposing && (components != null))

{

components.Dispose();

}

base.Dispose(disposing);

}

#region Windows Form Designer generated code

/// <summary>

/// Required method for Designer support - do not modify

/// the contents of this method with the code editor.

/// </summary>

privatevoid InitializeComponent()

{

this.components = new System.ComponentModel.Container();

System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Form1));

System.Windows.Forms.Label s_IDLabel;

System.Windows.Forms.Label s_NAMELabel;

System.Windows.Forms.Label s_ADDRESSLabel;

System.Windows.Forms.Label s_PHONELabel;

this.studentDataSet = new student.studentDataSet();

this.sTUDENTBindingSource = new System.Windows.Forms.BindingSource(this.components);

this.sTUDENTTableAdapter = new student.studentDataSetTableAdapters.STUDENTTableAdapter();

this.sTUDENTBindingNavigator = new System.Windows.Forms.BindingNavigator(this.components);

this.bindingNavigatorMoveFirstItem = new System.Windows.Forms.ToolStripButton();

this.bindingNavigatorMovePreviousItem = new System.Windows.Forms.ToolStripButton();

this.bindingNavigatorSeparator = new System.Windows.Forms.ToolStripSeparator();

this.bindingNavigatorPositionItem = new System.Windows.Forms.ToolStripTextBox();

this.bindingNavigatorCountItem = new System.Windows.Forms.ToolStripLabel();

this.bindingNavigatorSeparator1 = new System.Windows.Forms.ToolStripSeparator();

this.bindingNavigatorMoveNextItem = new System.Windows.Forms.ToolStripButton();

this.bindingNavigatorMoveLastItem = new System.Windows.Forms.ToolStripButton();

this.bindingNavigatorSeparator2 = new System.Windows.Forms.ToolStripSeparator();

this.bindingNavigatorAddNewItem = new System.Windows.Forms.ToolStripButton();

this.bindingNavigatorDeleteItem = new System.Windows.Forms.ToolStripButton();

this.sTUDENTBindingNavigatorSaveItem = new System.Windows.Forms.ToolStripButton();

this.s_IDTextBox = new System.Windows.Forms.TextBox();

this.s_NAMETextBox = new System.Windows.Forms.TextBox();

this.s_ADDRESSTextBox = new System.Windows.Forms.TextBox();

this.s_PHONETextBox = new System.Windows.Forms.TextBox();

this.sqlConnection1 = new System.Data.SqlClient.SqlConnection();

this.sqlCommand1 = new System.Data.SqlClient.SqlCommand();

this.sqlSelectCommand1 = new System.Data.SqlClient.SqlCommand();

this.sqlInsertCommand1 = new System.Data.SqlClient.SqlCommand();

this.sqlDataAdapter1 = new System.Data.SqlClient.SqlDataAdapter();

s_IDLabel = new System.Windows.Forms.Label();

s_NAMELabel = new System.Windows.Forms.Label();

s_ADDRESSLabel = new System.Windows.Forms.Label();

s_PHONELabel = new System.Windows.Forms.Label();

((System.ComponentModel.ISupportInitialize)(this.studentDataSet)).BeginInit();

((System.ComponentModel.ISupportInitialize)(this.sTUDENTBindingSource)).BeginInit();

((System.ComponentModel.ISupportInitialize)(this.sTUDENTBindingNavigator)).BeginInit();

this.sTUDENTBindingNavigator.SuspendLayout();

this.SuspendLayout();

//

// studentDataSet

//

this.studentDataSet.DataSetName = "studentDataSet";

this.studentDataSet.SchemaSerializationMode = System.Data.SchemaSerializationMode.IncludeSchema;

//

// sTUDENTBindingSource

//

this.sTUDENTBindingSource.DataMember = "STUDENT";

this.sTUDENTBindingSource.DataSource = this.studentDataSet;

//

// sTUDENTTableAdapter

//

this.sTUDENTTableAdapter.ClearBeforeFill = true;

//

// sTUDENTBindingNavigator

//

this.sTUDENTBindingNavigator.AddNewItem = this.bindingNavigatorAddNewItem;

this.sTUDENTBindingNavigator.BindingSource = this.sTUDENTBindingSource;

this.sTUDENTBindingNavigator.CountItem = this.bindingNavigatorCountItem;

this.sTUDENTBindingNavigator.DeleteItem = this.bindingNavigatorDeleteItem;

this.sTUDENTBindingNavigator.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {

this.bindingNavigatorMoveFirstItem,

this.bindingNavigatorMovePreviousItem,

this.bindingNavigatorSeparator,

this.bindingNavigatorPositionItem,

this.bindingNavigatorCountItem,

this.bindingNavigatorSeparator1,

this.bindingNavigatorMoveNextItem,

this.bindingNavigatorMoveLastItem,

this.bindingNavigatorSeparator2,

this.bindingNavigatorAddNewItem,

this.bindingNavigatorDeleteItem,

this.sTUDENTBindingNavigatorSaveItem});

this.sTUDENTBindingNavigator.Location = new System.Drawing.Point(0, 0);

this.sTUDENTBindingNavigator.MoveFirstItem = this.bindingNavigatorMoveFirstItem;

this.sTUDENTBindingNavigator.MoveLastItem = this.bindingNavigatorMoveLastItem;

this.sTUDENTBindingNavigator.MoveNextItem = this.bindingNavigatorMoveNextItem;

this.sTUDENTBindingNavigator.MovePreviousItem = this.bindingNavigatorMovePreviousItem;

this.sTUDENTBindingNavigator.Name = "sTUDENTBindingNavigator";

this.sTUDENTBindingNavigator.PositionItem = this.bindingNavigatorPositionItem;

this.sTUDENTBindingNavigator.Size = new System.Drawing.Size(463, 25);

this.sTUDENTBindingNavigator.TabIndex = 0;

this.sTUDENTBindingNavigator.Text = "bindingNavigator1";

//

// bindingNavigatorMoveFirstItem

//

this.bindingNavigatorMoveFirstItem.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;

this.bindingNavigatorMoveFirstItem.Image = ((System.Drawing.Image)(resources.GetObject("bindingNavigatorMoveFirstItem.Image")));

this.bindingNavigatorMoveFirstItem.Name = "bindingNavigatorMoveFirstItem";

this.bindingNavigatorMoveFirstItem.RightToLeftAutoMirrorImage = true;

this.bindingNavigatorMoveFirstItem.Size = new System.Drawing.Size(23, 22);

this.bindingNavigatorMoveFirstItem.Text = "Move first";

//

// bindingNavigatorMovePreviousItem

//

this.bindingNavigatorMovePreviousItem.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;

this.bindingNavigatorMovePreviousItem.Image = ((System.Drawing.Image)(resources.GetObject("bindingNavigatorMovePreviousItem.Image")));

this.bindingNavigatorMovePreviousItem.Name = "bindingNavigatorMovePreviousItem";

this.bindingNavigatorMovePreviousItem.RightToLeftAutoMirrorImage = true;

this.bindingNavigatorMovePreviousItem.Size = new System.Drawing.Size(23, 22);

this.bindingNavigatorMovePreviousItem.Text = "Move previous";

//

// bindingNavigatorSeparator

//

this.bindingNavigatorSeparator.Name = "bindingNavigatorSeparator";

this.bindingNavigatorSeparator.Size = new System.Drawing.Size(6, 25);

//

// bindingNavigatorPositionItem

//

this.bindingNavigatorPositionItem.AccessibleName = "Position";

this.bindingNavigatorPositionItem.AutoSize = false;

this.bindingNavigatorPositionItem.Name = "bindingNavigatorPositionItem";

this.bindingNavigatorPositionItem.Size = new System.Drawing.Size(50, 21);

this.bindingNavigatorPositionItem.Text = "0";

this.bindingNavigatorPositionItem.ToolTipText = "Current position";

//

// bindingNavigatorCountItem

//

this.bindingNavigatorCountItem.Name = "bindingNavigatorCountItem";

this.bindingNavigatorCountItem.Size = new System.Drawing.Size(36, 22);

this.bindingNavigatorCountItem.Text = "of {0}";

this.bindingNavigatorCountItem.ToolTipText = "Total number of items";

//

// bindingNavigatorSeparator1

//

this.bindingNavigatorSeparator1.Name = "bindingNavigatorSeparator";

this.bindingNavigatorSeparator1.Size = new System.Drawing.Size(6, 25);

//

// bindingNavigatorMoveNextItem

//

this.bindingNavigatorMoveNextItem.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;

this.bindingNavigatorMoveNextItem.Image = ((System.Drawing.Image)(resources.GetObject("bindingNavigatorMoveNextItem.Image")));

this.bindingNavigatorMoveNextItem.Name = "bindingNavigatorMoveNextItem";

this.bindingNavigatorMoveNextItem.RightToLeftAutoMirrorImage = true;

this.bindingNavigatorMoveNextItem.Size = new System.Drawing.Size(23, 22);

this.bindingNavigatorMoveNextItem.Text = "Move next";

//

// bindingNavigatorMoveLastItem

//

this.bindingNavigatorMoveLastItem.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;

this.bindingNavigatorMoveLastItem.Image = ((System.Drawing.Image)(resources.GetObject("bindingNavigatorMoveLastItem.Image")));

this.bindingNavigatorMoveLastItem.Name = "bindingNavigatorMoveLastItem";

this.bindingNavigatorMoveLastItem.RightToLeftAutoMirrorImage = true;

this.bindingNavigatorMoveLastItem.Size = new System.Drawing.Size(23, 22);

this.bindingNavigatorMoveLastItem.Text = "Move last";

//

// bindingNavigatorSeparator2

//

this.bindingNavigatorSeparator2.Name = "bindingNavigatorSeparator";

this.bindingNavigatorSeparator2.Size = new System.Drawing.Size(6, 25);

//

// bindingNavigatorAddNewItem

//

this.bindingNavigatorAddNewItem.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;

this.bindingNavigatorAddNewItem.Image = ((System.Drawing.Image)(resources.GetObject("bindingNavigatorAddNewItem.Image")));

this.bindingNavigatorAddNewItem.Name = "bindingNavigatorAddNewItem";

this.bindingNavigatorAddNewItem.RightToLeftAutoMirrorImage = true;

this.bindingNavigatorAddNewItem.Size = new System.Drawing.Size(23, 22);

this.bindingNavigatorAddNewItem.Text = "Add new";

//

// bindingNavigatorDeleteItem

//

this.bindingNavigatorDeleteItem.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;

this.bindingNavigatorDeleteItem.Image = ((System.Drawing.Image)(resources.GetObject("bindingNavigatorDeleteItem.Image")));

this.bindingNavigatorDeleteItem.Name = "bindingNavigatorDeleteItem";

this.bindingNavigatorDeleteItem.RightToLeftAutoMirrorImage = true;

this.bindingNavigatorDeleteItem.Size = new System.Drawing.Size(23, 22);

this.bindingNavigatorDeleteItem.Text = "Delete";

//

// sTUDENTBindingNavigatorSaveItem

//

this.sTUDENTBindingNavigatorSaveItem.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;

this.sTUDENTBindingNavigatorSaveItem.Image = ((System.Drawing.Image)(resources.GetObject("sTUDENTBindingNavigatorSaveItem.Image")));

this.sTUDENTBindingNavigatorSaveItem.Name = "sTUDENTBindingNavigatorSaveItem";

this.sTUDENTBindingNavigatorSaveItem.Size = new System.Drawing.Size(23, 22);

this.sTUDENTBindingNavigatorSaveItem.Text = "Save Data";

this.sTUDENTBindingNavigatorSaveItem.Click += new System.EventHandler(this.sTUDENTBindingNavigatorSaveItem_Click);

//

// s_IDLabel

//

s_IDLabel.AutoSize = true;

s_IDLabel.Location = new System.Drawing.Point(44, 52);

s_IDLabel.Name = "s_IDLabel";

s_IDLabel.Size = new System.Drawing.Size(31, 13);

s_IDLabel.TabIndex = 1;

s_IDLabel.Text = "S ID:";

//

// s_IDTextBox

//

this.s_IDTextBox.DataBindings.Add(new System.Windows.Forms.Binding("Text", this.sTUDENTBindingSource, "S_ID", true));

this.s_IDTextBox.Location = new System.Drawing.Point(81, 49);

this.s_IDTextBox.Name = "s_IDTextBox";

this.s_IDTextBox.Size = new System.Drawing.Size(100, 20);

this.s_IDTextBox.TabIndex = 2;

//

// s_NAMELabel

//

s_NAMELabel.AutoSize = true;

s_NAMELabel.Location = new System.Drawing.Point(51, 91);

s_NAMELabel.Name = "s_NAMELabel";

s_NAMELabel.Size = new System.Drawing.Size(51, 13);

s_NAMELabel.TabIndex = 3;

s_NAMELabel.Text = "S NAME:";

//

// s_NAMETextBox

//

this.s_NAMETextBox.DataBindings.Add(new System.Windows.Forms.Binding("Text", this.sTUDENTBindingSource, "S_NAME", true));

this.s_NAMETextBox.Location = new System.Drawing.Point(108, 88);

this.s_NAMETextBox.Name = "s_NAMETextBox";

this.s_NAMETextBox.Size = new System.Drawing.Size(100, 20);

this.s_NAMETextBox.TabIndex = 4;

//

// s_ADDRESSLabel

//

s_ADDRESSLabel.AutoSize = true;

s_ADDRESSLabel.Location = new System.Drawing.Point(49, 122);

s_ADDRESSLabel.Name = "s_ADDRESSLabel";

s_ADDRESSLabel.Size = new System.Drawing.Size(72, 13);

s_ADDRESSLabel.TabIndex = 5;

s_ADDRESSLabel.Text = "S ADDRESS:";

//

// s_ADDRESSTextBox

//

this.s_ADDRESSTextBox.DataBindings.Add(new System.Windows.Forms.Binding("Text", this.sTUDENTBindingSource, "S_ADDRESS", true));

this.s_ADDRESSTextBox.Location = new System.Drawing.Point(127, 119);

this.s_ADDRESSTextBox.Name = "s_ADDRESSTextBox";

this.s_ADDRESSTextBox.Size = new System.Drawing.Size(100, 20);

this.s_ADDRESSTextBox.TabIndex = 6;

//

// s_PHONELabel

//

s_PHONELabel.AutoSize = true;

s_PHONELabel.Location = new System.Drawing.Point(77, 160);

s_PHONELabel.Name = "s_PHONELabel";

s_PHONELabel.Size = new System.Drawing.Size(58, 13);

s_PHONELabel.TabIndex = 7;

s_PHONELabel.Text = "S PHONE:";

//

// s_PHONETextBox

//

this.s_PHONETextBox.DataBindings.Add(new System.Windows.Forms.Binding("Text", this.sTUDENTBindingSource, "S_PHONE", true));

this.s_PHONETextBox.Location = new System.Drawing.Point(141, 157);

this.s_PHONETextBox.Name = "s_PHONETextBox";

this.s_PHONETextBox.Size = new System.Drawing.Size(100, 20);

this.s_PHONETextBox.TabIndex = 8;

//

// sqlConnection1

//

this.sqlConnection1.ConnectionString = "Data Source=.\\SQLEXPRESS;AttachDbFilename=\"C:\\Documents and Settings\\Glad\\Desktop" +

"\\student\\student\\student.mdf\";Integrated Security=True;User Instance=True";

this.sqlConnection1.FireInfoMessageEventOnUserErrors = true;

this.sqlConnection1.StatisticsEnabled = true;

//

// sqlCommand1

//

this.sqlCommand1.Parameters.AddRange(new System.Data.SqlClient.SqlParameter[] {

new System.Data.SqlClient.SqlParameter("@.S_ID", System.Data.SqlDbType.Int, 0, System.Data.ParameterDirection.Output, false, ((byte)(0)), ((byte)(0)), "", System.Data.DataRowVersion.Current, null),

new System.Data.SqlClient.SqlParameter("@.S_NAME", System.Data.SqlDbType.VarChar),

new System.Data.SqlClient.SqlParameter("@.S_ADDRESS", System.Data.SqlDbType.VarChar),

new System.Data.SqlClient.SqlParameter("@.S_PHONE", System.Data.SqlDbType.Text)});

//

// sqlSelectCommand1

//

this.sqlSelectCommand1.CommandText = "SELECT S_ID, S_NAME, S_ADDRESS, S_PHONE\r\nFROM STUDENT";

this.sqlSelectCommand1.Connection = this.sqlConnection1;

//

// sqlInsertCommand1

//

this.sqlInsertCommand1.CommandText = "INSERT INTO [STUDENT] ([S_ID], [S_NAME], [S_ADDRESS], [S_PHONE]) VALUES (@.S_ID, @." +

"S_NAME, @.S_ADDRESS, @.S_PHONE)";

this.sqlInsertCommand1.Connection = this.sqlConnection1;

this.sqlInsertCommand1.Parameters.AddRange(new System.Data.SqlClient.SqlParameter[] {

new System.Data.SqlClient.SqlParameter("@.S_ID", System.Data.SqlDbType.Int, 0, "S_ID"),

new System.Data.SqlClient.SqlParameter("@.S_NAME", System.Data.SqlDbType.VarChar, 0, "S_NAME"),

new System.Data.SqlClient.SqlParameter("@.S_ADDRESS", System.Data.SqlDbType.VarChar, 0, "S_ADDRESS"),

new System.Data.SqlClient.SqlParameter("@.S_PHONE", System.Data.SqlDbType.Text, 0, "S_PHONE")});

//

// sqlDataAdapter1

//

this.sqlDataAdapter1.InsertCommand = this.sqlInsertCommand1;

this.sqlDataAdapter1.SelectCommand = this.sqlSelectCommand1;

this.sqlDataAdapter1.TableMappings.AddRange(new System.Data.Common.DataTableMapping[] {

new System.Data.Common.DataTableMapping("Table", "STUDENT", new System.Data.Common.DataColumnMapping[] {

new System.Data.Common.DataColumnMapping("S_ID", "S_ID"),

new System.Data.Common.DataColumnMapping("S_NAME", "S_NAME"),

new System.Data.Common.DataColumnMapping("S_ADDRESS", "S_ADDRESS"),

new System.Data.Common.DataColumnMapping("S_PHONE", "S_PHONE")})});

//

// Form1

//

this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);

this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;

this.ClientSize = new System.Drawing.Size(463, 266);

this.Controls.Add(s_PHONELabel);

this.Controls.Add(this.s_PHONETextBox);

this.Controls.Add(s_ADDRESSLabel);

this.Controls.Add(this.s_ADDRESSTextBox);

this.Controls.Add(s_NAMELabel);

this.Controls.Add(this.s_NAMETextBox);

this.Controls.Add(s_IDLabel);

this.Controls.Add(this.s_IDTextBox);

this.Controls.Add(this.sTUDENTBindingNavigator);

this.Name = "Form1";

this.Text = "Form1";

this.Load += new System.EventHandler(this.Form1_Load);

((System.ComponentModel.ISupportInitialize)(this.studentDataSet)).EndInit();

((System.ComponentModel.ISupportInitialize)(this.sTUDENTBindingSource)).EndInit();

((System.ComponentModel.ISupportInitialize)(this.sTUDENTBindingNavigator)).EndInit();

this.sTUDENTBindingNavigator.ResumeLayout(false);

this.sTUDENTBindingNavigator.PerformLayout();

this.ResumeLayout(false);

this.PerformLayout();

}

#endregion

privatestudentDataSet studentDataSet;

private System.Windows.Forms.BindingSource sTUDENTBindingSource;

private student.studentDataSetTableAdapters.STUDENTTableAdapter sTUDENTTableAdapter;

private System.Windows.Forms.BindingNavigator sTUDENTBindingNavigator;

private System.Windows.Forms.ToolStripButton bindingNavigatorAddNewItem;

private System.Windows.Forms.ToolStripLabel bindingNavigatorCountItem;

private System.Windows.Forms.ToolStripButton bindingNavigatorDeleteItem;

private System.Windows.Forms.ToolStripButton bindingNavigatorMoveFirstItem;

private System.Windows.Forms.ToolStripButton bindingNavigatorMovePreviousItem;

private System.Windows.Forms.ToolStripSeparator bindingNavigatorSeparator;

private System.Windows.Forms.ToolStripTextBox bindingNavigatorPositionItem;

private System.Windows.Forms.ToolStripSeparator bindingNavigatorSeparator1;

private System.Windows.Forms.ToolStripButton bindingNavigatorMoveNextItem;

private System.Windows.Forms.ToolStripButton bindingNavigatorMoveLastItem;

private System.Windows.Forms.ToolStripSeparator bindingNavigatorSeparator2;

private System.Windows.Forms.ToolStripButton sTUDENTBindingNavigatorSaveItem;

private System.Windows.Forms.TextBox s_IDTextBox;

private System.Windows.Forms.TextBox s_NAMETextBox;

private System.Windows.Forms.TextBox s_ADDRESSTextBox;

private System.Windows.Forms.TextBox s_PHONETextBox;

private System.Data.SqlClient.SqlConnection sqlConnection1;

private System.Data.SqlClient.SqlCommand sqlCommand1;

private System.Data.SqlClient.SqlCommand sqlSelectCommand1;

private System.Data.SqlClient.SqlCommand sqlInsertCommand1;

private System.Data.SqlClient.SqlDataAdapter sqlDataAdapter1;

}

}

///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

form1.cs

using System;

using System.Collections.Generic;

using System.ComponentModel;

using System.Data;

using System.Data.SqlClient;

using System.Drawing;

using System.Text;

using System.Windows.Forms;

namespace student

{

publicpartialclassForm1 : Form

{

public Form1()

{

InitializeComponent();

}

privatevoid sTUDENTBindingNavigatorSaveItem_Click(object sender, EventArgs e)

{

sqlConnection1.Open();

sqlDataAdapter1.InsertCommand.CommandText=

"INSERT INTO STUDENT (" +

"S_ID, S_NAME, S_ADDRESS, S_PHONE" +

") VALUES ('" +

s_IDTextBox.Text + "', '" +

s_NAMETextBox.Text + "', '" +

s_ADDRESSTextBox.Text + "', '" +

s_PHONETextBox.Text + "')";

sqlDataAdapter1.InsertCommand.ExecuteNonQuery();

sqlConnection1.Close();

this.Validate();

this.sTUDENTBindingSource.EndEdit();

this.sTUDENTTableAdapter.Update(this.studentDataSet.STUDENT);

}

privatevoid Form1_Load(object sender, EventArgs e)

{

this.sTUDENTTableAdapter.Fill(this.studentDataSet.STUDENT);

}

}

}

|||Does the problem still exist ?

Jens K. Suessmeyer.

http://www.sqlserver2005.de

error for sending(saving) data to database

Hi,

I’m using VS2005 and I’m trying to link the C# windows form to MSSQL. I used BindingNavigator Control to read the data. After that I add sqlcommand and sqldataadapter to send the data to the database. My code is this

sqlDataAdapter1.InsertCommand.CommandText =

"INSERT INTO SUDENT (" +

"S_ID, S_NAME, S_ADDRESS, S_PHONE" +

") VALUES ('" +

S_IDComboBox.Text + "', '" +

S_NAMETextBox.Text + "', '" +

S_ADDRESSTextBox.Text + "', '" +

S_PHONETextBox.Text + "')";

sqlDataAdapter1.InsertCommand.ExecuteNonQuery();

It gave me this error

NulleferenceException was Unhandled”and “ Object refrence not set to an instance of an object” so I add this line

sqlCommand1 = ("INSERT INTO STUDENT (S_ID,S_NAME,S_ADDRESS,S_PHONE) VALUES (@.S_ID,@.S_NAME,@.S_ADDRESS,@.S_PHONE)" ,sqlConnection1);

Then it gave me some stupid error. By the way it didn’t make a new object of SqlCommand although I tried ….

So can u help me to solve my problem ? Thank you

the first thing i noticed is "INSERT INTO SUDENT (" +

Spelling mistake

Madhu

|||Hi,

could you please send your whole code. As of now it seems that you did not initialize the DataAdapter object.

HTH, Jens K. Suessmeyer.

http://www.sqlserver2005.de|||

Form1.designer.cs

namespace student

{

partial class Form1

{

/// <summary>

/// Required designer variable.

/// </summary>

private System.ComponentModel.IContainer components = null;

/// <summary>

/// Clean up any resources being used.

/// </summary>

/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>

protected override void Dispose(bool disposing)

{

if (disposing && (components != null))

{

components.Dispose();

}

base.Dispose(disposing);

}

#region Windows Form Designer generated code

/// <summary>

/// Required method for Designer support - do not modify

/// the contents of this method with the code editor.

/// </summary>

private void InitializeComponent()

{

this.components = new System.ComponentModel.Container();

System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Form1));

System.Windows.Forms.Label s_IDLabel;

System.Windows.Forms.Label s_NAMELabel;

System.Windows.Forms.Label s_ADDRESSLabel;

System.Windows.Forms.Label s_PHONELabel;

this.studentDataSet = new student.studentDataSet();

this.sTUDENTBindingSource = new System.Windows.Forms.BindingSource(this.components);

this.sTUDENTTableAdapter = new student.studentDataSetTableAdapters.STUDENTTableAdapter();

this.sTUDENTBindingNavigator = new System.Windows.Forms.BindingNavigator(this.components);

this.bindingNavigatorMoveFirstItem = new System.Windows.Forms.ToolStripButton();

this.bindingNavigatorMovePreviousItem = new System.Windows.Forms.ToolStripButton();

this.bindingNavigatorSeparator = new System.Windows.Forms.ToolStripSeparator();

this.bindingNavigatorPositionItem = new System.Windows.Forms.ToolStripTextBox();

this.bindingNavigatorCountItem = new System.Windows.Forms.ToolStripLabel();

this.bindingNavigatorSeparator1 = new System.Windows.Forms.ToolStripSeparator();

this.bindingNavigatorMoveNextItem = new System.Windows.Forms.ToolStripButton();

this.bindingNavigatorMoveLastItem = new System.Windows.Forms.ToolStripButton();

this.bindingNavigatorSeparator2 = new System.Windows.Forms.ToolStripSeparator();

this.bindingNavigatorAddNewItem = new System.Windows.Forms.ToolStripButton();

this.bindingNavigatorDeleteItem = new System.Windows.Forms.ToolStripButton();

this.sTUDENTBindingNavigatorSaveItem = new System.Windows.Forms.ToolStripButton();

this.s_IDTextBox = new System.Windows.Forms.TextBox();

this.s_NAMETextBox = new System.Windows.Forms.TextBox();

this.s_ADDRESSTextBox = new System.Windows.Forms.TextBox();

this.s_PHONETextBox = new System.Windows.Forms.TextBox();

this.sqlConnection1 = new System.Data.SqlClient.SqlConnection();

this.sqlCommand1 = new System.Data.SqlClient.SqlCommand();

this.sqlSelectCommand1 = new System.Data.SqlClient.SqlCommand();

this.sqlInsertCommand1 = new System.Data.SqlClient.SqlCommand();

this.sqlDataAdapter1 = new System.Data.SqlClient.SqlDataAdapter();

s_IDLabel = new System.Windows.Forms.Label();

s_NAMELabel = new System.Windows.Forms.Label();

s_ADDRESSLabel = new System.Windows.Forms.Label();

s_PHONELabel = new System.Windows.Forms.Label();

((System.ComponentModel.ISupportInitialize)(this.studentDataSet)).BeginInit();

((System.ComponentModel.ISupportInitialize)(this.sTUDENTBindingSource)).BeginInit();

((System.ComponentModel.ISupportInitialize)(this.sTUDENTBindingNavigator)).BeginInit();

this.sTUDENTBindingNavigator.SuspendLayout();

this.SuspendLayout();

//

// studentDataSet

//

this.studentDataSet.DataSetName = "studentDataSet";

this.studentDataSet.SchemaSerializationMode = System.Data.SchemaSerializationMode.IncludeSchema;

//

// sTUDENTBindingSource

//

this.sTUDENTBindingSource.DataMember = "STUDENT";

this.sTUDENTBindingSource.DataSource = this.studentDataSet;

//

// sTUDENTTableAdapter

//

this.sTUDENTTableAdapter.ClearBeforeFill = true;

//

// sTUDENTBindingNavigator

//

this.sTUDENTBindingNavigator.AddNewItem = this.bindingNavigatorAddNewItem;

this.sTUDENTBindingNavigator.BindingSource = this.sTUDENTBindingSource;

this.sTUDENTBindingNavigator.CountItem = this.bindingNavigatorCountItem;

this.sTUDENTBindingNavigator.DeleteItem = this.bindingNavigatorDeleteItem;

this.sTUDENTBindingNavigator.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {

this.bindingNavigatorMoveFirstItem,

this.bindingNavigatorMovePreviousItem,

this.bindingNavigatorSeparator,

this.bindingNavigatorPositionItem,

this.bindingNavigatorCountItem,

this.bindingNavigatorSeparator1,

this.bindingNavigatorMoveNextItem,

this.bindingNavigatorMoveLastItem,

this.bindingNavigatorSeparator2,

this.bindingNavigatorAddNewItem,

this.bindingNavigatorDeleteItem,

this.sTUDENTBindingNavigatorSaveItem});

this.sTUDENTBindingNavigator.Location = new System.Drawing.Point(0, 0);

this.sTUDENTBindingNavigator.MoveFirstItem = this.bindingNavigatorMoveFirstItem;

this.sTUDENTBindingNavigator.MoveLastItem = this.bindingNavigatorMoveLastItem;

this.sTUDENTBindingNavigator.MoveNextItem = this.bindingNavigatorMoveNextItem;

this.sTUDENTBindingNavigator.MovePreviousItem = this.bindingNavigatorMovePreviousItem;

this.sTUDENTBindingNavigator.Name = "sTUDENTBindingNavigator";

this.sTUDENTBindingNavigator.PositionItem = this.bindingNavigatorPositionItem;

this.sTUDENTBindingNavigator.Size = new System.Drawing.Size(463, 25);

this.sTUDENTBindingNavigator.TabIndex = 0;

this.sTUDENTBindingNavigator.Text = "bindingNavigator1";

//

// bindingNavigatorMoveFirstItem

//

this.bindingNavigatorMoveFirstItem.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;

this.bindingNavigatorMoveFirstItem.Image = ((System.Drawing.Image)(resources.GetObject("bindingNavigatorMoveFirstItem.Image")));

this.bindingNavigatorMoveFirstItem.Name = "bindingNavigatorMoveFirstItem";

this.bindingNavigatorMoveFirstItem.RightToLeftAutoMirrorImage = true;

this.bindingNavigatorMoveFirstItem.Size = new System.Drawing.Size(23, 22);

this.bindingNavigatorMoveFirstItem.Text = "Move first";

//

// bindingNavigatorMovePreviousItem

//

this.bindingNavigatorMovePreviousItem.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;

this.bindingNavigatorMovePreviousItem.Image = ((System.Drawing.Image)(resources.GetObject("bindingNavigatorMovePreviousItem.Image")));

this.bindingNavigatorMovePreviousItem.Name = "bindingNavigatorMovePreviousItem";

this.bindingNavigatorMovePreviousItem.RightToLeftAutoMirrorImage = true;

this.bindingNavigatorMovePreviousItem.Size = new System.Drawing.Size(23, 22);

this.bindingNavigatorMovePreviousItem.Text = "Move previous";

//

// bindingNavigatorSeparator

//

this.bindingNavigatorSeparator.Name = "bindingNavigatorSeparator";

this.bindingNavigatorSeparator.Size = new System.Drawing.Size(6, 25);

//

// bindingNavigatorPositionItem

//

this.bindingNavigatorPositionItem.AccessibleName = "Position";

this.bindingNavigatorPositionItem.AutoSize = false;

this.bindingNavigatorPositionItem.Name = "bindingNavigatorPositionItem";

this.bindingNavigatorPositionItem.Size = new System.Drawing.Size(50, 21);

this.bindingNavigatorPositionItem.Text = "0";

this.bindingNavigatorPositionItem.ToolTipText = "Current position";

//

// bindingNavigatorCountItem

//

this.bindingNavigatorCountItem.Name = "bindingNavigatorCountItem";

this.bindingNavigatorCountItem.Size = new System.Drawing.Size(36, 22);

this.bindingNavigatorCountItem.Text = "of {0}";

this.bindingNavigatorCountItem.ToolTipText = "Total number of items";

//

// bindingNavigatorSeparator1

//

this.bindingNavigatorSeparator1.Name = "bindingNavigatorSeparator";

this.bindingNavigatorSeparator1.Size = new System.Drawing.Size(6, 25);

//

// bindingNavigatorMoveNextItem

//

this.bindingNavigatorMoveNextItem.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;

this.bindingNavigatorMoveNextItem.Image = ((System.Drawing.Image)(resources.GetObject("bindingNavigatorMoveNextItem.Image")));

this.bindingNavigatorMoveNextItem.Name = "bindingNavigatorMoveNextItem";

this.bindingNavigatorMoveNextItem.RightToLeftAutoMirrorImage = true;

this.bindingNavigatorMoveNextItem.Size = new System.Drawing.Size(23, 22);

this.bindingNavigatorMoveNextItem.Text = "Move next";

//

// bindingNavigatorMoveLastItem

//

this.bindingNavigatorMoveLastItem.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;

this.bindingNavigatorMoveLastItem.Image = ((System.Drawing.Image)(resources.GetObject("bindingNavigatorMoveLastItem.Image")));

this.bindingNavigatorMoveLastItem.Name = "bindingNavigatorMoveLastItem";

this.bindingNavigatorMoveLastItem.RightToLeftAutoMirrorImage = true;

this.bindingNavigatorMoveLastItem.Size = new System.Drawing.Size(23, 22);

this.bindingNavigatorMoveLastItem.Text = "Move last";

//

// bindingNavigatorSeparator2

//

this.bindingNavigatorSeparator2.Name = "bindingNavigatorSeparator";

this.bindingNavigatorSeparator2.Size = new System.Drawing.Size(6, 25);

//

// bindingNavigatorAddNewItem

//

this.bindingNavigatorAddNewItem.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;

this.bindingNavigatorAddNewItem.Image = ((System.Drawing.Image)(resources.GetObject("bindingNavigatorAddNewItem.Image")));

this.bindingNavigatorAddNewItem.Name = "bindingNavigatorAddNewItem";

this.bindingNavigatorAddNewItem.RightToLeftAutoMirrorImage = true;

this.bindingNavigatorAddNewItem.Size = new System.Drawing.Size(23, 22);

this.bindingNavigatorAddNewItem.Text = "Add new";

//

// bindingNavigatorDeleteItem

//

this.bindingNavigatorDeleteItem.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;

this.bindingNavigatorDeleteItem.Image = ((System.Drawing.Image)(resources.GetObject("bindingNavigatorDeleteItem.Image")));

this.bindingNavigatorDeleteItem.Name = "bindingNavigatorDeleteItem";

this.bindingNavigatorDeleteItem.RightToLeftAutoMirrorImage = true;

this.bindingNavigatorDeleteItem.Size = new System.Drawing.Size(23, 22);

this.bindingNavigatorDeleteItem.Text = "Delete";

//

// sTUDENTBindingNavigatorSaveItem

//

this.sTUDENTBindingNavigatorSaveItem.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;

this.sTUDENTBindingNavigatorSaveItem.Image = ((System.Drawing.Image)(resources.GetObject("sTUDENTBindingNavigatorSaveItem.Image")));

this.sTUDENTBindingNavigatorSaveItem.Name = "sTUDENTBindingNavigatorSaveItem";

this.sTUDENTBindingNavigatorSaveItem.Size = new System.Drawing.Size(23, 22);

this.sTUDENTBindingNavigatorSaveItem.Text = "Save Data";

this.sTUDENTBindingNavigatorSaveItem.Click += new System.EventHandler(this.sTUDENTBindingNavigatorSaveItem_Click);

//

// s_IDLabel

//

s_IDLabel.AutoSize = true;

s_IDLabel.Location = new System.Drawing.Point(44, 52);

s_IDLabel.Name = "s_IDLabel";

s_IDLabel.Size = new System.Drawing.Size(31, 13);

s_IDLabel.TabIndex = 1;

s_IDLabel.Text = "S ID:";

//

// s_IDTextBox

//

this.s_IDTextBox.DataBindings.Add(new System.Windows.Forms.Binding("Text", this.sTUDENTBindingSource, "S_ID", true));

this.s_IDTextBox.Location = new System.Drawing.Point(81, 49);

this.s_IDTextBox.Name = "s_IDTextBox";

this.s_IDTextBox.Size = new System.Drawing.Size(100, 20);

this.s_IDTextBox.TabIndex = 2;

//

// s_NAMELabel

//

s_NAMELabel.AutoSize = true;

s_NAMELabel.Location = new System.Drawing.Point(51, 91);

s_NAMELabel.Name = "s_NAMELabel";

s_NAMELabel.Size = new System.Drawing.Size(51, 13);

s_NAMELabel.TabIndex = 3;

s_NAMELabel.Text = "S NAME:";

//

// s_NAMETextBox

//

this.s_NAMETextBox.DataBindings.Add(new System.Windows.Forms.Binding("Text", this.sTUDENTBindingSource, "S_NAME", true));

this.s_NAMETextBox.Location = new System.Drawing.Point(108, 88);

this.s_NAMETextBox.Name = "s_NAMETextBox";

this.s_NAMETextBox.Size = new System.Drawing.Size(100, 20);

this.s_NAMETextBox.TabIndex = 4;

//

// s_ADDRESSLabel

//

s_ADDRESSLabel.AutoSize = true;

s_ADDRESSLabel.Location = new System.Drawing.Point(49, 122);

s_ADDRESSLabel.Name = "s_ADDRESSLabel";

s_ADDRESSLabel.Size = new System.Drawing.Size(72, 13);

s_ADDRESSLabel.TabIndex = 5;

s_ADDRESSLabel.Text = "S ADDRESS:";

//

// s_ADDRESSTextBox

//

this.s_ADDRESSTextBox.DataBindings.Add(new System.Windows.Forms.Binding("Text", this.sTUDENTBindingSource, "S_ADDRESS", true));

this.s_ADDRESSTextBox.Location = new System.Drawing.Point(127, 119);

this.s_ADDRESSTextBox.Name = "s_ADDRESSTextBox";

this.s_ADDRESSTextBox.Size = new System.Drawing.Size(100, 20);

this.s_ADDRESSTextBox.TabIndex = 6;

//

// s_PHONELabel

//

s_PHONELabel.AutoSize = true;

s_PHONELabel.Location = new System.Drawing.Point(77, 160);

s_PHONELabel.Name = "s_PHONELabel";

s_PHONELabel.Size = new System.Drawing.Size(58, 13);

s_PHONELabel.TabIndex = 7;

s_PHONELabel.Text = "S PHONE:";

//

// s_PHONETextBox

//

this.s_PHONETextBox.DataBindings.Add(new System.Windows.Forms.Binding("Text", this.sTUDENTBindingSource, "S_PHONE", true));

this.s_PHONETextBox.Location = new System.Drawing.Point(141, 157);

this.s_PHONETextBox.Name = "s_PHONETextBox";

this.s_PHONETextBox.Size = new System.Drawing.Size(100, 20);

this.s_PHONETextBox.TabIndex = 8;

//

// sqlConnection1

//

this.sqlConnection1.ConnectionString = "Data Source=.\\SQLEXPRESS;AttachDbFilename=\"C:\\Documents and Settings\\Glad\\Desktop" +

"\\student\\student\\student.mdf\";Integrated Security=True;User Instance=True";

this.sqlConnection1.FireInfoMessageEventOnUserErrors = true;

this.sqlConnection1.StatisticsEnabled = true;

//

// sqlCommand1

//

this.sqlCommand1.Parameters.AddRange(new System.Data.SqlClient.SqlParameter[] {

new System.Data.SqlClient.SqlParameter("@.S_ID", System.Data.SqlDbType.Int, 0, System.Data.ParameterDirection.Output, false, ((byte)(0)), ((byte)(0)), "", System.Data.DataRowVersion.Current, null),

new System.Data.SqlClient.SqlParameter("@.S_NAME", System.Data.SqlDbType.VarChar),

new System.Data.SqlClient.SqlParameter("@.S_ADDRESS", System.Data.SqlDbType.VarChar),

new System.Data.SqlClient.SqlParameter("@.S_PHONE", System.Data.SqlDbType.Text)});

//

// sqlSelectCommand1

//

this.sqlSelectCommand1.CommandText = "SELECT S_ID, S_NAME, S_ADDRESS, S_PHONE\r\nFROM STUDENT";

this.sqlSelectCommand1.Connection = this.sqlConnection1;

//

// sqlInsertCommand1

//

this.sqlInsertCommand1.CommandText = "INSERT INTO [STUDENT] ([S_ID], [S_NAME], [S_ADDRESS], [S_PHONE]) VALUES (@.S_ID, @." +

"S_NAME, @.S_ADDRESS, @.S_PHONE)";

this.sqlInsertCommand1.Connection = this.sqlConnection1;

this.sqlInsertCommand1.Parameters.AddRange(new System.Data.SqlClient.SqlParameter[] {

new System.Data.SqlClient.SqlParameter("@.S_ID", System.Data.SqlDbType.Int, 0, "S_ID"),

new System.Data.SqlClient.SqlParameter("@.S_NAME", System.Data.SqlDbType.VarChar, 0, "S_NAME"),

new System.Data.SqlClient.SqlParameter("@.S_ADDRESS", System.Data.SqlDbType.VarChar, 0, "S_ADDRESS"),

new System.Data.SqlClient.SqlParameter("@.S_PHONE", System.Data.SqlDbType.Text, 0, "S_PHONE")});

//

// sqlDataAdapter1

//

this.sqlDataAdapter1.InsertCommand = this.sqlInsertCommand1;

this.sqlDataAdapter1.SelectCommand = this.sqlSelectCommand1;

this.sqlDataAdapter1.TableMappings.AddRange(new System.Data.Common.DataTableMapping[] {

new System.Data.Common.DataTableMapping("Table", "STUDENT", new System.Data.Common.DataColumnMapping[] {

new System.Data.Common.DataColumnMapping("S_ID", "S_ID"),

new System.Data.Common.DataColumnMapping("S_NAME", "S_NAME"),

new System.Data.Common.DataColumnMapping("S_ADDRESS", "S_ADDRESS"),

new System.Data.Common.DataColumnMapping("S_PHONE", "S_PHONE")})});

//

// Form1

//

this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);

this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;

this.ClientSize = new System.Drawing.Size(463, 266);

this.Controls.Add(s_PHONELabel);

this.Controls.Add(this.s_PHONETextBox);

this.Controls.Add(s_ADDRESSLabel);

this.Controls.Add(this.s_ADDRESSTextBox);

this.Controls.Add(s_NAMELabel);

this.Controls.Add(this.s_NAMETextBox);

this.Controls.Add(s_IDLabel);

this.Controls.Add(this.s_IDTextBox);

this.Controls.Add(this.sTUDENTBindingNavigator);

this.Name = "Form1";

this.Text = "Form1";

this.Load += new System.EventHandler(this.Form1_Load);

((System.ComponentModel.ISupportInitialize)(this.studentDataSet)).EndInit();

((System.ComponentModel.ISupportInitialize)(this.sTUDENTBindingSource)).EndInit();

((System.ComponentModel.ISupportInitialize)(this.sTUDENTBindingNavigator)).EndInit();

this.sTUDENTBindingNavigator.ResumeLayout(false);

this.sTUDENTBindingNavigator.PerformLayout();

this.ResumeLayout(false);

this.PerformLayout();

}

#endregion

private studentDataSet studentDataSet;

private System.Windows.Forms.BindingSource sTUDENTBindingSource;

private student.studentDataSetTableAdapters.STUDENTTableAdapter sTUDENTTableAdapter;

private System.Windows.Forms.BindingNavigator sTUDENTBindingNavigator;

private System.Windows.Forms.ToolStripButton bindingNavigatorAddNewItem;

private System.Windows.Forms.ToolStripLabel bindingNavigatorCountItem;

private System.Windows.Forms.ToolStripButton bindingNavigatorDeleteItem;

private System.Windows.Forms.ToolStripButton bindingNavigatorMoveFirstItem;

private System.Windows.Forms.ToolStripButton bindingNavigatorMovePreviousItem;

private System.Windows.Forms.ToolStripSeparator bindingNavigatorSeparator;

private System.Windows.Forms.ToolStripTextBox bindingNavigatorPositionItem;

private System.Windows.Forms.ToolStripSeparator bindingNavigatorSeparator1;

private System.Windows.Forms.ToolStripButton bindingNavigatorMoveNextItem;

private System.Windows.Forms.ToolStripButton bindingNavigatorMoveLastItem;

private System.Windows.Forms.ToolStripSeparator bindingNavigatorSeparator2;

private System.Windows.Forms.ToolStripButton sTUDENTBindingNavigatorSaveItem;

private System.Windows.Forms.TextBox s_IDTextBox;

private System.Windows.Forms.TextBox s_NAMETextBox;

private System.Windows.Forms.TextBox s_ADDRESSTextBox;

private System.Windows.Forms.TextBox s_PHONETextBox;

private System.Data.SqlClient.SqlConnection sqlConnection1;

private System.Data.SqlClient.SqlCommand sqlCommand1;

private System.Data.SqlClient.SqlCommand sqlSelectCommand1;

private System.Data.SqlClient.SqlCommand sqlInsertCommand1;

private System.Data.SqlClient.SqlDataAdapter sqlDataAdapter1;

}

}

///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

form1.cs

using System;

using System.Collections.Generic;

using System.ComponentModel;

using System.Data;

using System.Data.SqlClient;

using System.Drawing;

using System.Text;

using System.Windows.Forms;

namespace student

{

public partial class Form1 : Form

{

public Form1()

{

InitializeComponent();

}

private void sTUDENTBindingNavigatorSaveItem_Click(object sender, EventArgs e)

{

sqlConnection1.Open();

sqlDataAdapter1.InsertCommand.CommandText=

"INSERT INTO STUDENT (" +

"S_ID, S_NAME, S_ADDRESS, S_PHONE" +

") VALUES ('" +

s_IDTextBox.Text + "', '" +

s_NAMETextBox.Text + "', '" +

s_ADDRESSTextBox.Text + "', '" +

s_PHONETextBox.Text + "')";

sqlDataAdapter1.InsertCommand.ExecuteNonQuery();

sqlConnection1.Close();

this.Validate();

this.sTUDENTBindingSource.EndEdit();

this.sTUDENTTableAdapter.Update(this.studentDataSet.STUDENT);

}

private void Form1_Load(object sender, EventArgs e)

{

this.sTUDENTTableAdapter.Fill(this.studentDataSet.STUDENT);

}

}

}

|||Does the problem still exist ?

Jens K. Suessmeyer.

http://www.sqlserver2005.de

error for sending(saving) data to database

Hi,
Im using VS2005 and Im trying to link the C# windows form to MSSQL. I used BindingNavigator Control to read the data. After that I add sqlcommand and sqldataadapter to send the data to the database. My code is this

sqlDataAdapter1.InsertCommand.CommandText =
"INSERT INTO SUDENT (" +
"S_ID, S_NAME, S_ADDRESS, S_PHONE" +
") VALUES ('" +
S_IDComboBox.Text + "', '" +
S_NAMETextBox.Text + "', '" +
S_ADDRESSTextBox.Text + "', '" +
S_PHONETextBox.Text + "')";

sqlDataAdapter1.InsertCommand.ExecuteNonQuery();

It gave me this error
NulleferenceException was Unhandled and Object refrence not set to an instance of an object so I add this line

sqlCommand1 = ("INSERT INTO STUDENT (S_ID,S_NAME,S_ADDRESS,S_PHONE) VALUES (@.S_ID,@.S_NAME,@.S_ADDRESS,@.S_PHONE)" ,sqlConnection1);

Then it gave me some stupid error. By the way it didnt make a new object of SqlCommand although I tried .

So can u help me to solve my problem ? Thank youHi. the only object reference I can see in your code is:
sqlDataAdapter1
You could check if this is the correct spelling or if indeed it exists as a valid object.|||hi thank you for reply.
i correct the spelling but it still gave me the same error.|||

Quote:

Originally Posted by csharpa

hi thank you for reply.
i correct the spelling but it still gave me the same error.


Interesting. You corrected the spelling to what?sql

error for sending(saving) data to database

Hi,
I'm using VS2005 and I'm trying to link the C# windows form to MSSQL.
I used BindingNavigator Control to read the data. After that I add
sqlcommand and sqldataadapter to send the data to the database. My
code is this

sqlDataAdapter1. InsertCommand. CommandText =
"INSERT INTO SUDENT (" +
"S_ID, S_NAME, S_ADDRESS, S_PHONE" +
") VALUES ('" +
S_IDComboBox. Text + "', '" +
S_NAMETextBox. Text + "', '" +
S_ADDRESSTextBox. Text + "', '" +
S_PHONETextBox. Text + "')";

sqlDataAdapter1. InsertCommand. ExecuteNonQuery( );

It gave me this error
"NulleferenceExcept ion was Unhandled"and " Object refrence not set to
an instance of an object" so I add this line

sqlCommand1 = ("INSERT INTO STUDENT (S_ID,S_NAME, S_ADDRESS, S_PHONE)
VALUES (@.S_ID,@.S_NAME, @.S_ADDRESS, @.S_PHONE) " ,sqlConnection1) ;

Then it gave me some stupid error. By the way it didn't make a new
object of SqlCommand although I tired ...

So can u help me to solve my problem ? Thank you(projectid2007@.yahoo.com) writes:

Quote:

Originally Posted by

I'm using VS2005 and I'm trying to link the C# windows form to MSSQL.
I used BindingNavigator Control to read the data. After that I add
sqlcommand and sqldataadapter to send the data to the database. My
code is this
>
sqlDataAdapter1. InsertCommand. CommandText =
"INSERT INTO SUDENT (" +
"S_ID, S_NAME, S_ADDRESS, S_PHONE" +
") VALUES ('" +
S_IDComboBox. Text + "', '" +
S_NAMETextBox. Text + "', '" +
S_ADDRESSTextBox. Text + "', '" +
S_PHONETextBox. Text + "')";


Since you ask this in an SQL Server newsgroup, I will tell you what is
wrong with this query from an SQL Server perspective. What do you think
happens if the user in the PhoneTextBoxs types:

'); DROP TABLE SUDENT'

Oops! Table gone!

You should use parameterised commands:

"INSERT INTO SUDENT (" +
"S_ID, S_NAME, S_ADDRESS, S_PHONE" +
") VALUES (@.ID, @.Name, @.Address, @.Phone)"

and then use the CreateParameter method to define your parameters.

Quote:

Originally Posted by

sqlDataAdapter1. InsertCommand. ExecuteNonQuery( );
>
It gave me this error
"NulleferenceExcept ion was Unhandled"and " Object refrence not set to
an instance of an object" so I add this line
>
sqlCommand1 = ("INSERT INTO STUDENT (S_ID,S_NAME, S_ADDRESS, S_PHONE)
VALUES (@.S_ID,@.S_NAME, @.S_ADDRESS, @.S_PHONE) " ,sqlConnection1) ;
>
Then it gave me some stupid error. By the way it didn't make a new
object of SqlCommand although I tired ...
>
So can u help me to solve my problem ? Thank you


You are probably better off asking in a .Net newsgroup about how to
write .Net programs. Particularly, if you want to link them to
forms.

--
Erland Sommarskog, SQL Server MVP, esquel@.sommarskog.se
Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/pr...oads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodin...ions/books.mspx

Tuesday, March 27, 2012

Error encountered while starting the SSIS service

I installed SQL Server 2005 Integration services on Windows XP machine. Then I went to the SQL Server Configuration Manager and tried to Start the SSIS service. The "Log On As" value is "NT AUTHORITY\NetworkService". But I get the follwoing error:

The request failed or the service did not respond in a timely fashion. COnsult the event log or other applicable error logs for details.


Event Log details:
The SQL Server Integration Services service failed to start due to the following error:
The service did not respond to the start or control request in a timely fashion.

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.

I tried running the service using the "Local Service" and the "Local System" accounts also, but am still encountering the same error. What do I do...

Are you using SP1? There was a bug in SP1 that stopped the SSIS service from starting under certain conditions.

-Jamie

|||

I dont have any SP installed.

I installed SSIS on another machine and here the service runs successfully under NT AUTHORITY\Network Service. As for the first machine, as of now, I am only able to run it under the current domain account- Is this fine or will it lead to some problems/threats in future.

Error during upgrade of SQL Server 7.0 to 2000

Hello!
I'm trying to upgrade SQL Srerver 7.0 SP4 to SQL Server
2000 on Windows 2000 server, during the upgrade
I received the following error message " Error running
script:messages.sql(1)".
I found Microsoft article 300676 how to fix this problem.
In this article they provide link to the new setup.ins file
you have to download in order to fix your installation.
Here's the link and it doesn't work:
ftp://ftp.microsoft.com/bussys/sql/transfer/sql80/setup/
Does anybody know the correct link? Or where I can download this file from?
Thank you,
LenaArticle says:
To use the fix, use these steps:
1.. Download s80305i.exe
from:ftp://ftp.microsoft.com/bussys/sql/transfer/sql80/setup/
The password is: 8.00.305
2.. To install SQL Server 2000 using the new Setup.ins file, copy all of
the files on the SQL Server 2000 CD to a directory on your drive.
3.. Replace the existing Setup.ins in the \x86\Setup\ folder with the
Setup.ins file that you downloaded in the fix.
4.. Rerun the SQL Server 2000 setup.
It is working fine. I just cheked this out. If you will not able to download
it let me know your EMail I'll send it to you.
Regards
---
All information provided above AS IS.
"Lena" <lenaglozman@.yahoo.com> wrote in message
news:fc1e8071.0310310848.12b948d5@.posting.google.com...
> Hello!
> I'm trying to upgrade SQL Srerver 7.0 SP4 to SQL Server
> 2000 on Windows 2000 server, during the upgrade
> I received the following error message " Error running
> script:messages.sql(1)".
> I found Microsoft article 300676 how to fix this problem.
> In this article they provide link to the new setup.ins file
> you have to download in order to fix your installation.
> Here's the link and it doesn't work:
> ftp://ftp.microsoft.com/bussys/sql/transfer/sql80/setup/
> Does anybody know the correct link? Or where I can download this file
from?
> Thank you,
> Lena|||I could download the file from
ftp://ftp.microsoft.com/bussys/sql/transfer/sql80/setup/s80
305i.exe and then ran winzip to extract the setup.ins
file, the password to unzip this file is 8.00.305.
Let me know if you still having problem downloading this
file, i can email the setup.ins file to you.
>--Original Message--
>Hello!
>I'm trying to upgrade SQL Srerver 7.0 SP4 to SQL Server
>2000 on Windows 2000 server, during the upgrade
> I received the following error message " Error running
>script:messages.sql(1)".
>I found Microsoft article 300676 how to fix this problem.
>In this article they provide link to the new setup.ins
file
>you have to download in order to fix your installation.
>Here's the link and it doesn't work:
>ftp://ftp.microsoft.com/bussys/sql/transfer/sql80/setup/
>Does anybody know the correct link? Or where I can
download this file from?
>Thank you,
>Lena
>.
>

Error during sql server 2000 Ent Edition on Windows 2003 cluster

I got this error while trying to install sql server 2000 Ent Edition on
Windows 2003 Cluster:
"another virtual server with the same name exist on the network"
Any help will be appreciated.
Thanks
ping that virtual name, and look it up in Active Directory to see if it
really does exist.
If you created the entry in AD before the install, this may be the issue.
The install does that for you...
Kevin Hill
3NF Consulting
http://www.3nf-inc.com/NewsGroups.htm
Real-world stuff I run across with SQL Server:
http://kevin3nf.blogspot.com
"Ariana12345" <hakim.nadia@.bmc.org> wrote in message
news:F5B096C2-0EA1-4812-BF0F-59BC186217DA@.microsoft.com...
>I got this error while trying to install sql server 2000 Ent Edition on
> Windows 2003 Cluster:
> "another virtual server with the same name exist on the network"
> Any help will be appreciated.
> Thanks
>
|||The virtual name doesn't exist in AD but it exists on the network and I can
ping it.
Should I delete the existing virual server name and create it during the sql
install?
If this is the case, why the setup wizard ask to enter the name of a new or
existing virtual SQL server?
Thank you
"Kevin3NF" wrote:

> ping that virtual name, and look it up in Active Directory to see if it
> really does exist.
> If you created the entry in AD before the install, this may be the issue.
> The install does that for you...
> --
> Kevin Hill
> 3NF Consulting
> http://www.3nf-inc.com/NewsGroups.htm
> Real-world stuff I run across with SQL Server:
> http://kevin3nf.blogspot.com
>
> "Ariana12345" <hakim.nadia@.bmc.org> wrote in message
> news:F5B096C2-0EA1-4812-BF0F-59BC186217DA@.microsoft.com...
>
>
|||I would verify that the one you can ping isn't actually being used.
Something is responding to that ping
When you enter an existnig Virtual name, you are presented with options to
modify that instance (such as IP addresses).
New name allows you to do an installation.
Kevin Hill
3NF Consulting
http://www.3nf-inc.com/NewsGroups.htm
Real-world stuff I run across with SQL Server:
http://kevin3nf.blogspot.com
"Ariana12345" <hakim.nadia@.bmc.org> wrote in message
news:5D3E3B66-E492-423E-A9FC-0FED0E3CF53B@.microsoft.com...[vbcol=seagreen]
> The virtual name doesn't exist in AD but it exists on the network and I
> can
> ping it.
> Should I delete the existing virual server name and create it during the
> sql
> install?
> If this is the case, why the setup wizard ask to enter the name of a new
> or
> existing virtual SQL server?
> Thank you
> "Kevin3NF" wrote:
|||I entered new name for the virtual server and I passed the error but when I
entered the ip address it just hang.
Any idea why?
Thanks
"Kevin3NF" wrote:

> I would verify that the one you can ping isn't actually being used.
> Something is responding to that ping
> When you enter an existnig Virtual name, you are presented with options to
> modify that instance (such as IP addresses).
> New name allows you to do an installation.
> --
> Kevin Hill
> 3NF Consulting
> http://www.3nf-inc.com/NewsGroups.htm
> Real-world stuff I run across with SQL Server:
> http://kevin3nf.blogspot.com
>
> "Ariana12345" <hakim.nadia@.bmc.org> wrote in message
> news:5D3E3B66-E492-423E-A9FC-0FED0E3CF53B@.microsoft.com...
>
>
|||A great link to SQL cluster installs...complete with screenshots.
http://www.sql-server-performance.com/sqlserver2000_clustering_install_part2.asp
If it is hanging between IP and Disk selection, you may be having issues
enumerating the disks. Do you have disk resources available?
Off the wall issue: If your SQL group and any disk resource have the same
name, the install will hang right here where you are.
Kevin Hill
3NF Consulting
http://www.3nf-inc.com/NewsGroups.htm
Real-world stuff I run across with SQL Server:
http://kevin3nf.blogspot.com
"Ariana12345" <hakim.nadia@.bmc.org> wrote in message
news:5CFD0964-839E-483D-B0AD-4F93C2C907DA@.microsoft.com...[vbcol=seagreen]
>I entered new name for the virtual server and I passed the error but when I
> entered the ip address it just hang.
> Any idea why?
> Thanks
> "Kevin3NF" wrote:
|||Thank you very much for your help.
you were right the shared drive weren't not showing.
I was able to pass through all the steps but the install failed again.
Here is the sqlsetup log:
13:48:59 Begin Setup
13:48:59 8.00.194
13:48:59 Mode = Silent
13:48:59 ModeType = CLUSTER
13:48:59 Cluster node.
13:48:59 g_szIssPath=C:\WINDOWS\setup~0.iss
13:48:59 GetDefinitionEx returned: 0, Extended: 0x0
13:48:59 ValueFTS returned: 1
13:48:59 ValuePID returned: 1
13:48:59 ValueLic returned: 1
13:48:59 System: Windows NT Enterprise Server
13:48:59 SQL Server ProductType: Enterprise Edition [0x3]
13:48:59 IsNTCluster returned: 1
13:48:59 Begin Action: SetupInitialize
13:48:59 End Action SetupInitialize
13:48:59 Begin Action: SetupInstall
13:48:59 Reading Software\Microsoft\Windows\CurrentVersion\CommonFi lesDir ...
13:48:59 CommonFilesDir=C:\Program Files\Common Files
13:48:59 Windows Directory=C:\WINDOWS\
13:48:59 Program Files=C:\Program Files\
13:48:59 TEMPDIR=C:\DOCUME~1\ITSMAS~1\LOCALS~1\Temp\2\
13:48:59 Begin Action: SetupInstall
13:48:59 Begin Action: CheckFixedRequirements
13:48:59 Platform ID: 0xf00000
13:48:59 Version: 5.2.3790
13:48:59 File Version - C:\WINDOWS\system32\shdocvw.dll: 6.0.3790.2783
13:48:59 End Action: CheckFixedRequirements
13:49:00 Begin Action: ShowDialogs
13:49:00 Initial Dialog Mask: 0x183000f7, Disable Back=0x1
13:49:00 Begin Action ShowDialogsHlpr: 0x1
13:49:00 Begin Action: DialogShowSdWelcome
13:49:00 End Action DialogShowSdWelcome
13:49:00 Dialog 0x1 returned: 1
13:49:00 End Action ShowDialogsHlpr
13:49:00 ShowDialogsGetDialog returned: nCurrent=0x2,index=1
13:49:00 Begin Action ShowDialogsHlpr: 0x2
13:49:00 Begin Action: DialogShowSdMachineName
13:49:00 [DlgMachine]
13:49:00 Result = 1
13:49:00 Type = 268435466
13:49:00 Name = SQL1
13:49:00 ShowDlgMachine returned: 1
13:49:00 Name = SQL1, Type = 0x1000000a
13:49:00 Begin Action: CheckRequirements
13:49:00 Processor Architecture: x86 (Pentium)
13:49:00 Service Pack: 256
13:49:00 ComputerName: SQL1
13:49:00 User Name: mservicesql
13:49:00 IsAllAccessAllowed returned: 1
13:49:00 OS Language: 0x409
13:49:00 End Action CheckRequirements
13:49:00 This combination of Package and Operating System allows a full
product install.
13:49:00 End Action DialogShowSdMachineName
13:49:00 begin ShowDialogsUpdateMask
13:49:00 nFullMask = 0x183000f7, nCurrent = 0x2, nDirection = 0
13:49:00 Updated Dialog Mask: 0xbf3c0f7, Disable Back = 0x1
13:49:00 Dialog 0x2 returned: 0
13:49:00 End Action ShowDialogsHlpr
13:49:00 ShowDialogsGetDialog returned: nCurrent=0x4,index=2
13:49:00 Begin Action ShowDialogsHlpr: 0x4
13:49:00 Begin Action: DialogShowSdInstallMode
13:49:00 [DlgInstallMode]
13:49:00 Result = 1
13:49:00 Type = 1
13:49:00 InstallMode : 0x1
13:49:00 End Action DialogShowSdInstallMode
13:49:00 begin ShowDialogsUpdateMask
13:49:00 nFullMask = 0xbf3c0f7, nCurrent = 0x4, nDirection = 1
13:49:00 Updated Dialog Mask: 0x1bf7c0f7, Disable Back = 0x1
13:49:00 Dialog 0x4 returned: 1
13:49:00 End Action ShowDialogsHlpr
13:49:00 ShowDialogsGetDialog returned: nCurrent=0x10,index=4
13:49:00 Begin Action ShowDialogsHlpr: 0x10
13:49:00 Begin Action: DialogShowSdRegisterUserEx
13:49:00 End Action DialogShowSdRegisterUserEx
13:49:00 begin ShowDialogsUpdateMask
13:49:00 nFullMask = 0x1bf7c0f7, nCurrent = 0x10, nDirection = 1
13:49:00 Updated Dialog Mask: 0x1bf7c0f7, Disable Back = 0x1
13:49:00 Dialog 0x10 returned: 1
13:49:00 End Action ShowDialogsHlpr
13:49:00 ShowDialogsGetDialog returned: nCurrent=0x20,index=5
13:49:00 Begin Action ShowDialogsHlpr: 0x20
13:49:00 Begin Action: DialogShowSdLicense
13:49:00 End Action DialogShowSdLicense
13:49:00 Dialog 0x20 returned: 1
13:49:00 End Action ShowDialogsHlpr
13:49:00 ShowDialogsGetDialog returned: nCurrent=0x40,index=6
13:49:00 Begin Action ShowDialogsHlpr: 0x40
13:49:00 Begin Action: DialogShowSdCDKey
13:49:00 digpid size : 256
13:49:00 [DlgCDKey]
13:49:00 Result = 1
13:49:00 CDKey = RG7M3-XJC27-YG7GD-9BBBY-J2G9B
13:49:00 ShowDlgCDKeyreturned: 1
13:49:00 digpid size : 164
13:49:00 CDKey = RG7M3-XJC27-YG7GD-9BBBY-J2G9B, 20 digit Product ID =
53934-400-3595724-05409
13:49:00 End Action DialogShowSdCDKey
13:49:00 begin ShowDialogsUpdateMask
13:49:00 nFullMask = 0x1bf7c0f7, nCurrent = 0x40, nDirection = 1
13:49:00 Updated Dialog Mask: 0x1bf7c0f7, Disable Back = 0x1
13:49:00 Dialog 0x40 returned: 1
13:49:00 End Action ShowDialogsHlpr
13:49:00 ShowDialogsGetDialog returned: nCurrent=0x80,index=7
13:49:00 Begin Action ShowDialogsHlpr: 0x80
13:49:00 Dialog 0x80 returned: 1
13:49:00 End Action ShowDialogsHlpr
13:49:00 ShowDialogsGetDialog returned: nCurrent=0x4000,index=14
13:49:00 Begin Action ShowDialogsHlpr: 0x4000
13:49:00 Begin Action: DialogShowSdVirtualServer
13:49:00 [DlgVirtServer]
13:49:00 Result = 1
13:49:00 VirtServerName = CTXDB
13:49:00 IpAddresses = 10.153.12.105,255.255.255.0,bmcprod
13:49:04 ShowDlgVirtualServer returned: 0
13:49:04 Ipaddress = 10.153.12.105,255.255.255.0,bmcprod
13:49:04 szNewList = 10.153.12.105,255.255.255.0,bmcprod
13:49:04 szModifiedList =
13:49:04 szRemovedList =
13:49:04 End Action DialogShowSdVirtualServer
13:49:04 begin ShowDialogsUpdateMask
13:49:04 nFullMask = 0x1bf7c0f7, nCurrent = 0x4000, nDirection = 1
13:49:04 Updated Dialog Mask: 0x1bf7c0f7, Disable Back = 0x1
13:49:04 Dialog 0x4000 returned: 1
13:49:04 End Action ShowDialogsHlpr
13:49:04 ShowDialogsGetDialog returned: nCurrent=0x8000,index=15
13:49:04 Begin Action ShowDialogsHlpr: 0x8000
13:49:04 Begin Action : DialogShowSdDiskGroups
13:49:04 [DlgDiskGroups]
13:49:04 Result = 1
13:49:04 DiskGroupsName = CTXDBSQL
13:49:04 ShowDlgDiskGroups returned: 1
13:49:04 Disk Group = CTXDBSQL
13:49:04 End Action : DialogShowSdDiskGroups
13:49:04 begin ShowDialogsUpdateMask
13:49:04 nFullMask = 0x1bf7c0f7, nCurrent = 0x8000, nDirection = 1
13:49:04 Updated Dialog Mask: 0x1bf7c0f7, Disable Back = 0x1
13:49:04 Dialog 0x8000 returned: 1
13:49:04 End Action ShowDialogsHlpr
13:49:04 ShowDialogsGetDialog returned: nCurrent=0x10000,index=16
13:49:04 Begin Action ShowDialogsHlpr: 0x10000
13:49:04 Begin Action: DialogShowSdClusterDef
13:49:04 [DlgClusterDef]
13:49:04 Result = 1
13:49:04 nNumNodes = 2
13:49:04 VirtServerName = CTXDB
13:49:04 szPrefowners = SQL1,SQL2
13:49:04 ShowDlgClusterDef returned: 1
13:49:04 PrefOwners = SQL1,SQL2, NumIp = 0
13:49:04 End Action DialogShowSdClusterDef
13:49:04 begin ShowDialogsUpdateMask
13:49:04 nFullMask = 0x1bf7c0f7, nCurrent = 0x10000, nDirection = 1
13:49:04 Updated Dialog Mask: 0x1bf7c0f7, Disable Back = 0x1
13:49:04 Dialog 0x10000 returned: 1
13:49:04 End Action ShowDialogsHlpr
13:49:04 ShowDialogsGetDialog returned: nCurrent=0x20000,index=17
13:49:04 Begin Action ShowDialogsHlpr: 0x20000
13:49:04 Begin Action : Cluster Security - DlgAcct
13:49:04 [DlgAccount]
13:49:04 Result = 1
13:49:04 Domain = BMC
13:49:04 DomainAcct = mservicesql
13:49:04 DomainPwd
13:49:04 ValidateUser returned: 1, 0, 0x1ac
13:49:04 IsAcctValidForCluster returned: 1, 0
13:49:04 End Action : Cluster Security - DlgAcct
13:49:04 begin ShowDialogsUpdateMask
13:49:04 nFullMask = 0x1bf7c0f7, nCurrent = 0x20000, nDirection = 1
13:49:04 Updated Dialog Mask: 0x1bf7c0f7, Disable Back = 0x1
13:49:04 Dialog 0x20000 returned: 1
13:49:04 End Action ShowDialogsHlpr
13:49:04 ShowDialogsGetDialog returned: nCurrent=0x40000,index=18
13:49:04 Begin Action ShowDialogsHlpr: 0x40000
13:49:04 Begin Action: DialogShowSdCliSvr
13:49:04 DisplaySystemPreReq
13:49:04 [DlgClientServer]
13:49:04 Result = 1
13:49:04 Type = 2
13:49:04 ShowDlgClientServerSelect returned: 1
13:49:04 Type : 0x2
13:49:04 End Action DialogShowSdCliSvr
13:49:04 begin ShowDialogsUpdateMask
13:49:04 nFullMask = 0x1bf7c0f7, nCurrent = 0x40000, nDirection = 1
13:49:04 Updated Dialog Mask: 0x1bffc0f7, Disable Back = 0x1
13:49:04 Dialog 0x40000 returned: 1
13:49:04 End Action ShowDialogsHlpr
13:49:04 ShowDialogsGetDialog returned: nCurrent=0x80000,index=19
13:49:04 Begin Action ShowDialogsHlpr: 0x80000
13:49:04 Begin Action: DialogShowSdInstanceName
13:49:04 [DlgInstanceName]
13:49:04 Result = 1
13:49:04 InstanceName = MSSQLSERVER
13:49:04 Begin Action: ShowDlgInstanceName
13:49:05 End Action: ShowDlgInstanceName
13:49:05 ShowDlgInstanceName returned : 1
13:49:05 InstanceName : MSSQLSERVER
13:49:05 CreateSetupTopology(SQL1), Handle : 0x14545d8, returned : 0
13:49:05 CreateSetupTopology returned : 0, Handle : 0x14545d8
13:49:05 Topology Type : 1, Return Value : 0
13:49:05 ST_GetPhysicalNode returned : 0, PNHandle : 0x1454618
13:49:05 PN_EnumerateEx returned : 0
13:49:05 PN_GetSQLStates returned : 0, SqlStates : 0x0
13:49:05 PN_StartScan [0x1454618] returned : 0
13:49:05 PN_GetNext [0x1454618] returned : 18, Handle: [0x0]
13:49:05 No more items in enumeration.
13:49:05 ReleaseSetupTopology
13:49:05 End Action DialogShowSdInstanceName
13:49:05 begin ShowDialogsUpdateMask
13:49:05 nFullMask = 0x1bffc0f7, nCurrent = 0x80000, nDirection = 1
13:49:05 Updated Dialog Mask: 0x1bffc0f7, Disable Back = 0x1
13:49:05 Dialog 0x80000 returned: 1
13:49:05 End Action ShowDialogsHlpr
13:49:05 ShowDialogsGetDialog returned: nCurrent=0x100000,index=20
13:49:05 Begin Action ShowDialogsHlpr: 0x100000
13:49:05 Begin Action: DialogShowSdSetupType
13:49:05 Begin Action: Setup Type
13:49:05 [SetupTypeSQL]
13:49:05 Result = 303
13:49:05 szDir = C:\Program Files\Microsoft SQL Server
13:49:05 final szDir = C:\Program Files\Microsoft SQL Server
13:49:05 szDataDir = f:\
13:49:05 final szDataDir = f:\
13:49:05 End Action: Setup Type
13:49:05 Setup Type: Custom (303)
13:49:05 End Action DialogShowSdSetupType
13:49:05 begin ShowDialogsUpdateMask
13:49:05 nFullMask = 0x1bffc0f7, nCurrent = 0x100000, nDirection = 303
13:49:05 Updated Dialog Mask: 0x1bffc0f7, Disable Back = 0x1
13:49:05 Dialog 0x100000 returned: 303
13:49:05 End Action ShowDialogsHlpr
13:49:05 ShowDialogsGetDialog returned: nCurrent=0x200000,index=21
13:49:05 Begin Action ShowDialogsHlpr: 0x200000
13:49:05 Begin Action: DialogShowSdComponentMult
13:49:05 basesys = 0, baseinst = 0, basedata = 0
13:49:05 Begin Action: Component Handler
13:49:05 ***** Silent Mode in Multi comps
13:49:05 [SQLComponentMult]
13:49:05 Result = 1
13:49:05 ComponentSelectItem(MgtTool\Wzcnflct): -103
13:49:05 End Action: Component Handler
13:49:05 End Action DialogShowSdComponentMult
13:49:05 begin ShowDialogsUpdateMask
13:49:05 nFullMask = 0x1bffc0f7, nCurrent = 0x200000, nDirection = 1
13:49:05 Updated Dialog Mask: 0x1bffc0f7, Disable Back = 0x1
13:49:05 Dialog 0x200000 returned: 1
13:49:05 End Action ShowDialogsHlpr
13:49:05 ShowDialogsGetDialog returned: nCurrent=0x400000,index=22
13:49:05 Begin Action ShowDialogsHlpr: 0x400000
13:49:05 Begin Action: DlgServices
13:49:05 [DlgServices]
13:49:05 Result = 1
13:49:05 Local-Domain = 61680
13:49:05 AutoStart = 0
13:49:05 SQLDomain= BMC
13:49:05 SQLDomainAcct = mservicesql
13:49:05 SQLDomainPwd
13:49:05 ValidateUser returned: 1, 0, 0x1ac
13:49:05 GrantRightAsService returned : 1, 0
13:49:05 AgtDomain= BMC
13:49:05 AgtDomainAcct= mservicesql
13:49:05 AgtDomainPwd
13:49:05 ValidateUser returned: 1, 0, 0x1b4
13:49:05 GrantRightAsService returned : 1, 0
13:49:05 End Action DlgServices
13:49:05 begin ShowDialogsUpdateMask
13:49:05 nFullMask = 0x1bffc0f7, nCurrent = 0x400000, nDirection = 1
13:49:05 Updated Dialog Mask: 0x1bffc0f7, Disable Back = 0x1
13:49:05 Dialog 0x400000 returned: 1
13:49:05 End Action ShowDialogsHlpr
13:49:05 ShowDialogsGetDialog returned: nCurrent=0x800000,index=23
13:49:05 Begin Action ShowDialogsHlpr: 0x800000
13:49:05 Begin Action: DlgSQLSecurity
13:49:05 [DlgSQLSecurity]
13:49:05 Result = 1
13:49:05 szPwd
13:49:05 ShowDlgSQLSecurity returned: 1
13:49:05 LoginMode = 2,szPwd
13:49:05 End Action DlgSQLSecurity
13:49:05 begin ShowDialogsUpdateMask
13:49:05 nFullMask = 0x1bffc0f7, nCurrent = 0x800000, nDirection = 1
13:49:05 Updated Dialog Mask: 0x1bffc0f7, Disable Back = 0x1
13:49:05 Dialog 0x800000 returned: 1
13:49:05 End Action ShowDialogsHlpr
13:49:05 ShowDialogsGetDialog returned: nCurrent=0x1000000,index=24
13:49:05 Begin Action ShowDialogsHlpr: 0x1000000
13:49:05 Begin Action: DlgCollation
13:49:05 [DlgCollation]
13:49:05 Result = 1
13:49:05 collation_name = SQL_Latin1_General_CP1_CI_AS
13:49:05 ShowDlgCollation returned: 1
13:49:05 collation_name = SQL_Latin1_General_CP1_CI_AS,locale_name = ,lcid =
0x0,SortId = 0,dwCompFlags = 0x0
13:49:05 End Action DlgCollation
13:49:05 begin ShowDialogsUpdateMask
13:49:05 nFullMask = 0x1bffc0f7, nCurrent = 0x1000000, nDirection = 1
13:49:05 Updated Dialog Mask: 0x1bffc0f7, Disable Back = 0x1
13:49:05 Dialog 0x1000000 returned: 1
13:49:05 End Action ShowDialogsHlpr
13:49:05 ShowDialogsGetDialog returned: nCurrent=0x2000000,index=25
13:49:05 Begin Action ShowDialogsHlpr: 0x2000000
13:49:05 Begin Action: DlgNetwork
13:49:05 Result = 1
13:49:05 [DlgServerNetwork]
13:49:05 NetworkLibs = 255
13:49:05 TCPPort =1433
13:49:05 TCPPrxy =
13:49:06 NMPPipeName =\\.\pipe\sql\query
13:49:06 ShowDlgNetwork returned: 1
13:49:06 [DlgServerNetwork]
13:49:06 NetworkLibs = 255
13:49:06 TCPPort = 1433
13:49:06 TCPPrxy = Default
13:49:06 NMPPipeName = \\.\pipe\sql\query
13:49:06 Result = 1
13:49:06 End Action DlgNetwork
13:49:06 begin ShowDialogsUpdateMask
13:49:06 nFullMask = 0x1bffc0f7, nCurrent = 0x2000000, nDirection = 1
13:49:06 Updated Dialog Mask: 0x1bffc0f7, Disable Back = 0x1
13:49:06 Dialog 0x2000000 returned: 1
13:49:06 End Action ShowDialogsHlpr
13:49:06 ShowDialogsGetDialog returned: nCurrent=0x8000000,index=27
13:49:06 Begin Action ShowDialogsHlpr: 0x8000000
13:49:06 Begin Action: DialogShowSdStartCopy
13:49:06 End Action DialogShowSdStartCopy
13:49:06 begin ShowDialogsUpdateMask
13:49:06 nFullMask = 0x1bffc0f7, nCurrent = 0x8000000, nDirection = 1
13:49:06 Updated Dialog Mask: 0x1bffc0f7, Disable Back = 0x1
13:49:06 Dialog 0x8000000 returned: 1
13:49:06 End Action ShowDialogsHlpr
13:49:06 ShowDialogsGetDialog returned: nCurrent=0x10000000,index=28
13:49:06 Begin Action ShowDialogsHlpr: 0x10000000
13:49:06 Begin Action: DialogShowSdLicenseMode
13:49:06 LicenseMode as read from ISS file : PERPROC
13:49:06 LicenseLimit as read from ISS file : 1
13:49:06 ShowDlgLicense returned: 50074
13:49:06 End Action DialogShowSdLicenseMode
13:49:06 Dialog 0x10000000 returned: -1
13:49:06 End Action ShowDialogsHlpr
13:49:06 End Action ShowDialogs
13:49:06 Action CleanUpInstall:
13:49:06 StatsGenerate returned: 2
13:49:06 StatsGenerate (0x0,0x1,0xf00000,0x100,1033,303,0x0,0x1000000a,0, 0,0
13:49:06 StatsGenerate -1,mservicesql)
13:49:06 Installation Failed.
"Kevin3NF" wrote:

> A great link to SQL cluster installs...complete with screenshots.
> http://www.sql-server-performance.com/sqlserver2000_clustering_install_part2.asp
> If it is hanging between IP and Disk selection, you may be having issues
> enumerating the disks. Do you have disk resources available?
> Off the wall issue: If your SQL group and any disk resource have the same
> name, the install will hang right here where you are.
>
> --
> Kevin Hill
> 3NF Consulting
> http://www.3nf-inc.com/NewsGroups.htm
> Real-world stuff I run across with SQL Server:
> http://kevin3nf.blogspot.com
>
> "Ariana12345" <hakim.nadia@.bmc.org> wrote in message
> news:5CFD0964-839E-483D-B0AD-4F93C2C907DA@.microsoft.com...
>
>
|||What was the last screen you saw, and what error did it exit with?
Kevin Hill
3NF Consulting
http://www.3nf-inc.com/NewsGroups.htm
Real-world stuff I run across with SQL Server:
http://kevin3nf.blogspot.com
"Ariana12345" <hakim.nadia@.bmc.org> wrote in message
news:A280678E-D2DF-49E5-8421-2F15652FCCB9@.microsoft.com...[vbcol=seagreen]
> Thank you very much for your help.
> you were right the shared drive weren't not showing.
> I was able to pass through all the steps but the install failed again.
> Here is the sqlsetup log:
> 13:48:59 Begin Setup
> 13:48:59 8.00.194
> 13:48:59 Mode = Silent
> 13:48:59 ModeType = CLUSTER
> 13:48:59 Cluster node.
> 13:48:59 g_szIssPath=C:\WINDOWS\setup~0.iss
> 13:48:59 GetDefinitionEx returned: 0, Extended: 0x0
> 13:48:59 ValueFTS returned: 1
> 13:48:59 ValuePID returned: 1
> 13:48:59 ValueLic returned: 1
> 13:48:59 System: Windows NT Enterprise Server
> 13:48:59 SQL Server ProductType: Enterprise Edition [0x3]
> 13:48:59 IsNTCluster returned: 1
> 13:48:59 Begin Action: SetupInitialize
> 13:48:59 End Action SetupInitialize
> 13:48:59 Begin Action: SetupInstall
> 13:48:59 Reading Software\Microsoft\Windows\CurrentVersion\CommonFi lesDir
> ...
> 13:48:59 CommonFilesDir=C:\Program Files\Common Files
> 13:48:59 Windows Directory=C:\WINDOWS\
> 13:48:59 Program Files=C:\Program Files\
> 13:48:59 TEMPDIR=C:\DOCUME~1\ITSMAS~1\LOCALS~1\Temp\2\
> 13:48:59 Begin Action: SetupInstall
> 13:48:59 Begin Action: CheckFixedRequirements
> 13:48:59 Platform ID: 0xf00000
> 13:48:59 Version: 5.2.3790
> 13:48:59 File Version - C:\WINDOWS\system32\shdocvw.dll: 6.0.3790.2783
> 13:48:59 End Action: CheckFixedRequirements
> 13:49:00 Begin Action: ShowDialogs
> 13:49:00 Initial Dialog Mask: 0x183000f7, Disable Back=0x1
> 13:49:00 Begin Action ShowDialogsHlpr: 0x1
> 13:49:00 Begin Action: DialogShowSdWelcome
> 13:49:00 End Action DialogShowSdWelcome
> 13:49:00 Dialog 0x1 returned: 1
> 13:49:00 End Action ShowDialogsHlpr
> 13:49:00 ShowDialogsGetDialog returned: nCurrent=0x2,index=1
> 13:49:00 Begin Action ShowDialogsHlpr: 0x2
> 13:49:00 Begin Action: DialogShowSdMachineName
> 13:49:00 [DlgMachine]
> 13:49:00 Result = 1
> 13:49:00 Type = 268435466
> 13:49:00 Name = SQL1
> 13:49:00 ShowDlgMachine returned: 1
> 13:49:00 Name = SQL1, Type = 0x1000000a
> 13:49:00 Begin Action: CheckRequirements
> 13:49:00 Processor Architecture: x86 (Pentium)
> 13:49:00 Service Pack: 256
> 13:49:00 ComputerName: SQL1
> 13:49:00 User Name: mservicesql
> 13:49:00 IsAllAccessAllowed returned: 1
> 13:49:00 OS Language: 0x409
> 13:49:00 End Action CheckRequirements
> 13:49:00 This combination of Package and Operating System allows a full
> product install.
> 13:49:00 End Action DialogShowSdMachineName
> 13:49:00 begin ShowDialogsUpdateMask
> 13:49:00 nFullMask = 0x183000f7, nCurrent = 0x2, nDirection = 0
> 13:49:00 Updated Dialog Mask: 0xbf3c0f7, Disable Back = 0x1
> 13:49:00 Dialog 0x2 returned: 0
> 13:49:00 End Action ShowDialogsHlpr
> 13:49:00 ShowDialogsGetDialog returned: nCurrent=0x4,index=2
> 13:49:00 Begin Action ShowDialogsHlpr: 0x4
> 13:49:00 Begin Action: DialogShowSdInstallMode
> 13:49:00 [DlgInstallMode]
> 13:49:00 Result = 1
> 13:49:00 Type = 1
> 13:49:00 InstallMode : 0x1
> 13:49:00 End Action DialogShowSdInstallMode
> 13:49:00 begin ShowDialogsUpdateMask
> 13:49:00 nFullMask = 0xbf3c0f7, nCurrent = 0x4, nDirection = 1
> 13:49:00 Updated Dialog Mask: 0x1bf7c0f7, Disable Back = 0x1
> 13:49:00 Dialog 0x4 returned: 1
> 13:49:00 End Action ShowDialogsHlpr
> 13:49:00 ShowDialogsGetDialog returned: nCurrent=0x10,index=4
> 13:49:00 Begin Action ShowDialogsHlpr: 0x10
> 13:49:00 Begin Action: DialogShowSdRegisterUserEx
> 13:49:00 End Action DialogShowSdRegisterUserEx
> 13:49:00 begin ShowDialogsUpdateMask
> 13:49:00 nFullMask = 0x1bf7c0f7, nCurrent = 0x10, nDirection = 1
> 13:49:00 Updated Dialog Mask: 0x1bf7c0f7, Disable Back = 0x1
> 13:49:00 Dialog 0x10 returned: 1
> 13:49:00 End Action ShowDialogsHlpr
> 13:49:00 ShowDialogsGetDialog returned: nCurrent=0x20,index=5
> 13:49:00 Begin Action ShowDialogsHlpr: 0x20
> 13:49:00 Begin Action: DialogShowSdLicense
> 13:49:00 End Action DialogShowSdLicense
> 13:49:00 Dialog 0x20 returned: 1
> 13:49:00 End Action ShowDialogsHlpr
> 13:49:00 ShowDialogsGetDialog returned: nCurrent=0x40,index=6
> 13:49:00 Begin Action ShowDialogsHlpr: 0x40
> 13:49:00 Begin Action: DialogShowSdCDKey
> 13:49:00 digpid size : 256
> 13:49:00 [DlgCDKey]
> 13:49:00 Result = 1
> 13:49:00 CDKey = RG7M3-XJC27-YG7GD-9BBBY-J2G9B
> 13:49:00 ShowDlgCDKeyreturned: 1
> 13:49:00 digpid size : 164
> 13:49:00 CDKey = RG7M3-XJC27-YG7GD-9BBBY-J2G9B, 20 digit Product ID =
> 53934-400-3595724-05409
> 13:49:00 End Action DialogShowSdCDKey
> 13:49:00 begin ShowDialogsUpdateMask
> 13:49:00 nFullMask = 0x1bf7c0f7, nCurrent = 0x40, nDirection = 1
> 13:49:00 Updated Dialog Mask: 0x1bf7c0f7, Disable Back = 0x1
> 13:49:00 Dialog 0x40 returned: 1
> 13:49:00 End Action ShowDialogsHlpr
> 13:49:00 ShowDialogsGetDialog returned: nCurrent=0x80,index=7
> 13:49:00 Begin Action ShowDialogsHlpr: 0x80
> 13:49:00 Dialog 0x80 returned: 1
> 13:49:00 End Action ShowDialogsHlpr
> 13:49:00 ShowDialogsGetDialog returned: nCurrent=0x4000,index=14
> 13:49:00 Begin Action ShowDialogsHlpr: 0x4000
> 13:49:00 Begin Action: DialogShowSdVirtualServer
> 13:49:00 [DlgVirtServer]
> 13:49:00 Result = 1
> 13:49:00 VirtServerName = CTXDB
> 13:49:00 IpAddresses = 10.153.12.105,255.255.255.0,bmcprod
> 13:49:04 ShowDlgVirtualServer returned: 0
> 13:49:04 Ipaddress = 10.153.12.105,255.255.255.0,bmcprod
> 13:49:04 szNewList = 10.153.12.105,255.255.255.0,bmcprod
> 13:49:04 szModifiedList =
> 13:49:04 szRemovedList =
> 13:49:04 End Action DialogShowSdVirtualServer
> 13:49:04 begin ShowDialogsUpdateMask
> 13:49:04 nFullMask = 0x1bf7c0f7, nCurrent = 0x4000, nDirection = 1
> 13:49:04 Updated Dialog Mask: 0x1bf7c0f7, Disable Back = 0x1
> 13:49:04 Dialog 0x4000 returned: 1
> 13:49:04 End Action ShowDialogsHlpr
> 13:49:04 ShowDialogsGetDialog returned: nCurrent=0x8000,index=15
> 13:49:04 Begin Action ShowDialogsHlpr: 0x8000
> 13:49:04 Begin Action : DialogShowSdDiskGroups
> 13:49:04 [DlgDiskGroups]
> 13:49:04 Result = 1
> 13:49:04 DiskGroupsName = CTXDBSQL
> 13:49:04 ShowDlgDiskGroups returned: 1
> 13:49:04 Disk Group = CTXDBSQL
> 13:49:04 End Action : DialogShowSdDiskGroups
> 13:49:04 begin ShowDialogsUpdateMask
> 13:49:04 nFullMask = 0x1bf7c0f7, nCurrent = 0x8000, nDirection = 1
> 13:49:04 Updated Dialog Mask: 0x1bf7c0f7, Disable Back = 0x1
> 13:49:04 Dialog 0x8000 returned: 1
> 13:49:04 End Action ShowDialogsHlpr
> 13:49:04 ShowDialogsGetDialog returned: nCurrent=0x10000,index=16
> 13:49:04 Begin Action ShowDialogsHlpr: 0x10000
> 13:49:04 Begin Action: DialogShowSdClusterDef
> 13:49:04 [DlgClusterDef]
> 13:49:04 Result = 1
> 13:49:04 nNumNodes = 2
> 13:49:04 VirtServerName = CTXDB
> 13:49:04 szPrefowners = SQL1,SQL2
> 13:49:04 ShowDlgClusterDef returned: 1
> 13:49:04 PrefOwners = SQL1,SQL2, NumIp = 0
> 13:49:04 End Action DialogShowSdClusterDef
> 13:49:04 begin ShowDialogsUpdateMask
> 13:49:04 nFullMask = 0x1bf7c0f7, nCurrent = 0x10000, nDirection = 1
> 13:49:04 Updated Dialog Mask: 0x1bf7c0f7, Disable Back = 0x1
> 13:49:04 Dialog 0x10000 returned: 1
> 13:49:04 End Action ShowDialogsHlpr
> 13:49:04 ShowDialogsGetDialog returned: nCurrent=0x20000,index=17
> 13:49:04 Begin Action ShowDialogsHlpr: 0x20000
> 13:49:04 Begin Action : Cluster Security - DlgAcct
> 13:49:04 [DlgAccount]
> 13:49:04 Result = 1
> 13:49:04 Domain = BMC
> 13:49:04 DomainAcct = mservicesql
> 13:49:04 DomainPwd
> 13:49:04 ValidateUser returned: 1, 0, 0x1ac
> 13:49:04 IsAcctValidForCluster returned: 1, 0
> 13:49:04 End Action : Cluster Security - DlgAcct
> 13:49:04 begin ShowDialogsUpdateMask
> 13:49:04 nFullMask = 0x1bf7c0f7, nCurrent = 0x20000, nDirection = 1
> 13:49:04 Updated Dialog Mask: 0x1bf7c0f7, Disable Back = 0x1
> 13:49:04 Dialog 0x20000 returned: 1
> 13:49:04 End Action ShowDialogsHlpr
> 13:49:04 ShowDialogsGetDialog returned: nCurrent=0x40000,index=18
> 13:49:04 Begin Action ShowDialogsHlpr: 0x40000
> 13:49:04 Begin Action: DialogShowSdCliSvr
> 13:49:04 DisplaySystemPreReq
> 13:49:04 [DlgClientServer]
> 13:49:04 Result = 1
> 13:49:04 Type = 2
> 13:49:04 ShowDlgClientServerSelect returned: 1
> 13:49:04 Type : 0x2
> 13:49:04 End Action DialogShowSdCliSvr
> 13:49:04 begin ShowDialogsUpdateMask
> 13:49:04 nFullMask = 0x1bf7c0f7, nCurrent = 0x40000, nDirection = 1
> 13:49:04 Updated Dialog Mask: 0x1bffc0f7, Disable Back = 0x1
> 13:49:04 Dialog 0x40000 returned: 1
> 13:49:04 End Action ShowDialogsHlpr
> 13:49:04 ShowDialogsGetDialog returned: nCurrent=0x80000,index=19
> 13:49:04 Begin Action ShowDialogsHlpr: 0x80000
> 13:49:04 Begin Action: DialogShowSdInstanceName
> 13:49:04 [DlgInstanceName]
> 13:49:04 Result = 1
> 13:49:04 InstanceName = MSSQLSERVER
> 13:49:04 Begin Action: ShowDlgInstanceName
> 13:49:05 End Action: ShowDlgInstanceName
> 13:49:05 ShowDlgInstanceName returned : 1
> 13:49:05 InstanceName : MSSQLSERVER
> 13:49:05 CreateSetupTopology(SQL1), Handle : 0x14545d8, returned : 0
> 13:49:05 CreateSetupTopology returned : 0, Handle : 0x14545d8
> 13:49:05 Topology Type : 1, Return Value : 0
> 13:49:05 ST_GetPhysicalNode returned : 0, PNHandle : 0x1454618
> 13:49:05 PN_EnumerateEx returned : 0
> 13:49:05 PN_GetSQLStates returned : 0, SqlStates : 0x0
> 13:49:05 PN_StartScan [0x1454618] returned : 0
> 13:49:05 PN_GetNext [0x1454618] returned : 18, Handle: [0x0]
> 13:49:05 No more items in enumeration.
> 13:49:05 ReleaseSetupTopology
> 13:49:05 End Action DialogShowSdInstanceName
> 13:49:05 begin ShowDialogsUpdateMask
> 13:49:05 nFullMask = 0x1bffc0f7, nCurrent = 0x80000, nDirection = 1
> 13:49:05 Updated Dialog Mask: 0x1bffc0f7, Disable Back = 0x1
> 13:49:05 Dialog 0x80000 returned: 1
> 13:49:05 End Action ShowDialogsHlpr
> 13:49:05 ShowDialogsGetDialog returned: nCurrent=0x100000,index=20
> 13:49:05 Begin Action ShowDialogsHlpr: 0x100000
> 13:49:05 Begin Action: DialogShowSdSetupType
> 13:49:05 Begin Action: Setup Type
> 13:49:05 [SetupTypeSQL]
> 13:49:05 Result = 303
> 13:49:05 szDir = C:\Program Files\Microsoft SQL Server
> 13:49:05 final szDir = C:\Program Files\Microsoft SQL Server
> 13:49:05 szDataDir = f:\
> 13:49:05 final szDataDir = f:\
> 13:49:05 End Action: Setup Type
> 13:49:05 Setup Type: Custom (303)
> 13:49:05 End Action DialogShowSdSetupType
> 13:49:05 begin ShowDialogsUpdateMask
> 13:49:05 nFullMask = 0x1bffc0f7, nCurrent = 0x100000, nDirection = 303
> 13:49:05 Updated Dialog Mask: 0x1bffc0f7, Disable Back = 0x1
> 13:49:05 Dialog 0x100000 returned: 303
> 13:49:05 End Action ShowDialogsHlpr
> 13:49:05 ShowDialogsGetDialog returned: nCurrent=0x200000,index=21
> 13:49:05 Begin Action ShowDialogsHlpr: 0x200000
> 13:49:05 Begin Action: DialogShowSdComponentMult
> 13:49:05 basesys = 0, baseinst = 0, basedata = 0
> 13:49:05 Begin Action: Component Handler
> 13:49:05 ***** Silent Mode in Multi comps
> 13:49:05 [SQLComponentMult]
> 13:49:05 Result = 1
> 13:49:05 ComponentSelectItem(MgtTool\Wzcnflct): -103
> 13:49:05 End Action: Component Handler
> 13:49:05 End Action DialogShowSdComponentMult
> 13:49:05 begin ShowDialogsUpdateMask
> 13:49:05 nFullMask = 0x1bffc0f7, nCurrent = 0x200000, nDirection = 1
> 13:49:05 Updated Dialog Mask: 0x1bffc0f7, Disable Back = 0x1
> 13:49:05 Dialog 0x200000 returned: 1
> 13:49:05 End Action ShowDialogsHlpr
> 13:49:05 ShowDialogsGetDialog returned: nCurrent=0x400000,index=22
> 13:49:05 Begin Action ShowDialogsHlpr: 0x400000
> 13:49:05 Begin Action: DlgServices
> 13:49:05 [DlgServices]
> 13:49:05 Result = 1
> 13:49:05 Local-Domain = 61680
> 13:49:05 AutoStart = 0
> 13:49:05 SQLDomain = BMC
> 13:49:05 SQLDomainAcct = mservicesql
> 13:49:05 SQLDomainPwd
> 13:49:05 ValidateUser returned: 1, 0, 0x1ac
> 13:49:05 GrantRightAsService returned : 1, 0
> 13:49:05 AgtDomain = BMC
> 13:49:05 AgtDomainAcct = mservicesql
> 13:49:05 AgtDomainPwd
> 13:49:05 ValidateUser returned: 1, 0, 0x1b4
> 13:49:05 GrantRightAsService returned : 1, 0
> 13:49:05 End Action DlgServices
> 13:49:05 begin ShowDialogsUpdateMask
> 13:49:05 nFullMask = 0x1bffc0f7, nCurrent = 0x400000, nDirection = 1
> 13:49:05 Updated Dialog Mask: 0x1bffc0f7, Disable Back = 0x1
> 13:49:05 Dialog 0x400000 returned: 1
> 13:49:05 End Action ShowDialogsHlpr
> 13:49:05 ShowDialogsGetDialog returned: nCurrent=0x800000,index=23
> 13:49:05 Begin Action ShowDialogsHlpr: 0x800000
> 13:49:05 Begin Action: DlgSQLSecurity
> 13:49:05 [DlgSQLSecurity]
> 13:49:05 Result = 1
> 13:49:05 szPwd
> 13:49:05 ShowDlgSQLSecurity returned: 1
> 13:49:05 LoginMode = 2,szPwd
> 13:49:05 End Action DlgSQLSecurity
> 13:49:05 begin ShowDialogsUpdateMask
> 13:49:05 nFullMask = 0x1bffc0f7, nCurrent = 0x800000, nDirection = 1
> 13:49:05 Updated Dialog Mask: 0x1bffc0f7, Disable Back = 0x1
> 13:49:05 Dialog 0x800000 returned: 1
> 13:49:05 End Action ShowDialogsHlpr
> 13:49:05 ShowDialogsGetDialog returned: nCurrent=0x1000000,index=24
> 13:49:05 Begin Action ShowDialogsHlpr: 0x1000000
> 13:49:05 Begin Action: DlgCollation
> 13:49:05 [DlgCollation]
> 13:49:05 Result = 1
> 13:49:05 collation_name = SQL_Latin1_General_CP1_CI_AS
> 13:49:05 ShowDlgCollation returned: 1
> 13:49:05 collation_name = SQL_Latin1_General_CP1_CI_AS,locale_name = ,lcid
> =
> 0x0,SortId = 0,dwCompFlags = 0x0
> 13:49:05 End Action DlgCollation
> 13:49:05 begin ShowDialogsUpdateMask
> 13:49:05 nFullMask = 0x1bffc0f7, nCurrent = 0x1000000, nDirection = 1
> 13:49:05 Updated Dialog Mask: 0x1bffc0f7, Disable Back = 0x1
> 13:49:05 Dialog 0x1000000 returned: 1
> 13:49:05 End Action ShowDialogsHlpr
> 13:49:05 ShowDialogsGetDialog returned: nCurrent=0x2000000,index=25
> 13:49:05 Begin Action ShowDialogsHlpr: 0x2000000
> 13:49:05 Begin Action: DlgNetwork
> 13:49:05 Result = 1
> 13:49:05 [DlgServerNetwork]
> 13:49:05 NetworkLibs = 255
> 13:49:05 TCPPort =1433
> 13:49:05 TCPPrxy =
> 13:49:06 NMPPipeName =\\.\pipe\sql\query
> 13:49:06 ShowDlgNetwork returned: 1
> 13:49:06 [DlgServerNetwork]
> 13:49:06 NetworkLibs = 255
> 13:49:06 TCPPort = 1433
> 13:49:06 TCPPrxy = Default
> 13:49:06 NMPPipeName = \\.\pipe\sql\query
> 13:49:06 Result = 1
> 13:49:06 End Action DlgNetwork
> 13:49:06 begin ShowDialogsUpdateMask
> 13:49:06 nFullMask = 0x1bffc0f7, nCurrent = 0x2000000, nDirection = 1
> 13:49:06 Updated Dialog Mask: 0x1bffc0f7, Disable Back = 0x1
> 13:49:06 Dialog 0x2000000 returned: 1
> 13:49:06 End Action ShowDialogsHlpr
> 13:49:06 ShowDialogsGetDialog returned: nCurrent=0x8000000,index=27
> 13:49:06 Begin Action ShowDialogsHlpr: 0x8000000
> 13:49:06 Begin Action: DialogShowSdStartCopy
> 13:49:06 End Action DialogShowSdStartCopy
> 13:49:06 begin ShowDialogsUpdateMask
> 13:49:06 nFullMask = 0x1bffc0f7, nCurrent = 0x8000000, nDirection = 1
> 13:49:06 Updated Dialog Mask: 0x1bffc0f7, Disable Back = 0x1
> 13:49:06 Dialog 0x8000000 returned: 1
> 13:49:06 End Action ShowDialogsHlpr
> 13:49:06 ShowDialogsGetDialog returned: nCurrent=0x10000000,index=28
> 13:49:06 Begin Action ShowDialogsHlpr: 0x10000000
> 13:49:06 Begin Action: DialogShowSdLicenseMode
> 13:49:06 LicenseMode as read from ISS file : PERPROC
> 13:49:06 LicenseLimit as read from ISS file : 1
> 13:49:06 ShowDlgLicense returned: 50074
> 13:49:06 End Action DialogShowSdLicenseMode
> 13:49:06 Dialog 0x10000000 returned: -1
> 13:49:06 End Action ShowDialogsHlpr
> 13:49:06 End Action ShowDialogs
> 13:49:06 Action CleanUpInstall:
> 13:49:06 StatsGenerate returned: 2
> 13:49:06 StatsGenerate
> (0x0,0x1,0xf00000,0x100,1033,303,0x0,0x1000000a,0, 0,0
> 13:49:06 StatsGenerate -1,mservicesql)
> 13:49:06 Installation Failed.
>
> "Kevin3NF" wrote:
|||SQL Server setup failed because I selected Per Processor Licensing -- It's a
known issue.
http://support.microsoft.com/?id=273769
Thank you very much for your help
"Kevin3NF" wrote:
[vbcol=seagreen]
> What was the last screen you saw, and what error did it exit with?
> --
> Kevin Hill
> 3NF Consulting
> http://www.3nf-inc.com/NewsGroups.htm
> Real-world stuff I run across with SQL Server:
> http://kevin3nf.blogspot.com
>
> "Ariana12345" <hakim.nadia@.bmc.org> wrote in message
> news:A280678E-D2DF-49E5-8421-2F15652FCCB9@.microsoft.com...