private void Exl_Click(object sender, System.Web.UI.ImageClickEventArgs e) { string strTitle = " any Name u give" + DateTime.Now; new DataGridExcelExporter(this.gridname , this.Page).Export(strTitle); }
dhans
private void Exl_Click(object sender, System.Web.UI.ImageClickEventArgs e) { string strTitle = " any Name u give" + DateTime.Now; new DataGridExcelExporter(this.gridname , this.Page).Export(strTitle); }
dhans
:) :-D :laugh: ;) ;P :^) :( :sigh: :doh: :(( :zzz: :-\ :-O :rolleyes: :omg: :wtf: :mad::confused::~:|X|:suss::cool::rose:
dhans
:^):^):^):^):^):^):^):^):^):^):^) :^):rose::rose::rose::rose::rose: :^):rose::^):^):^):^)***** :^):rose::^):^):^):^)***** :^):rose::^):^):^):^)***** :^):rose::rose::rose::rose::rose: :^):^):^):^):^):^):^):^):^):^):^)
dhans
put semicolon at the end of the statement this.k=k;
dhans
For understanding AutoPostBack, we need to know , what a PostBack Then, what is AutoPostBack, Autopostback is the mechanism, by which the page will be posted Back to the server automatically based on some events in the web controls. In some of the web controls, the property called auto post back, which if set to true, will send the request to the server when an event happens in the control For example. Dropdown Box (Combo box) web control has the property autopostback, if we set the property to true, when ever user selects a different value in the combo box, and event will be fired in the server. i.e. a request will be send to the server. Why we need to send a request to the server in this case? Consider this scenario where the web page is used for entering the user information. The page contains two combo box controls State and Town. When user selects the state, the appropriate towns should be filled in the town combo box which is loaded from the database. For achieving this requirement, we can set the autopostback property of state combo box to true. If we do that we can handle the event in the server side and write code to populate the town combo box with the values from the database. This is how we use the autopostback property. I will give another example for the autopostback usage with another control which will give much better understanding. Consider a login page, which contains text fields User ID, User Name and Password fields. User name text box will not be editable. So the requirement will be like this, when user enters the user id and clicks tab, his name should be displayed in the User Name text field. For achieving this we have to make autopostback property of the user id textfield to true and handle the event in the server side, In the event handler, we have to write code to fetch the user name from the database for the user id ,which we will be getting from the user id text box
dhans
modified on Friday, January 04, 2008 2:07:23 AM
give us the sql query and code. so that we will check it and will say
dhans
Check into the sql query where u have given the new DBfield for updating
dhans
Don't give the option to enter the date by user. Give the option to select the date from the calender. Display a popup calender and select the date from it. Make the textfield for the date to be "readonly".
dhans
The follwing is the coding in Editmodule.aspx protected void Page_Load(object sender, EventArgs e) { if (Session["username"] == null) { Response.Redirect("PMSessionExpiry.aspx"); } string strAccess, Filename; strAccess = null; Filename = System.IO.Path.GetFileName(HttpContext.Current.Request.CurrentExecutionFilePath); strAccess = PTSGeneral.File_Found(Session["username"].ToString(), Filename); if (strAccess == "") { Response.Redirect("PMAccess.aspx"); } if (!IsPostBack) { //Fill project name, module name to dropdownlist. PTSGeneral.DDlGetData("select pr_id,pr_name from project_mst order by pr_id", DDLProjectName, "pr_name", "Pr_id"); ProjectId = DDLProjectName.SelectedValue.ToString(); lblModId.Text = CModule.getMaxModuleID(); //PTSGeneral.DDlGetData("select mo_id,mo_name from module_mst where pr_id='" + DDLProjectName.SelectedValue.ToString() + "' order by pr_id,mo_id", lblModId , "mo_id", "mo_name"); PTSGeneral.getUserDetails(ddlModifiedBy); //call script for only accept only numeric value in no.of developer field txtNoofDeveloper.Attributes.Add("onKeypress", "javascript:return inputNumbers()"); } } 2. source contains the following <a href="javascript:OpenPopupPage('HelpMod.aspx','<%= txtModIdSearch.ClientID %>','false');"> <img id="imgHelpMod" onclick="return imgHelpMod_onclick()" src="images/help4.jpg" style="width: 19px" height="19" /></td> 3. helpmodule.aspx has the following No coding. only grid which contains "module id, module name" Kindly give a clear coding how to do and where to write. plz
dhans
kindly write me a clear coding for that, As i am a new programmer. plz
dhans
I am using session variable
dhana
:sigh: Have EditModule.aspx form and an helpMod.aspx(popup) form. when image button clicked in Editmodule.aspx, helpmod.aspx opens. Helpmod.aspx is loaded with 2 field "id and name" in grid using sql query. id is kept as link button in the grid. When linkbutton "id" clicked, i need the id must be placed in the "textfield" of EditModule.aspx. Kindly help in this regard.
dhana