//==================================================
//功能: 根據焦點位置信息設置滾動文本框焦點
//輸入參數:
//?_mOffset ??滾動文本框對象
//?_OffsetObject?焦點位置信息對象
//返回值:
//?定位滾動文本框焦點
//更新記錄:
//?2007-03-16? 黃建德? 實現設置滾動文本框焦點的基本功能
//?
//==================================================
function setOffsetPointer(_mOffset, _OffsetObject){
?var _allText = _mOffset.value;???????//輸入框的所有值
?_mOffset.focus();??????????//輸入框獲得焦點
?var _tOffset = _mOffset.createTextRange();????//創建輸入框文本對象
?_tOffset.collapse(true);????????//將光標移到頭
?_tOffset.moveStart('character', _OffsetObject.length);?//移動光標到指定長度
?_tOffset.scrollTop = _OffsetObject.scrollTop;???//返回滾動條的原來位置
?_tOffset.select();??????????//顯示光標
}
posted on 2007-03-16 15:43
LORD BLOG 閱讀(1000)
評論(0) 編輯 收藏 所屬分類:
項目筆記