|
How can i use Datagrid for displaying as well as select an item from the datagrid list.
If i display Id,name and i need to update using one selected row from the datagrid,How to do this.
this updation will be done in the other page.My problem is how to select from the datagrid,i know only how to display,but i need how to select from the DataGrid.
Help me out.
Thanks in advance.
kissy
|
|
|
|
|
Sir,
This reply is not concerned with ur query .This is concerned with ur previous query.
U can i think display the the columns .use table tag in the drop downlist class.use three td tags in one tr tag and finally bind it.
Hope it can help u.
Thanks
|
|
|
|
|
Ur updation should be done in another page.
U fist store ur datakey value in session.
call that session on another page and retrive the datakey value.
by taking this datakey value as a referece,
Create on function for updation of data and pass on parameter to that function.
And now assign this datakey value to that parameter
for. e.g. Public Shared Function (ByVal Id as Integer) as boolean
before this function assign "Session value" to "Id".
Ok ?
Bye ?
Hope u will get answer.
prakash sawant
|
|
|
|
|
Different ways - depends on what you want to do after the selection:
(1) Add a checkbox/radio button to each row. Add a button to the page. Once user clicks on the button, check which row(s) were selected.
(2) Add a select column to the grid. If you are using .Net 1.x, then add a command column and set text to Select.
Shreekar
http://shreekarishere.blogspot.com
|
|
|
|
|
|
iam using c# asp.net and i want to retrieve the system date and put date in text box
any ideas highy appreciated
|
|
|
|
|
You can get that like this:
DateTime.Now
Best Regards,
Apurva Kaushal
|
|
|
|
|
thank u kaushal
thing is i want to display only date is it possible
|
|
|
|
|
Yes you can display the date part by converting it into shortdatestring. Like this:
DateTime.Now.ToShortDateString();
Best Regards,
Apurva Kaushal
|
|
|
|
|
TextBox.Text=DateTime.Now.ToString()
Regards,
Jay
|
|
|
|
|
Unfortunetly, the last two responses are only partially correct.
Here is the code:
First, your cs file;
<code>using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
public partial class _Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
tbalpha.Text = DateTime.Today.ToShortDateString();
tbalpha.ReadOnly = true;
}
}</code>
Then your HTML/source page
<code><%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>Untitled Page</title>
</head>
<body>
<form id="form1" runat="server">
<asp:TextBox ID="tbalpha" runat="server" />
</form>
</body>
</html>
</code>
"We've all heard that a million monkeys banging on a million typewriters will eventually reproduce the entire works of Shakespeare. Now, thanks to the internet, we know this is not true." -- Professor Robert Silensky
|
|
|
|
|
TextBox1.Text = DateTime.Now.ToString("yyyy.MM.dd");<br />
|
|
|
|
|
Hi,
I need help.
Here we are developing a web application ( using C# ). in that I need to drag and drop the items of a datagrid.
What I need exactly is
If I put the cursor anywhere in a row that row must be selected. ( Without using CheckBoxes, item template column )
Then if I drag the selected row over another row, those two rows must be swapped.
Try to send me some code snippets if possible.
Thanks in advance,
Libran
|
|
|
|
|
Hi,
I am developing a web application. Here I need to drag the rows of a datagrid. Plese anyone send me some examples or some links.
Thanks in advance,
Libran
|
|
|
|
|
i can create a text file in my project that it is full of iformation(asp.net(c#)) but now i want edit that file and fine a word from content of that file how can i do it? can any body help me
|
|
|
|
|
Read from file into a string and use the shared Contains method to find required word.
Hope this helps.
Shreekar
http://shreekarishere.blogspot.com
|
|
|
|
|
can u explain a little more plz
|
|
|
|
|
dim f as new file = File.OpenText(filepath)<br />
dim s as string = f.readall<br />
if s.Contains(wordtosearch) Then<br />
' do something<br />
End If
Shreekar
http://shreekarishere.blogspot.com
|
|
|
|
|
Hello,
I'm amking a project in asp.net with vb.users come on my site and make their own site.i want to make a report that how much bandwidth they are using.
not getting how to do this.
Any suggestion plz thanx.
|
|
|
|
|
Hi All,
Please provide me some sample programs on DrillDown Reports.
Sowmya C
|
|
|
|
|
i want to save Audio and Video Files To the Database and And Later i want to play that Files how to do that in ASP.NET
sdfsdf
|
|
|
|
|
As for saving the files, u don't save the auio file to the database, u just save its path on the server so what u need is to upload the file on the server in a path using any file upload script then u play it calling it from it's path
Best Regards
3ala2
|
|
|
|
|
Hi,
I think you must use Windows Media Services for online play audio and video file's. I'm not recommend save audio and video file's in DB. I think you must save path to file's in DB.
|
|
|
|
|
hi,
friends i m facing problem in binding dropdown listbox with two tables. table A and table B. i m succeeed in reterieving data frm both tables in a dropdown listbox but not able to fatch their id's. and i want that content of table A is parent & contant of table B is child, means first comes parent then in next row its child content will com from second table who's id is same as of parent id.
pls help me .
waiting for rply.
thanx
bye.
rahul saini
|
|
|
|
|
What is the query you are using and what is the output that you require?
Post some code, that will help us help you.
Shreekar
http://shreekarishere.blogspot.com
|
|
|
|