c#


asp:Textbox off focus?


I want to save the contents of a multline textbox when off focus - i.e. user has finished typing and clicks outside the textbox so it goes off focus.
I can handle the saving- thats no problem, but is there an off focus function?
I don't mind a javascript version. I must be using asp:TextBox though.
I tried with onFocus, OnServerChange, onKeyUp, but it is not exactly how I want it.
If any of you use Facebook, then it is like the textbox displayed right below the profile picture.
OnBlur :)
<asp:TextBox runat="server" onblur="alert(1);" />
(I can't recall, off the top of my head, if it will write any unknown server property to the client, I think it does, but if it doesn't, you'll need to add it as an attribute, in code).
-- Edit:
Confirmed that it does, indeed, happily write out unknown properties (onblur is not a property of TextBox control, but it will render in the HTML, so it works).
A multiline textbox should render to a textarea element. Assign an event handler to its onBlur event, and you should be good.

Related Links

Maintain HTML encoding when processing RSS XML via XSLT
How to force a listbox to always have at least one item selected and highlighted?
Locking VSS progammatically
Allow null value when parsing file to datatable
C#: Replace a single / with a *single* \
How can i find what is missing at run time that makes my application crash?
Refresh ListView grouped items
Starting a windows service on remote machine in different domain
Double value not correct on Device
What would be the best and easiest way of getting currency rates within SharePoint (Custom Actions) or C# project
Decimal.Parse Issue
Route patterns vs individual routes
Why entity framework isn't implement identity map with unit of work?
How to wrap a thread unsafe class into one that is thread safe without wrapping each member function
Read console output while program is running c#
How to run a for loop after a for loop?

Categories

HOME
model-view-controller
system-calls
microcontroller
gaussian
stdout
redhawksdr
crash
mailchimp
browser-cache
revit-api
wkhtmltopdf
angularjs-ng-repeat
lambda-calculus
web-worker
ringcentral
android-actionbar
rndis
matlab-gui
devexpress-mvc
sqldependency
ipython-parallel
ios9
arp
textview
spring-oauth2
eclipse-jdt
availability
extern
aspose.pdf
ui-grid
definition
qt-quick
codepen
emacs24
ear
wink
playframework-2.3
jtextarea
multi-select
disassembly
scrollmagic
ownership
disconnect
deck.js
tinybox2
netlink
jigsaw
falcon
database-administration
boost-propertytree
wizard
producer-consumer
event-tracking
transbase
tooltwist
pagecontrol
web-standards
grails-3.0.9
copy-on-write
gmaps4jsf
accpac
jad
apache-pivot
yosemite
sat4j
triplestore
xpand
nodeunit
mixradio
data-layers
nativequery
objectdatasource
record-locking
windows-scheduler
mysql2
reference-manual
blotter
freeimage
tasklist
mail-gem
motordriver
webpage-screenshot
django-admin-tools
win-prolog
digg
jquery-attributes
versions
lts
morfik
manuals
high-load

Resources

Mobile Apps Dev
Database Users
javascript
java
csharp
php
android
MS Developer
developer works
python
ios
c
html
jquery
RDBMS discuss
Cloud Virtualization
Database Dev&Adm
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App