|
yes, it is right, are you facing any problem in this?
|
|
|
|
|
when i run this it giving error
"DataBinding: 'System.Data.DataRowView' does not contain a property with the name 'IsVisible'."Sasmi
|
|
|
|
|
why don't you set the visibiltiy to false in the method where you bind the grid?
this is easier.
|
|
|
|
|
You have got to mark the property as public to access it from the markup. Change the "IsVisible" property's access specifier to "public " and your code will work.
HTH!
|
|
|
|
|
I have change the property to public but still showing error
"DataBinding: 'System.Data.DataRowView' does not contain a property with the name 'IsVisible'."Sasmi
|
|
|
|
|
Modify the gridview code where you set the visible property like this.
Visible='<%# IsVisible %>'
|
|
|
|
|
Yes,
Thanks now it working fine....
can i access any class property using this syntex?
Thank you very muchSasmi
|
|
|
|
|
hi! i've seen that you've solved your problem. but you can use also
<%=Server.HtmlEncode(IsVisible) %> when you use IsVisible function to return a string (parse true to "true" and false to "false")
|
|
|
|
|
Hi,
I am trying to use the Sqlcachedependency in my application but am getting error...
step1) Enabled notification service of the database
step2) enabled notification service of the Table
step3) coding in asp.net2.0
protected void Page_Load(object sender, EventArgs e)
{
if (Page.IsPostBack == false)
{
DataTable tbl1 = new DataTable();
tbl1 = (DataTable) Cache.Get("tbl");
if (tbl1 == null)
{
tbl1 = fnloadgrid();
lbl.Text = System.DateTime.Now.ToString();
}
grd.DataSource = tbl1.DefaultView;
grd.DataBind();
}
}
public DataTable fnloadgrid()
{
if (Con.State == ConnectionState.Closed)
{
Con.ConnectionString = Constr.ConnectionString;
Con.Open();
Cmd.Connection = Con;
Cmd.CommandType = CommandType.StoredProcedure;
Cmd.CommandText = "Sp_Select";
Cmd.Parameters.Add("@Tabid", SqlDbType.Int).Value = 1;
SqlCacheDependency Depend = new SqlCacheDependency(Cmd);
Da.SelectCommand = Cmd;
Da.Fill(Ds, "tbl");
tbl = Ds.Tables[0];
Cache.Insert("tbl", tbl, Depend);
}
return tbl;
}
note: while filling am getting error like as follows,
Notifications require SQL Server 9.0 or later.
so what is this Error ..can u clear me plz.......?
Regards,
kannak.......kannak
|
|
|
|
|
sekannak wrote: Notifications require SQL Server 9.0 or later
Means that you'll need SQL Server 2005, or newer. Are you running SQL Server 2000 by any chance?I are Troll
|
|
|
|
|
Hi Everyone,
I have hosted my appication in IIS,some of my PDF files are in other system.but before configuring in IIS its working fine.my questionis how to acces PDF files after hosting in IIS. My Path is some thing like this..
\\inlogicpc17\dotnetkanna\test.pdfRegardsKanna
Rgrds
Kanna
|
|
|
|
|
Are the files you are trying to access on another server? If so are they on the same domain?
|
|
|
|
|
Thnks.
Its not in another server.it will be in another machine.for example another machine d:test.pdf ,This machine will be connected as network.
|
|
|
|
|
|
Hey,
does any one know what might clear a session?
i have a session that is automatically cleared when i click on a hyperlink.
i couldn't trace the problem , since no event for a hyperlink.
the hyperlink is only redirecting me to another page.
I didn't clear the session in any of my codes. however it's cleared when i click on the hyperlink.
Thanks for you help.
Rana
|
|
|
|
|
By default session will be automatically cleared after 20 min of unusage.
In your case are you sure you are not assigning new value for the session in the page load?
|
|
|
|
|
Sure i am not.
sometimes it works from the first click(the session is not cleared),
but after the second click it is cleared !!!
|
|
|
|
|
try to put a link button instead of hyperlink and trace
the code to see where the session is being cleared
|
|
|
|
|
badre!!!
I already tried it.
|
|
|
|
|
ya none at least ana bronze
|
|
|
|
|
heheheh
nice one
|
|
|
|
|
Hi,
How to open excisiting excel document in asp.net??Yours,
KaNNaN
-----------------------------------------------------------------
"Success is When Ur Signature Becomes An Autograph"
|
|
|
|
|
You can read excel into a dataset and then can dispay it easily using grid view of whatever control you prefer.
int workSheetNumber = 0;
OleDbConnection ExcelConnection = new OleDbConnection(@"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + FilePathWithName + ";Extended Properties=Excel 8.0;");
OleDbCommand ExcelCommand = new OleDbCommand();
ExcelCommand.Connection = ExcelConnection;
OleDbDataAdapter ExcelAdapter = new OleDbDataAdapter(ExcelCommand);
ExcelConnection.Open();
System.Data.DataTable ExcelSheets = ExcelConnection.GetOleDbSchemaTable(System.Data.OleDb.OleDbSchemaGuid.Tables, new object[] { null, null, null, "TABLE" });
string SpreadSheetName = "[" + ExcelSheets.Rows[workSheetNumber]["TABLE_NAME"].ToString() + "]";
DataSet ExcelDataSet = new DataSet();
ExcelCommand.CommandText = @"SELECT * FROM " + SpreadSheetName;
ExcelAdapter.Fill(ExcelDataSet);
|
|
|
|
|
Hello,
Please help i want to add update and delte data from the specified table.I m using Gridview and i want to to add data in grid when add button is clicked and also edit it on edit button. It same as we do in windows app (i.e., is add data in specify cells and click on save button to save the data in table.)Please help its urgent?
|
|
|
|
|