|
I am creating a mp3 player through C#.Net I have kept a CheckBox that shows the play list. I have created the player such that it when ever the user cicks on the selection on checkbox the player play the corresponding song. so the user has to click on the next song to play the next song once the previous song is finished.
Now I would like to know is it possible for the player to automatically play the next song once the previous song is finished? If so how do I go about doing this on C#.Net
Please let me know... Thanks!
|
|
|
|
|
U better Post the question in C# Blog rather than Asp.net
|
|
|
|
|
if we want to send a image in a folder which is in my project on clicking a button after selecting a image from any directory in my computer through fileupload web control?
|
|
|
|
|
Save it in that folder using FileUpload control method.
Google on FileUpload control usage.
|
|
|
|
|
Try to search in Google or MSDN you'll get tons of samples for FileUpload control.
|
|
|
|
|
Try This Code
FileUpload1.SaveAs(Server.MapPath("images1") + "/" +TextBox2 .Text +TextBox4 .Text + FileUpload1.FileName);
FileUpload2.SaveAs(Server.MapPath("images1") + "/" + TextBox2.Text + TextBox4.Text + FileUpload2.FileName);
FileUpload3.SaveAs(Server.MapPath("images1") + "/" + TextBox2.Text + TextBox4.Text + FileUpload3.FileName);
cmd.Parameters.AddWithValue("@hotelexteriorview","./images1/" + System.IO.Path.GetFileName(FileUpload1.PostedFile.FileName) );
cmd.Parameters.AddWithValue("@roomtype1","./images1/" + System.IO.Path.GetFileName(FileUpload2.PostedFile.FileName) );
cmd.Parameters.AddWithValue("@roomtype2", "./images1/" + System.IO.Path.GetFileName(FileUpload3.PostedFile.FileName));
FileUpload1.SaveAs save the file in server.mappath
cmd.Parameters.AddWithValue save the link in database
I Used this code long back
hope it may help
|
|
|
|
|
The two web services provided in the article of Sending messages in asp.net through we service are not working properly.Please suggest me the webservice which is working correctly.
Thankx & regards
Riti
|
|
|
|
|
Wow. Why is it that this forum gets so terrible this time of day ?
What on earth makes you think that someone would find this article, work out why the code does not work for you, write new code, and send it to you ? How about you get a grip on reality. Do your own work, or pay someone to do it for you. If you have a question on an article, ask in the article. If you post in the forums, be clear what you want., and what you have tried. I am sure the code in the article works, you just don't know how to use it.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
Christian Graus wrote: Why is it that this forum gets so terrible this time of day ?
|
|
|
|
|
Hello All,
I have one select box in Html and i want to call javascript when scroll down event in IE 6.0
that is working with firefox as well as in IE 7.0
below call work in IE 7.0 but not workin IE 6.0
function first()
{
alert('scrolldown');
}
please help me out how can i solved above issue
Thanks in advance,
Anish Patel
|
|
|
|
|
Please help me.
Now I want to store the (text and image) combined to store in one field as
binary format. In later we want to retrieving the binary data from the database and display a IE page.
How it is possible?
Can you give a solution in VB.net
Thanking you,
abglorie
|
|
|
|
|
The only way to store two pieces of data in one field, is to combine them, for example, in a zip. If you were to store them in two fields, then it would be a lot easier. How do you do it ? With SQL, it's got to be one of the most answered questions on the web, and if you bothered to google it, you'd get far more in depth examples and answers than you'll ever get in a forum reply
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
hii
m trying to update the column ProductID of table Product.db
i have written the following code on pageload but its giving error:
syntax error in update statement.where m i wrong.plz guide.
the code is:
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
String str2 = "Select PID From Product Where(ProductID='PID1')";
OleDbCommand cmd = new OleDbCommand(str2, conn);
conn.Open();
string m = cmd.ExecuteScalar().ToString();
m = "PID" + m;
conn.Close();
string str3 = "Update Product Set(ProductID='" + m + "')Where(ProductID='PID1')";
cmd = new OleDbCommand(str3, conn);
conn.Open();
cmd.ExecuteNonQuery();
conn.Close();
populateddl1();
populateddl2();
}
}
|
|
|
|
|
Well, the brackets in your SQL are at a mininum, superfluous. Why would you change all product IDs from a known value to the new one ?
This code is an utter disaster, but I think it should work. However, I don't think this is what's blowing up. Are you sure this is the issue, because ASP.NET will only identify an 'update statement', if you try to use one of it's nasty, SQL holding controls that tries to update things for you. I think you've got the code there to use an updating control, and not the code in that control to do the update as it expects.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
Actually i want to insert data in Product.db table
it has columns named:
PID: which is auto number
ProductID:Which is Primary key
and others columnss are:ProductName,ProductDescription,ProductPrice,VendorID;
i want the entries in ProductID table like when PID value is 1
ProductID value becomes PID1.in have written code for this on button click.but the Promblem occurs that when somebody deletes the rows of
the table the new PID Value doesnt start from 1.it start from last deleted value of PID.Now i want that ProductID value gets update according to the PID value.the code at button click is:
string str1 = "Select MAX(PID) From Product";
OleDbCommand cmd = new OleDbCommand(str1, conn);
conn.Open();
string max= cmd.ExecuteScalar().ToString();
if (max == "")
{
max = "PID" + 1;
}
else
{
int i= Convert.ToInt32(max) + 1;
string s1=Convert.ToString(i);
max = "PID" + s1;
}
conn.Close();
string str = "Insert Into Product(ProductID,ProductName,ProductDescription,ProductPrice)Values('"+max+"','" + txtprdtname.Text + "','" + txtprdtdescrp.Text + "','" + txtprdtprice.Text + "')";
cmd = new OleDbCommand(str, conn);
conn.Open();
cmd.ExecuteNonQuery();
conn.Close();
str = "Select * From Product";
cmd = new OleDbCommand(str, conn);
OleDbDataReader dr1 = null;
conn.Open();
dr1 = cmd.ExecuteReader();
DropDownList2.DataSource = dr1;
DropDownList2.DataTextField = "ProductID";
DropDownList2.DataValueField = "ProductID";
DropDownList2.DataBind();
conn.Close();
so m trying to update the ProductID value AS i have default inserted
PID1 when the first row is inserted in Product table.
|
|
|
|
|
|
m not insertin PID in Product table but m inserting ProductID value and it is
necessary as it is primary key and cannot be null.
|
|
|
|
|
If it's the primary key, why not make it an identity ? Either way, why not write a data layer, or at least write code to a semi professional standard ?
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
Well, this code is excrable. Why would you assume that any postback is a new row ? Why would you not do all your code for an insertion inside your event ? Why would you not have a data layer ?
Everything about this code is terrible. You should buy a book on ASP.NET and one on ADO.NET, and read them before writing any code. I assume no-one is paying for this code, if they are, you are a liar and a thief.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
Christian Graus wrote: I assume no-one is paying for this code, if they are, you are a liar and a thief.
Depends on how much they pay for it Christian ;>
var question = (_2b || !(_2b));
|
|
|
|
|
Well, I am sure they know their website would cost $12000 to write in the US, and believe that the $50 they are paying this guy will get the same result. They probably deserve each other.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
Is it possible to call onClientClick event on a specific condition at server side.....I mean i m entering prodcut reviews from user and it is necessary for user to login and for that i m using animation extender on click event i want to check whether logged in or not if yes then save the reviews else show animation window for login........i created animation extender at desing view ....plz guide me a bit.....
|
|
|
|
|
KhandelwalA wrote: Is it possible to call onClientClick event on a specific condition at server side.....
Not without the code in question making an AJAX call to check the status on the server side, or the status on the server being passed to the client beforehand.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
If you are using Sessions to check if the user is logged in then it can be done on the server side by check the null for the session. or you can still do it on the client site.
Vuyiswa Maseko,
Few companies that installed computers to reduce the employment of clerks have realized their expectations.... They now need more and more expensive clerks even though they call them "Developers" or "Programmers."
C#/VB.NET/ASP.NET/SQL7/2000/2005/2008
http://www.vuyiswamaseko.com
vuyiswa@its.co.za
http://www.itsabacus.co.za/itsabacus/
|
|
|
|
|
Is it necessary to install asp.net on that computer on which a deploy project of asp.net is installed.and if it is a web application then how we get domain for it and a perticuler site name.
|
|
|
|