Bagikan melalui


StrokeCollection.InkSerializedFormat Bidang

Definisi

Mewakili format persistensi asli untuk data tinta.

public: static initonly System::String ^ InkSerializedFormat;
public static readonly string InkSerializedFormat;
 staticval mutable InkSerializedFormat : string
Public Shared ReadOnly InkSerializedFormat As String 

Nilai Bidang

Contoh

Contoh berikut menunjukkan cara menyalin StrokeCollection ke Clipboard. Contoh menentukan bahwa StrokeCollection ada dalam Format Serial Tinta (ISF), sehingga program lain, seperti Microsoft Office Word dapat menerima data yang disalin.

public void CopyStrokeCollection(StrokeCollection strokes)
{
    MemoryStream strokesInMemory = new MemoryStream();
    strokes.Save(strokesInMemory);
    
    DataObject dataobj = new DataObject(StrokeCollection.InkSerializedFormat,
        strokesInMemory);

    Clipboard.SetDataObject(dataobj, true);
}
Public Sub CopyStrokeCollection(ByVal strokes As StrokeCollection)

    Dim strokesInMemory As New MemoryStream()
    strokes.Save(strokesInMemory)
    Dim dataObj As New DataObject(StrokeCollection.InkSerializedFormat, _
                strokesInMemory)

    Clipboard.SetDataObject(dataObj, True)

End Sub

Keterangan

InkSerializedFormat Gunakan bidang untuk menentukan format StrokeCollection saat Anda mentransfer data, seperti saat Anda menyalin StrokeCollection ke Clipboard.

Berlaku untuk