title: vba Find Text box in an application using FindWindowEx
body: <p>I have an <code>MS Access</code> form that contains <code>Button</code> to open an application. The application is created using <code>c#</code>. I want to get the <code>TextBox</code> in the Form so that I will set a value on it using the MS Access project. </p>
  
  <p>I am using the following code:</p>
  
  <pre><code>hwndParent = FindWindow(vbNullString, "Form1")
  
  If hwndParent &lt;&gt; 0 Then
     TextBoxHandle = FindWindowEx(hwndParent, 0&amp;, "WindowsForms10.EDIT.app.0.3cb5890_r6_ad1", vbNullString)
     SendMessage TextBoxHandle, WM_SETTEXT, 0&amp;, ByVal strText
  End If
  </code></pre>
  
  <p>Above code is working on my workstation: Windows 10 Pro.</p>
  
  <p>When I open the MS Access in windows 8. it can't find the <code>TextBox</code>.</p>
  
  <p><code>TextBoxHandle</code> always return 0 in Windows 8. I am sure that the issue is with 3rd parameter in <code>FinWindowEx</code>. I used <code>spy++</code> from Microsoft to get the value <code>WindowsForms10.EDIT.app.0.3cb5890_r6_ad1</code> cause when I try to just enter <code>"Edit"</code>, it does not work.</p>