와 데이터 세트 직렬화 때 아래오류 protobuf - 순 나는 데이터 집합을 직렬화 protobuf - 그물을 사용하려고하지만, 아래의 오류가 무엇입니까
Unhandled Exception: System.InvalidOperationException: No suitable Default DataSet encoding found. at ProtoBuf.Serializer.ThrowNoEncoder(DataFormat format, Type valueType) at ProtoBuf.Property.PropertyFactory.CreateProperty[T](Type type, DataFormat& format, MemberSerializationOptions options)
at ProtoBuf.Property.PropertyFactory.Create[T](MemberInfo member) at ProtoBuf.Serializer`1.Build()
코드를 사용하고
[ProtoContract]
public class Packet
{
[ProtoMember(1)]
public DataSet Data { get; set; }
[ProtoMember(2)]
public string Name { get; set; }
[ProtoMember(3)]
public string Description { get; set; }
}
using (var fs = new FileStream("test0.txt", FileMode.Create))
{
Serializer.Serialize(fs, packet);
Console.WriteLine("Total bytes with protobuf-net = " + fs.Length);
}