For those that are interested, following is the VB.net version.
Add a reference to the UI form inside the autogenerated code of the dockable window:
'''Auto generated code....
Private m_windowUI As DockWindow1
~~~~~~~~~~~~~~~~~~~~~~~~~
'Add this reference here:
Friend ReadOnly Property UI() As DockWindow1
Get
Return m_windowUI
End Get
End Property
~~~~~~~~~~~~~~~~~~~~~~~~
To access, say Textbox1 from a click event in a button, the code is:
Dim addinimpl As DockWindow1.AddinImpl = ESRI.ArcGIS.Desktop.AddIns.AddIn.FromID(Of DockWindow1.AddinImpl)(My.ThisAddIn.IDs.DockWindow1)
Dim window As DockWindow1 = addinimpl.UI
MsgBox(window.TextBox1.Text)
Hope this helps.