|
I've been trying to do the same thing (also in "classic ASP"). Ever figure it out? I'm going to keep working on it and will let you know if I come up with a solution.
Paul
|
|
|
|
|
I am displaying a GridView on some specific criteria which is entered by some textboxes say studentid, studentname as input from textbox and show records in GridView.
For this I m using a stored procedure which returns a datatable based on inputs came from textboxes.
I want an Edit button in the Gridview on click of which a with some label and textbox controls get displayed with prefilled entries.
For this I want the datarow from the datatable got from the stored procedure, from where I will get the complete info. Also I want to edit the data.
How can I get the row details of specified Edit button row and which way is better put a command button control in ItemTemplate of GridView or use a Buttonfield cotnrol inside the GridView?
I am working in ASP.NET2.0 and C#.
I m not getting the correct way, can anybody suggest me?
Thanks in advance,
|
|
|
|
|
I am displaying a GridView on some specific criteria which is entered by some textboxes say studentid, studentname as input from textbox and show records in GridView.
For this I m using a stored procedure which returns a datatable based on inputs came from textboxes.
I want an Edit button in the Gridview on click of which a with some label and textbox controls get displayed with prefilled entries.
For this I want the datarow from the datatable got from the stored procedure, from where I will get the complete info. Also I want to edit the data.
How can I get the row details of specified Edit button row and which way is better put a command button control in ItemTemplate of GridView or use a Buttonfield cotnrol inside the GridView?
I am working in ASP.NET2.0 and C#.
I m not getting the correct way, can anybody suggest me?
Thanks in advance,
|
|
|
|
|
You can edit a particular datagrid row using EditCommand event of the datagrid.
i attach code below:
private void Edit_DataGrid(object source,System.Web.UI.WebControls.DataGridCommandEventArgs e)
{
// We use CommandEventArgs e to get the row which is being clicked
// This also changes the DataGrid labels into Textboxes so user can edit them
myDataGrid.EditItemIndex = e.Item.ItemIndex;
// Always bind the data so the datagrid can be displayed.
}
thankyou
Rasma
|
|
|
|
|
To use RowDataBound to find Id in each row:
<asp:gridview allowpaging="true" pagesize="5" autogeneratecolumns="false" id="GridView1" runat="server" datasourceid="SqlDataSource1" onrowdatabound="GridView1_RowDataBound">
<columns><asp:boundfield datafield="studentid" headertext="Student ID">
<asp:boundfield datafield="Name" headertext="Name">
In code behind:
protected void Page_Load(object sender, EventArgs e)
{
//Accepting the Id of a clicked row.
string id = Convert.ToString(Request.QueryString["id"]);
}
protected void GridView1_RowDataBound(object sender, GridViewRowEventArgs e)
{
if (e.Row.RowType == DataControlRowType.DataRow)
{
string id = e.Row.Cells[0].Text.ToString();
e.Row.Attributes["onclick"] = "window.navigate('samewebpage.aspx?id=" + id + ")";
}
}
you can access id from page load, reading the entire data of corresponding id using datatable or datareader and display the contents in a textbox or label.
Thankyou,
Rasma
|
|
|
|
|
I'm trying to show japanese character on the page and to sent mail.
To show on the screen, I've to save as the following format in SQL Server.
"
ƒtƒBƒŠƒbƒvØŒ"ƒIƒ"ƒ‰ƒCƒ"ŒûÀ\‚µ "
and use encoding "shift-jis".
It is showing correctly at browser.
But if I send mail that message, it can't be shown on some mail.
eg. gmail and hotmail can show but yahoo can't show correctly.
If I store as the following format in SQL Server, it can show correctly on most of the web mail.
"
& #12458 ; & #12531 ; & #12521 ; & #12452 ; & # 12531 ; & #21475 ; & #24231 ;
"
Can anybody explain about these formats?
Can anybody advice me for the best practise dealing with unicode character?
I would like to use same format to show and to send for unicode character.
I'm using classic ASP for server side script.
Thanks in advance,
Mann Khine
|
|
|
|
|
Have you tried using nvarchar columns in your database?
Bob
Ashfield Consultants Ltd
|
|
|
|
|
Yes Bob,
I used nvarchar columns.
|
|
|
|
|
Just a thought, suspected you already had. Could it be the format of the mail message? I know there are problems with extended charater sets when the email client only displays plain text.
Bob
Ashfield Consultants Ltd
|
|
|
|
|
HI
anybody has a sample program (with VBscript or JAVAscript) to read from an XML file to a simple form (include a text field and a check-box or radio-button) and load dat of these controls and then save changes again on XML file by pressing a "save" button.
I need for classic ASP (not ASP.NET)
thank you
|
|
|
|
|
What a nightmare.
There's a COM object that manipulates XML, from memory, a DOM implimentation that is probably part of IE. I seem to recall that's what I used when I Was trapped in the hell of 'classic' ASP.
Christian Graus
Please read this if you don't understand the answer I've given you
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Guys,
If this is not the right place pardon me and tell me the right forum.
I just want to know if there is a limitations when sending email using Microsoft ESMTP mail server for TO and CC recipients. my web page is sending around 30-40 recipients in TO and 20-30 recipients in CC (email address) for notification?
When I tried to check our application server there was no error on the application event and it seems that the message was sent ok but after 1 hr of waiting no mails arrived in our inbox. Is there any constraints?
If I used the same number of email add using the microsoft outlook it works fine though outlook is using a different email server.
Hope to hear from you soon, our users are already complaining because it is a real-time notification and they reply on this process.
Regards
Dabsukol
|
|
|
|
|
Did you check your MailQueue folders on the server for any BadMail? Any messages in the eventlog?
Vasudevan Deepak Kumar
Personal Homepage Tech Gossips
All the world's a stage,
And all the men and women merely players.
They have their exits and their entrances;
And one man in his time plays many parts... --William Shakespeare
|
|
|
|
|
Hi all,
I m a Software Developer, now working on VC++ 2005, i dont have any idea about web development.
I want to know the procedure for developing a web site.
please help me for this.
Thanks in advance.
IN A DAY, WHEN YOU DON'T COME ACROSS ANY PROBLEMS - YOU CAN BE SURE THAT YOU ARE TRAVELLING IN A WRONG PATH
|
|
|
|
|
ThatsMe. wrote: i dont have any idea about web development
Employ someone who does.
ThatsMe. wrote: I want to know the procedure for developing a web site
What type of site do you want, what language do you want to use etc etc - try Google for some books/articles, its a massive subject.
Bob
Ashfield Consultants Ltd
|
|
|
|
|
|
Do you know any web programming (PHP, ASP)? Do you know any .NET programming (ASP.NET)?
If you have use VC++2005, you must be familiar with .NET, try ASP.NET.
The process of web development is similar to software development. The difference is how you code.
|
|
|
|
|
How did you learn C++ ? Did you take a class, or buy a book ? Buy a book on C#, learn it. Then buy an ASP.NET book, in C#, and learn that.
Christian Graus
Please read this if you don't understand the answer I've given you
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Hi,
please how do i disable menu items in menu controls in visual studios 2005.
Thanks.
modified on Friday, June 6, 2008 6:55 AM
|
|
|
|
|
if there is no event working on menu item then it is already disabled.
IN A DAY, WHEN YOU DON'T COME ACROSS ANY PROBLEMS - YOU CAN BE SURE THAT YOU ARE TRAVELLING IN A WRONG PATH
|
|
|
|
|
use EnableMenuItem from CMenu.
IN A DAY, WHEN YOU DON'T COME ACROSS ANY PROBLEMS - YOU CAN BE SURE THAT YOU ARE TRAVELLING IN A WRONG PATH
|
|
|
|
|
My need to display all dates of 1 or 2 months previous from current dates
means if current date is 01-06-2008 then all date between 01-05-2008 to 01-06-2008. How can i do it.
sanjeev
|
|
|
|
|
A calender control? Its easy enough to generate the dates, how you want ot display them is up to you.
Bob
Ashfield Consultants Ltd
|
|
|
|
|
thanks for
i got it working by this code
<%For dt = DateAdd("m",-1,Date())To Date()
Response.Write dt & "<br/>" & vbNewLine
Next %>
regards
jha
sanjeev
|
|
|
|
|
I would like to know how to run media play on the web. I can create the file but in order for the customer to view the movie it has to be downloaded to their PC then played. How can I get it to play on the web?
Lonnie R Thomas
|
|
|
|