Implemented interface member:
method
SetData
System.Windows.Forms.IDataObject.SetData(System.String, System.Boolean, System.Object)
29 references to SetData
System.Windows.Forms (10)
System\Windows\Forms\Controls\DataGridView\DataGridView.Methods.cs (6)
7427
dataObject.
SetData
(format, autoConvert: false, utf8Stream);
7431
dataObject.
SetData
(format, autoConvert: false, sbContent.ToString());
7726
dataObject.
SetData
(format, autoConvert: false, utf8Stream);
7730
dataObject.
SetData
(format, autoConvert: false, sbContent.ToString());
8142
dataObject.
SetData
(format, autoConvert: false, utf8Stream);
8146
dataObject.
SetData
(format, autoConvert: false, sbContent.ToString());
System\Windows\Forms\OLE\DataObject.cs (4)
84
internal DataObject(string format, bool autoConvert, object data) : this() =>
SetData
(format, autoConvert, data);
149
public void SetDataAsJson<T>(string format, bool autoConvert, T data) =>
SetData
(format, autoConvert, TryJsonSerialize(format, data));
357
SetData
(DataFormats.FileDropConstant, true, strings);
371
SetData
(ConvertToDataFormats(format), false, textData);
System.Windows.Forms.Tests (19)
System\Windows\Forms\DataObjectTests.ClipboardTests.cs (1)
172
dataObject.
SetData
(format, autoConvert, input);
System\Windows\Forms\DataObjectTests.cs (18)
1050
.Setup(o => o.
SetData
(DataFormats.WaveAudio, false, audioStream))
1053
mockDataObject.Verify(o => o.
SetData
(DataFormats.WaveAudio, false, audioStream), Times.Once());
1257
dataObject.
SetData
(DataFormats.Dib, autoConvert: true, image);
1342
dataObject.
SetData
(format, autoConvert, input);
1373
dataObject.
SetData
(format, autoConvert, input);
1410
dataObject.
SetData
(DataFormats.Dib, autoConvert: true, image);
1453
dataObject.
SetData
(format, autoConvert, data);
1488
((Action)(() => dataObject.
SetData
(null, true, new object()))).Should()
1490
((Action)(() => dataObject.
SetData
(null, false, new object()))).Should()
1505
action = () => dataObject.
SetData
(format, true, new object());
1508
action = () => dataObject.
SetData
(format, false, new object());
1516
((Action)(() => dataObject.
SetData
(DataFormats.Dib, false, new Bitmap(10, 10))))
1559
.Setup(o => o.
SetData
(DataFormats.FileDrop, true, It.IsAny<string[]>()))
1562
mockDataObject.Verify(o => o.
SetData
(DataFormats.FileDrop, true, It.IsAny<string[]>()), Times.Once());
1620
.Setup(o => o.
SetData
(DataFormats.Bitmap, true, image))
1623
mockDataObject.Verify(o => o.
SetData
(DataFormats.Bitmap, true, image), Times.Once());
1793
.Setup(o => o.
SetData
(expectedFormat, false, textData))
1796
mockDataObject.Verify(o => o.
SetData
(expectedFormat, false, textData), Times.Once());