Click here to Skip to main content
15,891,775 members
Home / Discussions / ASP.NET
   

ASP.NET

 
AnswerRe: problem during converting from C# to Vb Pin
Christian Graus27-Jul-09 11:24
protectorChristian Graus27-Jul-09 11:24 
GeneralRe: problem during converting from C# to Vb Pin
Omar Gameel Salem27-Jul-09 11:27
professionalOmar Gameel Salem27-Jul-09 11:27 
GeneralRe: problem during converting from C# to Vb Pin
Abhijit Jana27-Jul-09 11:30
professionalAbhijit Jana27-Jul-09 11:30 
GeneralRe: problem during converting from C# to Vb Pin
Omar Gameel Salem27-Jul-09 11:32
professionalOmar Gameel Salem27-Jul-09 11:32 
GeneralRe: problem during converting from C# to Vb Pin
Abhijit Jana27-Jul-09 11:36
professionalAbhijit Jana27-Jul-09 11:36 
Questiongridview Pin
solo_gaurav27-Jul-09 10:43
solo_gaurav27-Jul-09 10:43 
AnswerRe: gridview Pin
Abhijit Jana27-Jul-09 10:54
professionalAbhijit Jana27-Jul-09 10:54 
GeneralRe: gridview Pin
solo_gaurav27-Jul-09 11:07
solo_gaurav27-Jul-09 11:07 
no i dont want to hide whole row.. i just want to hide cell from row...
can i give my code here it is Smile | :)

using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
using System.Data.Odbc;

public partial class Default2 : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!this.IsPostBack)
        {
            // Define the ADO.NET objects for selecting products from the database.
            string selectSQL = "SELECT * FROM test ";
            OdbcConnection con = new OdbcConnection("Dsn=PostgreSQL35W123;uid=postgres;pwd=abc");
            OdbcCommand cmd = new OdbcCommand(selectSQL, con);
            // Open the connection.
            con.Open();
            // Define the binding.
            cmd.Connection = con;
            DropDownList1.DataSource = cmd.ExecuteReader();
            DropDownList1.DataTextField = "Journal_Title";
            //   DropDownList1.DataValueField = "year1974";
            // Activate the binding.
            this.DataBind();
            con.Close();
            // Make sure nothing is currently selected in the list box.
            DropDownList1.SelectedIndex = -1;
        }
    }
    protected void DropDownList1_SelectedIndexChanged(object sender, EventArgs e)
    {
        string selectSQL = "SELECT * FROM test where Journal_Title='" + DropDownList1.SelectedItem.Text + "'";
        OdbcConnection con = new OdbcConnection("Dsn=PostgreSQL35W123;uid=postgres;pwd=abc");
        OdbcCommand cmd = new OdbcCommand(selectSQL, con);
        // Open the connection.
        con.Open();
        // Define the binding.
        cmd.Connection = con;
        cmd.ExecuteNonQuery();
        OdbcDataReader dr = cmd.ExecuteReader();
        if (dr.HasRows)
        {
            GridView1.DataSource = dr;
            GridView1.DataBind();
            Label1.Text = "found";
        }
        else
        {
            Label1.Text = "not found";
        }

        //Label1.Text = "Your favorite country is: " + DropDownList1.SelectedItem.Text;

    }
}


now i want that when a dropdownlist item is selected then it show a griview with only those cells which has data in them... and the cell with no data(null) , i want them to be hidden Smile | :) abhijit plz help if you get it Smile | :)
GeneralRe: gridview Pin
Abhijit Jana27-Jul-09 11:21
professionalAbhijit Jana27-Jul-09 11:21 
GeneralRe: gridview Pin
solo_gaurav27-Jul-09 11:28
solo_gaurav27-Jul-09 11:28 
QuestionError in compiling Page with Crystal reports Pin
www.Developerof.NET27-Jul-09 4:24
www.Developerof.NET27-Jul-09 4:24 
AnswerRe: Error in compiling Page with Crystal reports Pin
Abhishek Sur27-Jul-09 8:20
professionalAbhishek Sur27-Jul-09 8:20 
GeneralRe: Error in compiling Page with Crystal reports Pin
www.Developerof.NET27-Jul-09 20:00
www.Developerof.NET27-Jul-09 20:00 
GeneralRe: Error in compiling Page with Crystal reports Pin
Abhishek Sur27-Jul-09 21:45
professionalAbhishek Sur27-Jul-09 21:45 
Question[Message Deleted] Pin
comp_j27-Jul-09 4:20
comp_j27-Jul-09 4:20 
AnswerRe: GridView & CheckBox Pin
Abhijit Jana27-Jul-09 4:27
professionalAbhijit Jana27-Jul-09 4:27 
QuestionGridView & CheckBox Pin
comp_j27-Jul-09 4:18
comp_j27-Jul-09 4:18 
AnswerRe: GridView & CheckBox Pin
Blue_Boy27-Jul-09 4:22
Blue_Boy27-Jul-09 4:22 
GeneralRe: GridView & CheckBox Pin
comp_j27-Jul-09 8:39
comp_j27-Jul-09 8:39 
AnswerRe: GridView & CheckBox Pin
Abhijit Jana27-Jul-09 4:31
professionalAbhijit Jana27-Jul-09 4:31 
GeneralRe: GridView & CheckBox Pin
comp_j27-Jul-09 4:55
comp_j27-Jul-09 4:55 
GeneralRe: GridView & CheckBox Pin
Blue_Boy27-Jul-09 6:45
Blue_Boy27-Jul-09 6:45 
AnswerRe: GridView & CheckBox [modified] Pin
comp_j27-Jul-09 10:28
comp_j27-Jul-09 10:28 
AnswerRe: GridView & CheckBox Pin
Abhijit Jana27-Jul-09 10:39
professionalAbhijit Jana27-Jul-09 10:39 
AnswerRe: GridView & CheckBox Pin
bonypatel27-Jul-09 22:26
bonypatel27-Jul-09 22:26 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.