954,595 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

need help - please

hi everyone,
I'm new to Asp.Net and I have to write a virtual store project.
I have a DB and can read from it but can't do anytjing else no matter how I try.

I also think I am getting a little lost in all the forms amd partial code.

please, if anyone can take a look at my project and maybe tell me what I should do next.
I would really appreciate the help.
it's driving me crazy!!!!!!!!!!!!!!!!!!

Attachments DVDPr.zip (236.34KB)
yavanna
Newbie Poster
3 posts since Sep 2005
Reputation Points: 10
Solved Threads: 0
 

What do you want to do with the code?

Whats your next step? Can you be specific what you are asking for?

Letscode
Junior Poster
175 posts since Feb 2005
Reputation Points: 11
Solved Threads: 6
 

my main problems currently are not beeing able to update my members in the DB and I can't verifi credit card info.

so far I was able only to read from my DB not write to it.

yavanna
Newbie Poster
3 posts since Sep 2005
Reputation Points: 10
Solved Threads: 0
 

my main problems currently are not beeing able to update my members in the DB and I can't verifi credit card info.

so far I was able only to read from my DB not write to it.


In your Project under the FileSales,

I found out these code,

this.oleDbInsertCommand1.CommandText = "INSERT INTO tblSales(CountSale, Date_sale, Sale_Cus_Code, Sale_movie_code) VALUES" +
				<strong>" (?, ?, ?, ?)"</strong>;



And the Parameter assigning is given something like this,

this.oleDbInsertCommand1.Parameters.Add<strong>(new System.Data.OleDb.OleDbParameter("CountSale", System.Data.OleDb.OleDbType.Integer, 0, System.Data.ParameterDirection.Input, false, ((System.Byte)(10)), ((System.Byte)(0)), "CountSale", System.Data.DataRowVersion.Current, null));</strong>
			this.oleDbInsertCommand1.Parameters.Add(new System.Data.OleDb.OleDbParameter("Date_sale", System.Data.OleDb.OleDbType.DBDate, 0, "Date_sale"));
			this.oleDbInsertCommand1.Parameters.Add(new System.Data.OleDb.OleDbParameter("Sale_Cus_Code", System.Data.OleDb.OleDbType.Integer, 0, System.Data.ParameterDirection.Input, false, ((System.Byte)(10)), ((System.Byte)(0)), "Sale_Cus_Code", System.Data.DataRowVersion.Current, null));
			this.oleDbInsertCommand1.Parameters.Add(new System.Data.OleDb.OleDbParameter("Sale_movie_code", System.Data.OleDb.OleDbType.Integer, 0, System.Data.ParameterDirection.Input, false, ((System.Byte)(10)), ((System.Byte)(0)), "Sale_movie_code", System.Data.DataRowVersion.Current, null));

Problems
1.I dont see where the parameter is declared.
2.I dont see where the parameter is Assigned.

Can you verify that?

Letscode
Junior Poster
175 posts since Feb 2005
Reputation Points: 11
Solved Threads: 6
 

thanks, I changed the code in the new member form which was almost the same, and now it works.

private void fillin_Click(object sender, System.EventArgs e)
{		
     AddProduc(this.id.Text,this.firstname.Text,...,this.email.Text);
}

private void AddProduct(string id,string fn,string ln,...,string email)
{
   string sql = "insert into tblCustomer (Id_cus,...,Emai_cus) " +" values ('{0}'...'{10}') ";
   sql = String.Format(sql,id,...,email);
   UpdateDB(sql);
}

but now I have problems with adding and deliting movies.
It keeps saying :Exception Details: System.Data.OleDb.OleDbException: No value given for one or more required parameters.

and points to these code lines:

Line 33: DataSet ds=new DataSet();
Line 34: atmovies MovTbl=new atmovies();
Line 35: MovTbl.moviesadp.Fill(ds);
Line 36: DDMov.Items.Add("בחר סרט מהרשימה");
Line 37: DataTable MovDetales = ds.Tables["tblmovie"];

these workes well in my new member form and I don't know why they won't work here.

Attachments project161005.zip (265.75KB)
yavanna
Newbie Poster
3 posts since Sep 2005
Reputation Points: 10
Solved Threads: 0
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You