Search

You searched for the word(s): userid:776543

Matching Posts

  • Re: Response.Redirect("URL") and target="_blank"

    Try this one: protected void DataList3_ItemCommand(object source, DataListCommandEventArgs e) { if(!Page.IsPostback) { if (Convert.ToInt32(e.CommandArgument) == 1) { string nurl=e.CommandName.ToString(); if (nurl != "") { Response.Write("<script>"); Response.Write("window.open('" + nurl +"')"); Response.Write("<"+"/script>"); } } } }
    Posted to Web Forms (Forum) by Punithkumar on 1/20/2009
  • Re: Response.Redirect("URL") and target="_blank"

    Otherwise try this: if(!Page.IsPostback) { Response.Write("<script>window.open(' http://www.google.com.hk/ ','_blank');</script>"); }
    Posted to Web Forms (Forum) by Punithkumar on 1/20/2009
  • Re: Response.Redirect("URL") and target="_blank"

    Do not put that code in page load event. Place that code in some button click event.
    Posted to Web Forms (Forum) by Punithkumar on 1/20/2009
  • Re: How to search database data and display it ?

    try this: //Connecting to a database; using System.Data.SqlClient; using System.Data.SqlTypes; this.con = new System.Data.SqlClient.SqlConnection(); this.con.ConnectionString = "workstation id=MPHWEDT012D;packet size=4096;user id=sa;data source=MPHWEDT012D;pe" + "rsist security info=True;initial catalog=ESD;password=Password12"; //using DataReader.. string SQL1 = "select * from YourTable where Name like '%john%'"; SqlCommand cmd1 = new SqlCommand(SQL1,con); con
    Posted to Getting Started (Forum) by Punithkumar on 9/18/2008
  • Re: Export Gridview to Excel not working

    Hi, There are three approaches can export to excel file, approach 2 and 3 are helpful to you. 1.One is using GridView that is bound on DataSet from database. And export GridView to Excel File. http://forums.asp.net/t/1197704/2076903.aspx . 2.Another approach is more flexible: Write an Excel file directly via the data in DataSet. http://forums.asp.net/p/1222903/2189537.aspx . 3.As to export the data to existing excel file or write data into specific cell of excel file, you can use Excel Library: http
    Posted to Getting Started (Forum) by Punithkumar on 9/18/2008
  • Re: how to display message and redirect to another page

    try this: if(some condition) { Response.Write(@"<script language='javascript'>alert('The following errors have occurred: \n" + strErrorDesc + " .');</script>"); Response.Redirect("SomeOtherPage.aspx") }
    Posted to Getting Started (Forum) by Punithkumar on 9/18/2008
  • Re: .Net

    Check these link for Gridview Editing : http://quickstarts.asp.net/QuickStartv20/aspnet/doc/ctrlref/data/gridview.aspx EXTRAS about Gridview : Inserting rows in Gridview : http://www.aspdotnetcodes.com/Simple_Insert_Update_Delete_GridView_Sample.aspx Multi featured GridViews : 1.http://www.eggheadcafe.com/tutorials/aspnet/c67c4daa-83c2-4baa-aea4-2c8855527acb/aspnet-gridview-filterin.aspx 2.http://www.codeproject.com/KB/aspnet/MultiFeatureGridView.aspx 3. http://www.aspdotnetcodes.com/Asp.Net_GridView_Filter_Sample
    Posted to Getting Started (Forum) by Punithkumar on 9/18/2008
  • Re: writing log files in asp.net

    [quote user="Zong-Qing Li - MSFT"] Hi, Based on my understandings, we could get log message from the Application_error event. The code is shown below. .asax.cs protected void Application_Error(object sender, EventArgs e) { Exception ee = Server.GetLastError(); string errormessage= ee.Message.ToString(); //write the log to the file } If I misunderstanding the problem, please inform of me. [/quote] Hi Zong-Qing Li, Thank you for your reply. The above post writes only error messages. But i
    Posted to Getting Started (Forum) by Punithkumar on 8/11/2008
  • Re: Dynamic Links

    This is a better good idea. Using LinkButton Instead of Hyperlink. Did you try this? [quote user="StefanPienaar"] Hi, I'm guessing you are already using a GridView to display your results. If thats the case, you can achieve the desired results by using 2 template columns: < asp : GridView ID ="GridView1" runat ="server" AutoGenerateColumns ="False" DataKeyNames ="Id" > < Columns > < asp : templatefield headertext ="Id"
    Posted to Getting Started (Forum) by Punithkumar on 8/7/2008
  • Re: pls help me with the radio button

    [quote user="unnamed"] what if i have 4 radio buttons and in every buttons there is different query.. and im not going to use a command button?? thank you [/quote] try this one. In Page load event: if(!Page.IsPostBack) { DropDownList1.Visible=false; Button1.Visible=false; } Under RadioButton1_CheckedChanged event // SET AutoPostBack Property to true. { DropDownList1.Visible=true; Button1.Visible=true; string SQL1 = "select * from tblDailyChecks where ColumnName=@para1"; SqlCommand
    Posted to Getting Started (Forum) by Punithkumar on 8/6/2008
Page 1 of 91 (908 items) 1 2 3 4 5 Next > ... Last ยป