sdom100
asked on
Implement a sliding window textbox
Hi,
I am looking for the most efficient way to create a textbox to monitor comms data.
I need to limit it's size to 100 lines so when a new line arrives, it is added to the bottom and if the no. lines in the textbox >100 the first one is removed.
The behaviour would be similar to that of the hyperterminal window (cant see all data just latest x lines).
I need to do this in a highly performant manner.
Please advise on the best way to go about it. ps. not wedded to a text box so use another control if it suits.
(using visual studio 2005)
thanks.
Shaun
I am looking for the most efficient way to create a textbox to monitor comms data.
I need to limit it's size to 100 lines so when a new line arrives, it is added to the bottom and if the no. lines in the textbox >100 the first one is removed.
The behaviour would be similar to that of the hyperterminal window (cant see all data just latest x lines).
I need to do this in a highly performant manner.
Please advise on the best way to go about it. ps. not wedded to a text box so use another control if it suits.
(using visual studio 2005)
thanks.
Shaun
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Hard to say without testing, but I'd say the difference is minimal; the same mechanisms are used in both cases.
ASKER
Which is most efficient ? (this way or using binding as per your suggestions) ?
Thanks,
Shaun