|
I am using a dropdownlist. DropDownList Enter the value in Design Time
(Add New).
My event in
dropdownlist_SelectedIndexChanged(---------)
{
if(dropdownlist.selectedindex == 0)
{
---------------
}
But Write this code not fired event()
|
|
|
|
|
Check property of dropdownlist that autopostback is true or not.
Devjit Das
|
|
|
|
|
Yes, AutoPostBack Property already True
|
|
|
|
|
in html OnSelectedIndexChanged="dropdownlist_SelectedIndexChanged" is written this function.plz to verify this.
|
|
|
|
|
Set the DropDown Property Autopostback is True
|
|
|
|
|
Yes, AutoPostBack Property Already Ture
|
|
|
|
|
<asp:DropDownList ID="DropDownList1" runat="server" AutoPostBack ="true" OnSelectedIndexChanged="DropDownList1_SelectedIndexChanged">
<asp:ListItem >Slect</asp:ListItem>
<asp:ListItem >Hello</asp:ListItem>
<asp:ListItem >Hi</asp:ListItem>
<asp:ListItem >Are</asp:ListItem>
</asp:DropDownList>
protected void DropDownList1_SelectedIndexChanged(object sender, EventArgs e)
{
if (DropDownList1.SelectedIndex == 1)
{
Response.Write("Testing");
}
}
|
|
|
|
|
May I know the code outside the "IF" condition is working or not??
or that dropdown contain any items???
You are using ASP.NET1.0 or 1.1??
if so check the InitializeComponent() in the code behind file that it contain an eventhandler for selectedindexchanged event....
All I ever wanted is what others have.... CrazySanker
|
|
|
|
|
--Here This code is according to the Question
if the Selected index is 2 than the code outside if is execute
-- I am user asp.net 2.0
|
|
|
|
|
put a break point on this point
if (DropDownList1.SelectedIndex == 1)<br />
check that, is it become true? and wat happend next
All I ever wanted is what others have.... CrazySanker
|
|
|
|
|
|
How can a new row be added to the grid view using JavaScript code?
|
|
|
|
|
sofiz.p wrote: grid view using JavaScript code?
Javascript works on the client side, it can't identify grid view. AFAIK, you have two alternatives
1 - Use AJAX to request to a server method which adds a new row to grid view
2 - Gridview will be rendered as HTML table. Use Document.CreateElement() in javascript to create new row elements and add it to the gridview table.
|
|
|
|
|
I want to add multiple records at a time.
When clicking the JavaScript button a new row should be added to the grid. After I fill the row and make the necessary validations, I should be able to add another row without saving the previous row so that I can delete or modify it whenever I want (all operations are client side till now) until you hit the save button. When I click on save, I have to add all records to the DB at once . Do you know how to use javascript for this?
|
|
|
|
|
The easiest way is to use an AJAX ASP .net UpdatePanel. It will go to the server side, but users won't notice of the flicker, it's a typical solution for this issue.
/// -------------------------
Braulio Díez
http://www.tipsdotnet.com
/// -------------------------
|
|
|
|
|
I want to add multiple records at a time.
When clicking the JavaScript button a new row should be added to the grid. After I fill the row and make the necessary validations, I should be able to add another row without saving the previous row so that I can delete or modify it whenever I want (all operations are client side till now) until you hit the save button. When I click on save, I have to add all records to the DB at once
|
|
|
|
|
HI All Frdsssssssss,
I have a web Appllication and i want upload on the server. Plz tell me Process step by step..... I am Waiting..
Thanksssssssss
Ramakant Singh
|
|
|
|
|
Hi ramakant,
If u want to upload your app. on the live server then first u need to web space. if u have already space then u have also access for that space ok. Now there are some software to upload a file on web server like filezilla, cuteftp, smartftpclient using this software u can uplaod your website on live server
|
|
|
|
|
Hello TarDuk,
Thanks for mailing...
Dear I have web space and also have cuteftp...
plz tell me Step how can Deploy ASP.Net Web application on live server.
|
|
|
|
|
open cuteftp. It will ask for urlname and username and password ok this 3 things is necessary
now there is one now there may be some folder depends on your configuration. then copy your folder from your hard drive and paste it into cuteftp which is currently opend your site ok.
then if all the page are static then no problem otherwise if u r using jsp,asp or dotnet u have to set and configure web.config file as per your application ok
|
|
|
|
|
If you are using Visual Studio 2005, you have an option called "publish web site", from there you can directly upload it into your web space, or you can publish it in your local hard disk and then manually upload that files using e.g. FileZilla.
I use normally the second option using FileZilla, it's free and works very well.
HTH
Braulio
/// -------------------------
Braulio Díez
tipsdotnet.com
/// -------------------------
|
|
|
|
|
Hi friends, I am developing one application. In our application there are two types of multimedia object like Image and flash object. And I want to save it into sql server 2005 I can save image into database and also retrieve it successfully. But I cannot save and retrive swf object to and from database can anybody help me.
Thanks
|
|
|
|
|
Swf files are similar like any other files. What is the content type you given when sending this to page, what problem you are facing when fetching the data ?
|
|
|
|
|
Ya that I know when we store image it will store as a binary and when we store swf file it will store like binary only. But the mail problem is that how can we retrieve it
I want to convert this 3 line only.
Response.ContentType = "image/jpeg"; // 1
Response.ContentType = "application/x-shockwave-flash"; // Done
System.Drawing.Image image = RetrieveImage(id, tname);
image.Save(Response.OutputStream, System.Drawing.Imaging.ImageFormat.Jpeg);
How can we change this two line for shockwavw object
|
|
|
|
|
TarDuk wrote: System.Drawing.Image image = RetrieveImage(id, tname);
image.Save(Response.OutputStream, System.Drawing.Imaging.ImageFormat.Jpeg);
Assume you have the byte array in b[] . Response.BinaryWrite(b); ?
|
|
|
|