Prev: Supported image-formats by Windows.Media.BitmapDecoder?
Next: Linq to XML - managing xsd with multiple schemas
From: Phil on 12 Oct 2009 05:11 I am trying to use binary serialisation to store and retrieve objects from file and to/from a database. This all seemed to work fine when running in the IDE, but when I build a release version of my application, it no longer reads the data from the files that I have generated, nor from the database that I have written to with the debug version.I don't get any error messages, I just get all my properties set to nothing.. This application is likely to be under continual development for some time, so I will need to be able to access the same data with both the debug and release versions. Any suggestions appreciated. TIA Phil. PS. I have also tried using the XMLSerializer (I would prefer binary as it is more compact for storage in a database), but I get an error indicating that multi-dimensional arrays are not supported.
From: Phil on 12 Oct 2009 10:40 >I am trying to use binary serialisation to store and retrieve objects from >file and to/from a database. This all seemed to work fine when running in >the IDE, but when I build a release version of my application, it no longer >reads the data from the files that I have generated, nor from the database >that I have written to with the debug version. Seems to be working now. I think it may have just have been an issue with file locations.
From: Phil on 14 Oct 2009 09:59 "Phil" <p> wrote in message news:0pednSC-iudHok7XnZ2dnUVZ8q-dnZ2d(a)brightview.co.uk... > >I am trying to use binary serialisation to store and retrieve objects > >from file and to/from a database. This all seemed to work fine when > >running in the IDE, but when I build a release version of my application, > >it no longer reads the data from the files that I have generated, nor > >from the database that I have written to with the debug version. > > Seems to be working now. > I think it may have just have been an issue with file locations. Well I thought it had started working, but it's failing again now. When I run from the VB IDE it all works fine, and when I run my deployed application it all works fine, but if I try to use a file created when running under the IDE it will not deserialise properly when running my deployed application and vice versa. Any suggestions appreciated. My serialisation code is very simple: ' serialise: With New BinaryFormatter .Serialize(MyStream, MyObj) End With ' de-serialise: MyObj= (New BinaryFormatter).Deserialize(Stream)
From: Adam Benson on 15 Oct 2009 06:14 >> it will not deserialise properly when running my deployed application and >> vice versa What happens? You get an object back but its corrupt? You get an exception? If you get an exception what is it? Cheers, Adam. =========
From: Phil on 15 Oct 2009 11:41 > > What happens? You get an object back but its corrupt? You get an > exception? No exception. I get an object but all the properties are set to Nothing. The properties are all arrays of Double or arrays of String.
|
Next
|
Last
Pages: 1 2 Prev: Supported image-formats by Windows.Media.BitmapDecoder? Next: Linq to XML - managing xsd with multiple schemas |