Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
3/12/2014
Constructs a Generic Data Acceptor that will fill a TextBox control.
Namespace: Microsoft.RemoteToolSdk.PluginComponents
Assembly: Microsoft.RemoteToolSdk (in microsoft.remotetoolsdk.dll)
Syntax
public GenericDataAcceptor (
TextBox textBox
)
'Declaration
Public Sub New ( _
textBox As TextBox _
)
Parameters
- textBox
TextBox control to populate with the data passed into this object.
Example
The following example function populates a TextBox control with data from a plugin data object.
void FillTextBoxFromDataObject(
TextBox tb,
PluginData data
)
{
//
// Suspend drawing for flicker free fun
//
tb.BeginUpdate();
//
// Start with a clean slate
//
tb.Text = "";
//
// Build a Generic Data Acceptor that receives the data from
// the data object.
// The acceptor is given the TextBox control, and it knows
// how to fill it.
//
GenericDataAcceptor acceptor = new GenericDataAcceptor(tb);
//
// Call upon the data to feed the strings to the
// data acceptor.
//
data.RenderGeneric(acceptor);
//
// Resume drawing.
//
tb.EndUpdate();
}
See Also
Reference
GenericDataAcceptor Class
GenericDataAcceptor Members
Microsoft.RemoteToolSdk.PluginComponents Namespace