Click here to Skip to main content
16,017,297 members
Home / Discussions / C#
   

C#

 
QuestionGet current point in time in recurring time interval. Pin
Member 136084655-Jan-18 2:10
Member 136084655-Jan-18 2:10 
AnswerRe: Get current point in time in recurring time interval. Pin
Ralf Meier5-Jan-18 2:38
mveRalf Meier5-Jan-18 2:38 
AnswerRe: Get current point in time in recurring time interval. Pin
Gerry Schmitz6-Jan-18 7:06
mveGerry Schmitz6-Jan-18 7:06 
QuestionHow to fetch master detail data using EF and LINQ Pin
Mou_kol5-Jan-18 0:15
Mou_kol5-Jan-18 0:15 
AnswerRe: How to fetch master detail data using EF and LINQ Pin
Vincent Maverick Durano5-Jan-18 2:20
professionalVincent Maverick Durano5-Jan-18 2:20 
GeneralRe: How to fetch master detail data using EF and LINQ Pin
Mou_kol6-Jan-18 6:08
Mou_kol6-Jan-18 6:08 
GeneralRe: How to fetch master detail data using EF and LINQ Pin
Vincent Maverick Durano8-Jan-18 15:33
professionalVincent Maverick Durano8-Jan-18 15:33 
QuestionPetaPoco (T4 Template) in .Net Core 2.0 for MSql : - SerializationException in generating Database.cs Pin
J Kaur4-Jan-18 15:18
J Kaur4-Jan-18 15:18 
Hi I am trying to generate petapoco objects in .Net Core class library for MySQL, I have 3 files as
1) Database.tt
2) PetaPoco.Core.ttinclude
3) PetaPoco.Generator.ttinclude

I have changed connection string in Database.tt file, Whenever it trying to save, some error occurs which results in empty Database.cs file.

Here it displays error message like :

Running transformation: System.Runtime.Serialization.SerializationException: Type 'Microsoft.VisualStudio.ProjectSystem.VS.Implementation.Package.Automation.OAProject' in Assembly 'Microsoft.VisualStudio.ProjectSystem.VS.Implementation, Version=15.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' is not marked as serializable.Server stack trace:    at System.Runtime.Serialization.FormatterServices.InternalGetSerializableMembers(RuntimeType type)   at System.Runtime.Serialization.FormatterServices.<>c__DisplayClass9_0.<GetSerializableMembers>b__0(MemberHolder _)   at System.Collections.Concurrent.ConcurrentDictionary`2.GetOrAdd(TKey key, Func`2 valueFactory)   at System.Runtime.Serialization.FormatterServices.GetSerializableMembers(Type type, StreamingContext context)   at System.Runtime.Serialization.Formatters.Binary.WriteObjectInfo.InitMemberInfo()   at System.Runtime.Serialization.Formatters.Binary.WriteObjectInfo.InitSerialize(Object obj, ISurrogateSelector surrogateSelector, StreamingContext context, SerObjectInfoInit serObjectInfoInit, IFormatterConverter converter, ObjectWriter objectWriter, SerializationBinder binder)   at System.Runtime.Serialization.Formatters.Binary.WriteObjectInfo.Serialize(Object obj, ISurrogateSelector surrogateSelector, StreamingContext context, SerObjectInfoInit serObjectInfoInit, IFormatterConverter converter, ObjectWriter objectWriter, SerializationBinder binder)   at System.Runtime.Serialization.Formatters.Binary.ObjectWriter.Serialize(Object graph, Header[] inHeaders, __BinaryWriter serWriter, Boolean fCheck)   at System.Runtime.Serialization.Formatters.Binary.BinaryFormatter.Serialize(Stream serializationStream, Object graph, Header[] headers, Boolean fCheck)   at System.Runtime.Remoting.Channels.CrossAppDomainSerializer.SerializeMessageParts(ArrayList argsToSerialize)   at System.Runtime.Remoting.Messaging.SmuggledMethodReturnMessage..ctor(IMethodReturnMessage mrm)   at System.Runtime.Remoting.Messaging.SmuggledMethodReturnMessage.SmuggleIfPossible(IMessage msg)   at System.Runtime.Remoting.Channels.CrossAppDomainSink.DoDispatch(Byte[] reqStmBuff, SmuggledMethodCallMessage smuggledMcm, SmuggledMethodReturnMessage& smuggledMrm)   at System.Runtime.Remoting.Channels.CrossAppDomainSink.DoTransitionDispatchCallback(Object[] args)Exception rethrown at [0]:    at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)   at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)   at EnvDTE._DTE.get_ActiveSolutionProjects()   at Microsoft.VisualStudio.TextTemplating8FAECA0C56F72C74151CC9A5C0478EAD855803D5D537389B8623F8D6923181E8F8417EB61C3C9AA7CEE873C74FA7879A4EBD8DE5914CA1814842932C9121F4A5.GeneratedTextTransformation.GetCurrentProject()   at Microsoft.VisualStudio.TextTemplating8FAECA0C56F72C74151CC9A5C0478EAD855803D5D537389B8623F8D6923181E8F8417EB61C3C9AA7CEE873C74FA7879A4EBD8DE5914CA1814842932C9121F4A5.GeneratedTextTransformation.GetConnectionString(String& connectionStringName, String& providerName)   at Microsoft.VisualStudio.TextTemplating8FAECA0C56F72C74151CC9A5C0478EAD855803D5D537389B8623F8D6923181E8F8417EB61C3C9AA7CEE873C74FA7879A4EBD8DE5914CA1814842932C9121F4A5.GeneratedTextTransformation.InitConnectionString()   at Microsoft.VisualStudio.TextTemplating8FAECA0C56F72C74151CC9A5C0478EAD855803D5D537389B8623F8D6923181E8F8417EB61C3C9AA7CEE873C74FA7879A4EBD8DE5914CA1814842932C9121F4A5.GeneratedTextTransformation.LoadTables()   at Microsoft.VisualStudio.TextTemplating8FAECA0C56F72C74151CC9A5C0478EAD855803D5D537389B8623F8D6923181E8F8417EB61C3C9AA7CEE873C74FA7879A4EBD8DE5914CA1814842932C9121F4A5.GeneratedTextTransformation.TransformText()


Thanks in advance
AnswerRe: PetaPoco (T4 Template) in .Net Core 2.0 for MSql : - SerializationException in generating Database.cs Pin
BillWoodruff4-Jan-18 21:37
professionalBillWoodruff4-Jan-18 21:37 
PraiseRe: PetaPoco (T4 Template) in .Net Core 2.0 for MSql : - SerializationException in generating Database.cs Pin
J Kaur11-Jan-18 10:52
J Kaur11-Jan-18 10:52 
AnswerRe: PetaPoco (T4 Template) in .Net Core 2.0 for MSql : - SerializationException in generating Database.cs Pin
Vincent Maverick Durano5-Jan-18 1:59
professionalVincent Maverick Durano5-Jan-18 1:59 
PraiseRe: PetaPoco (T4 Template) in .Net Core 2.0 for MSql : - SerializationException in generating Database.cs Pin
J Kaur11-Jan-18 10:51
J Kaur11-Jan-18 10:51 
QuestionAdding Items in a Class Pin
Member 136074754-Jan-18 12:04
Member 136074754-Jan-18 12:04 
AnswerRe: Adding Items in a Class Pin
Mycroft Holmes4-Jan-18 12:41
professionalMycroft Holmes4-Jan-18 12:41 
AnswerRe: Adding Items in a Class Pin
BillWoodruff4-Jan-18 21:27
professionalBillWoodruff4-Jan-18 21:27 
AnswerRe: Adding Items in a Class Pin
OriginalGriff4-Jan-18 21:39
mveOriginalGriff4-Jan-18 21:39 
Questionlistview to combobox - HELP Pin
Member 136074164-Jan-18 10:31
Member 136074164-Jan-18 10:31 
QuestionRe: listview to combobox - HELP Pin
Gerry Schmitz4-Jan-18 10:40
mveGerry Schmitz4-Jan-18 10:40 
AnswerRe: listview to combobox - HELP Pin
Member 136074165-Jan-18 12:32
Member 136074165-Jan-18 12:32 
GeneralRe: listview to combobox - HELP Pin
Gerry Schmitz6-Jan-18 6:28
mveGerry Schmitz6-Jan-18 6:28 
GeneralRe: listview to combobox - HELP Pin
Member 136074167-Jan-18 3:59
Member 136074167-Jan-18 3:59 
GeneralRe: listview to combobox - HELP Pin
Gerry Schmitz7-Jan-18 7:10
mveGerry Schmitz7-Jan-18 7:10 
AnswerRe: listview to combobox - HELP Pin
Mycroft Holmes4-Jan-18 12:44
professionalMycroft Holmes4-Jan-18 12:44 
GeneralRe: listview to combobox - HELP Pin
Member 136074165-Jan-18 12:26
Member 136074165-Jan-18 12:26 
GeneralRe: listview to combobox - HELP Pin
Mycroft Holmes6-Jan-18 10:27
professionalMycroft Holmes6-Jan-18 10:27 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.