user1855437
user1855437

Reputation: 71

How to assign System.Type and object values from c#.net to protobuf

google.protobuf.Type Type = 1;

Using below code I am trying to assign the value which is system.type to WellKnownTypes.Type.

scanParameter.Type = (Google.Protobuf.WellKnownTypes.Type)parameter.ValueDataType;

It is giving me compile time error saying Invalid Cast.

how to handle this

Thanks

Upvotes: 0

Views: 201

Answers (0)

Related Questions