p2p.wrox.com Forums

Need to download code?

View our list of code downloads.


  Return to Index  

aspx thread: Editing an item in a DataList, but changing its value in a functi on?


Message #1 by "Oliver, Wells" <WOliver@l...> on Wed, 17 Jul 2002 14:50:58 -0700
This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.

------_=_NextPart_001_01C22DDC.09179270
Content-Type: text/plain;
	charset="iso-8859-1"

I have a datalist with an Edit button. Upon clicking on it, the user is
provided w/ the text boxes to edit.

However, I want to change a value of the textbox beforehand, so that the <br
/> tags are changed to \n characters.

My item edit sub is:

	Public Sub DoItemEdit (S as System.Object, E as
DataListCommandEventArgs)
	' Edit a record
		dlMessages.EditItemIndex = E.Item.ItemIndex
		E.Item.FindControl ("POSTTEXT").Text = "Err"
		BindData ()
	End Sub

That doesn't work. Can anyone suggest a way to edit the value of the textbox
before presenting it to the user? Thanks!

Wells Oliver
Web Application Programmer
Leviton Voice & Data
xxx-xxx-xxxx
http://www.levitonvoicedata.com 


  Return to Index