RowEditor Plugin with Custom Search Box focus problem

  1. #1

    RowEditor Plugin with Custom Search Box focus problem

    I am using RowEditor Plugin in a GridPanel. If someone choose the value from list (Custom Search Box) in RowEditor Plugin which is already exist then it will showing a confirmbox. If we choose "NO" button the it will clear the value of Custom Search Box and focus it.

    ..........
    ..........
    <Editor>
    	<ext:ComboBox ID="Combobox1" runat="server" DisplayField="isin" ValueField="isin" TypeAhead="false" LoadingText="Loading..." PageSize="10" HideTrigger="true" ItemSelector="div.search-item" MinChars="1">
    		<Store>
    			<ext:Store ID="Store2" runat="server" AutoLoad="false">
    				<Proxy>
    					<ext:HttpProxy Method="GET" Url="AutoCompleteHandler.ashx" />
    				</Proxy>
    				<Reader>
    					<ext:JsonReader Root="employees" TotalProperty="total">
    						<Fields>
    							<ext:RecordField Name="empno" Mapping="EmpNo" />
    						</Fields>
    					</ext:JsonReader>
    				</Reader>
    			</ext:Store>
    		</Store>
    		<Listeners>
    			<Select Handler="checkValue(this.value);" />
    		</Listeners>
    		<Template ID="Template1" runat="server">
    		   <Html>
    			   <tpl for=".">
    				  <div class="search-item">
    					 <h3>{empno}</h3>
    				  </div>
    			   </tpl>
    		   </Html>
    		</Template>
    	</ext:ComboBox>
    </Editor>
    ..........
    ..........
    
    <ext:XScript ID="XScript1" runat="server">
    	<script type="text/javascript">
    		var checkValue = function(empno) {
    			Ext.net.DirectMethods.CheckValue(empno, {
    				success: function (result) {
    					if (result)
    					{
    						Ext.Msg.confirm("Message", "If you continue then it will be over written", function (btn, text) {
    							if (btn == 'no') {                                   
    								rowEditor.on("show", function () {
    									Combobox1.focus(true, true);
    								});
    							}
    						});
    					}
    				},
    		
    				failure: function (errorMsg) {
    					Ext.Msg.alert('Error - ', errorMsg);
    				}
    			});
    		}
    	</script>
    </ext:XScript>
    Please help me
    Attached Thumbnails Click image for larger version. 

Name:	screenshot.JPG 
Views:	107 
Size:	22.7 KB 
ID:	3678  
    Last edited by abhijit; Jan 10, 2012 at 8:54 AM.

Similar Threads

  1. Replies: 1
    Last Post: Dec 21, 2011, 5:32 AM
  2. Custom button on RowEditor plugin
    By mirzasa in forum 1.x Help
    Replies: 2
    Last Post: May 17, 2011, 10:42 AM
  3. [CLOSED] Focus Problem in EditableGrid Plugin
    By kemalyigit in forum 1.x Legacy Premium Help
    Replies: 4
    Last Post: Jan 18, 2011, 6:00 PM
  4. [CLOSED] GridPanel RowEditor Plugin problem with AutoHeight
    By SFritsche in forum 1.x Legacy Premium Help
    Replies: 1
    Last Post: Jul 21, 2010, 10:48 PM
  5. [CLOSED] [1.0] GridPanel RowEditor Plugin ValidateEdit problem
    By kemalyigit in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: Apr 29, 2010, 10:51 AM

Posting Permissions