![]() |
| |||||||
| Sponsored Links |
![]() | « Previous Thread | Next Thread » |
| | LinkBack | Thread Tools | Display Modes |
|
#1
| ||||
| ||||
| hi i m displaying list of records with edit and delete button.code is here Code: If(Not rstSettings.EOF) then
While Not rstSettings.EOF
lCounter = lCounter + 1
StrDisplay = StrDisplay & "<TR class=""Row" & lCounter Mod 2 & """>"
StrDisplay = StrDisplay & "<TD align=""left"">"& rstSettings("ProtocolSettingNo")&"</TD>"
StrDisplay = StrDisplay & "<TD align=""left"">"& rstSettings("DocumentTypeNo")&"</TD>"
StrDisplay = StrDisplay & "<TD align=""left"">"& rstSettings("DocumentFormatNo")&"</TD>"
StrDisplay = StrDisplay & "<TD align=""left"">"& rstSettings("PartnerID")&"</TD>"
StrDisplay = StrDisplay & "<TD align=""left"">"& rstSettings("SettingValue")&"</TD>"
StrDisplay = StrDisplay & "<TD align=""right"" colspan=""2""><input type=""button"" name='btnEdit_"& vlMemberID &"' value=""Edit"" onClick=""fnNextPage('"& vlMemberID &"','"& Server.URLEncode(rstSettings("ProtocolSettingNo")) &"');"">"
StrDisplay = StrDisplay & "<input type=""button"" name='btnDelete_"& vlMemberID &"' value=""Delete"" onClick=""fnDelete('"& vlMemberID &"','"& rstSettings("ProtocolSettingNo") &"','"&rstSettings("DocumentTypeNo")&"','"&rstSettings("DocumentFormatNo")&"','"&rstSettings("PartnerID")&"','"&rstSettings("SettingValue")&"');""></TD>"
StrDisplay = StrDisplay & "</TR>"
rstSettings.MoveNext
Wend
Set objData = nothing
Set rstSettings = nothing
Else
StrDisplay = StrDisplay & "<TR class=""Row1"" ><TD Colspan=7><font color=red><B>No Protocol Settings Found.<B></TD></TR>"
End If
how to do this?
__________________ Love is physical attraction and mental destruction |
| Sponsored Links |
|
#2
| ||||
| ||||
| Unless you want to have several requests to the server, your best bet would be to use JavaScript. If you want to use JavaScript, this thread can be moved to the appropriate forum.
__________________ jmurrayhead If you agree with me... click the icon! If my post solved your problem, click the button in the lower right-hand corner of the post.Join our Folding team: DeveloperBarn Folding |
|
#3
| ||||
| ||||
| i dont mind for javascript bcoz the solution is going to give by you guys only. cheers!! |
|
#4
| ||||
| ||||
| First, have your ASP generate textboxes inside each cell and set their display property to none. The resulting markup should look something like this: Code: <tr>
<td><span id="textcolumn1row1">Some text</span></td>
</tr>
Code: <tr>
<td><span id="textboxcolum1row1"><input type="text" id="textbox1" /></td>
</tr>
Keep in mind that each <span> must have a unique ID that you can use to pass to the function. |
| The Following User Says Thank You to jmurrayhead For This Useful Post: | ||
guddu (August 20th, 2008) | ||
|
#5
| ||||
| ||||
| hi in this line i m getting javascript syntax error Code: StrDisplay = StrDisplay & "<TD align=""left""><span id='txtRow_"& lCounter &"'>"& rstSettings("SettingValue")&"</span><span style=""display:none"" id='txtBoxRow_"& lCounter &"'><input type=""text"" value="""& rstSettings("SettingValue") &""" name='txtBoxRow_"& lCounter &"' ></span></TD>"
|
|
#6
| ||||
| ||||
| sorry not a error .JMH this is the what u said to do me? now next? |
|
#7
| ||||
| ||||
| hi now i javascript function i written this code Code: document.getElementById("txtRow_" + vlCounter ).style.display = "none";
document.getElementById("txtBoxRow_" + vlCounter ).style.display = "";
|
|
#8
| ||||
| ||||
| So you'll need something like this: Code: function makeVis(textSpanID,boxSpanID,action) {
if action == "edit"
{
document.getElementById(textSpanID).style.display = "none";
document.getElementById(boxSpanID).style.display = "inline";
}
else
{
document.getElementById(textSpanID).style.display = "inline";
document.getElementById(boxSpanID).style.display = "none";
}
}
|
|
#9
| ||||
| ||||
| that is already i have done.let me try whole stuff now.catch u later. Thanks a lot. |
|
#10
| ||||
| ||||
| forgot to ask u after submit how i will get value of name='txtBoxRow_"& lCounter &"' this text box Request.form("'txtBoxRow_")? |
![]() |
|
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| [Forms] Field that is a link (rs) and/or text field question | Rebelle | ASP Development | 14 | August 12th, 2008 08:43 AM |
| Text or List option plus | Rebelle | JavaScript Programming | 8 | June 17th, 2008 12:27 PM |
| text display problem | todd2006 | HTML & CSS Help | 10 | May 7th, 2008 08:14 PM |