View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
Bob Phillips[_6_] Bob Phillips[_6_] is offline
external usenet poster
 
Posts: 11,272
Default Dynamic update of UserForm TextBox

Tom,

Haven't monitored a serial port myself, but you could try this.

Private Sub Worksheet_Change(ByVal Target As Range)

If Target.Address = "$A$1" Then
UserForm1.TextBox1.Text = Target.Value
End If

End Sub

Add it to sheet1 code module.

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"Tom_C " wrote in message
...
Bob,

Thank you for your quick response. What I have is a DDE Server picking
up measurements from the COM port. With this formula
(=SIPART|'DR24'!SAA8) in cell "A1" I can continuously monitor
measurements. SIPART being the application (server) and DR24 the item
and SAA8 the point name (SAA8 means serial analog output #8).

With the TextBox1 (below) I can get one update from cell "A1" into my
userform everytime I press the backspace. (and of course I am in the
textbox). I would like the textbox to update continuouly without my
interaction. There could be of course a button that starts continuous
monitoring and stops it.

Private Sub TextBox1_Change()
TextBox1.Value = Worksheets("Sheet1").Range("A1")
End Sub

Thanks.

Tom


---
Message posted from http://www.ExcelForum.com/