Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
G

Guilherme Morais

@Guilherme Morais
About
Posts
8
Topics
4
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • AutoComplete Like Visual Studio??
    G Guilherme Morais

    Thanks Sirama, I´m thiking here, I could try to search if the letter is upper case, like D%T%... I will try this later, thanks.

    C# visual-studio csharp tutorial question

  • AutoComplete Like Visual Studio??
    G Guilherme Morais

    Hi Everone, I´m looking for a implementantion or a code or even a Tip to implement one Autocomplete (intellisense) like visual studio. For example: If you tipe DT in caps letters in visual Studio they suggest DateTime and any other item wich contains D in begining and T in the middle. in capital letter. It´s amazing, I really want to put this in a WindowsForms application. Thanks in advance!

    C# visual-studio csharp tutorial question

  • Something like hsqldb??? (besides sharpsqldb)...
    G Guilherme Morais

    Thanks a Lot! :-D :laugh: ;P :)

    C# database mysql sysadmin question

  • Something like hsqldb??? (besides sharpsqldb)...
    G Guilherme Morais

    Hi! I need to replace the mysql for any other database type... Because... The client doesn´t want to install anything else besides my application and I don´t want to lose my implementation with "insert"s "delete"s and "update"s.... ;)

    C# database mysql sysadmin question

  • Something like hsqldb??? (besides sharpsqldb)...
    G Guilherme Morais

    Hi everyone. I have wrote a little program which uses mysql server, but now I need to remove mysql server and you some sql database witch do not need to you another install application... Anyone has any ANYYY kind of tip?? Thanks A LOT in advance.

    C# database mysql sysadmin question

  • Serialization load/save getting a different HashCode....
    G Guilherme Morais

    Hi there... I´m facing a strange problem... I made a WebApp which serializate a complex object and save in the bank and load to save time of processor. When the WebApp save and read the object everything goes fine, but If I install one second WebApp in other server the same object is readed but the HashCode is differently from the original... Anyone has a opnion about that?? Thanks in advance...

    C# sysadmin json help question

  • Deserialization, after GZipStream it´s possible?? (What is Wrong??)
    G Guilherme Morais

    JUST for awnser this... It´s necessary to put

    Serial.Seek(0, SeekOrigin.Begin);

    Between:

    byte[] buffer = new byte[Serial.Length];
    Serial.Read(buffer, 0, buffer.Length);

    C# help question database json announcement

  • Deserialization, after GZipStream it´s possible?? (What is Wrong??)
    G Guilherme Morais

    Hi, everyone... I have a stream and put in a GZipStream, save in SQL 2005, after that I load this stream from sql 2005 and try to deserialize from BinaryFormatter. This will be the GOLD, for now a simple serializable-Compress-Decompress-Deserializable is very fine... But, I´m getting a error: "Binary stream '0' does not contain a valid BinaryHeader. Possible causes are invalid stream or object version change between serialization and deserialization." Any help? My Code:

    public static void Main()
    {

                List p3;
                List p1 = new List();
                p1.Add("Brazil");
                p1.Add("Error");
                p1.Add("Serializable");
    
    
                Stream Serial = new MemoryStream();
                FileStream fileStream = new FileStream("Teste.bin", FileMode.Create, FileAccess.ReadWrite, FileShare.None);
                //BinaryFormatter teste = new BinaryFormatter();
                Processo \_Retorno = new Processo();
                BinaryFormatter teste = new BinaryFormatter();
                teste.Serialize(Serial, p1);
                byte\[\] buffer = new byte\[Serial.Length\];
                Serial.Read(buffer, 0, buffer.Length);
                fileStream.Write(buffer, 0, buffer.Length);
                fileStream.Close();
                //teste.Serialize(fileStream, \_Retorno );
                byte\[\] Compremido = Compressor.Compress(buffer);
                //FileStream destino = new FileStream("Teste.ZIP", FileMode.Create, FileAccess.ReadWrite, FileShare.None);
                //destino.Write(Compremido,0,Compremido.Length  );
                //destino.Close();
                byte\[\] Descompremido = Compressor.Decompress(Compremido);
                MemoryStream msUnZip = new MemoryStream();
                msUnZip.Write(Descompremido, 0, Descompremido.Length);
                msUnZip.Seek(0, SeekOrigin.Begin);
                BinaryFormatter Serializador = new BinaryFormatter();
                p3 = (List)Serializador.Deserialize(msUnZip);:mad:
                
            }
    

    public static class Compressor
    {

            public static byte\[\] Compress(byte\[\] data)
            {
                MemoryStream output = new MemoryStream();
                GZipStream gzip = new GZipStream(output,
                                  CompressionMode.Compress, true);
                gzip.Write(data, 0, dat
    
    C# help question database json announcement
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups