<?xml version="1.0" encoding="utf-8" ?>
<?xml-stylesheet type="text/xsl" href="RSS_xslt_style.asp" version="1.0" ?>
<rss version="2.0" xmlns:WebWizForums="https://syndication.webwiz.net/rss_namespace/">
 <channel>
  <title>Codejock Developer Community : SetFocus error</title>
  <link>http://forum.codejock.com/</link>
  <description><![CDATA[This is an XML content feed of; Codejock Developer Community : Docking Pane : SetFocus error]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Tue, 28 Apr 2026 19:52:20 +0000</pubDate>
  <lastBuildDate>Thu, 11 Jun 2009 11:43:30 +0000</lastBuildDate>
  <docs>http://blogs.law.harvard.edu/tech/rss</docs>
  <generator>Web Wiz Forums 12.04</generator>
  <ttl>360</ttl>
  <WebWizForums:feedURL>forum.codejock.com/RSS_post_feed.asp?TID=14511</WebWizForums:feedURL>
  <image>
   <title><![CDATA[Codejock Developer Community]]></title>
   <url>http://forum.codejock.com/forum_images/codejock-logo.gif</url>
   <link>http://forum.codejock.com/</link>
  </image>
  <item>
   <title><![CDATA[SetFocus error : Possible workaroundThe following...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=14511&amp;PID=49871&amp;title=setfocus-error#49871</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4225">chrisABC</a><br /><strong>Subject:</strong> 14511<br /><strong>Posted:</strong> 11 June 2009 at 11:43am<br /><br />Possible workaround<br><br>The following sort of thing seems to work OK<br><br>Sub AttemptSetFocus(myControl)<br>&nbsp;&nbsp;&nbsp;&nbsp; On Error Goto ERR_SF<br>&nbsp;&nbsp;&nbsp;&nbsp; For X = 1 to 5<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; myControl.SetFocus<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Exit Sub<br>&nbsp;&nbsp;&nbsp;&nbsp; <br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ERR_SF:<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; DoEvents<br>&nbsp;&nbsp;&nbsp;&nbsp; Next<br>End Sub<br><br><br>(Note this is not real code. Just to give the idea).<br>]]>
   </description>
   <pubDate>Thu, 11 Jun 2009 11:43:30 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=14511&amp;PID=49871&amp;title=setfocus-error#49871</guid>
  </item> 
  <item>
   <title><![CDATA[SetFocus error : I have some vb textboxes on a...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=14511&amp;PID=49866&amp;title=setfocus-error#49866</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4225">chrisABC</a><br /><strong>Subject:</strong> 14511<br /><strong>Posted:</strong> 11 June 2009 at 11:02am<br /><br />I have some vb textboxes on a Frame which is on a Tab control. All this is on a Form in an MDI child using DockingPane.<br><br>To move user from one text box to another, I use&nbsp; textbox(x).SetFocus<br><br>This 95% works OK, but sometimes gives error. <br>I think this error is same as if textbox is not enabled or not visible.<br><br>I guess this is a timing error or similar.&nbsp; Most times the SetFocus is fine. But sometimes I guess the DockingPane is busy doing something and the SetFocus gives error.&nbsp;&nbsp; (without the DockingPane it always works OK.)<br><br><br>Any ideas to workaround this?<br>]]>
   </description>
   <pubDate>Thu, 11 Jun 2009 11:02:21 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=14511&amp;PID=49866&amp;title=setfocus-error#49866</guid>
  </item> 
 </channel>
</rss>