Solved

Saving binary - Simple but Urgent!

Posted on 2007-04-09
4
213 Views
Last Modified: 2010-04-15
Hello,

I have a simple problem. I want to save a file from ms access to the desk. However, chars are being added at the beginning of the file and when I'm extracting the files it's being corrupted.

Here's my application:

http://www.geocities.com/i950i950/WindowsApplication1.zip

If I manually remove the added chars the file works just fine.

How can I fix this?

Thank you in advance.
0
Comment
Question by:i950
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 63

Expert Comment

by:Fernando Soto
ID: 18875972
Hi: i950;

I had no problem running the program and creating the file. When I ran WinZip on it, it uncompressed the file giving me two extracted files, it121_setup.exe and Readme.txt. I opened the readme file and it looks fine. What extra characters are being added on your system?

Fernando
0
 

Author Comment

by:i950
ID: 18877702
Hello,

It only works with WinRar not with WinZip. When I try it with WinZip I get:

error [c:\test.zip]: start of central directory not found; Zip file corrupt.
Possible cause: file transfer error.

The added characters differs from one editor to another. Here's what I get when I open it with NotePad:

$            Binary  Binary           Binary          ,؛  

Thanks.
0
 

Author Comment

by:i950
ID: 18877942
Here's the original file so you can see the difference:

http://rapidshare.com/files/25143130/it121.zip

Please help.
0
 
LVL 63

Accepted Solution

by:
Fernando Soto earned 500 total points
ID: 18878497
Hi i950;

I looked at the two files the one you sent as the original and the one that I get from the DB file in your project.

   Original   =  47,660 Bytes
   From DB =  47,728 Bytes

And the byte values were all different as well as the two file being of different size. I suspect that the compression algorithm  that was used to compress the files were different. But I was able to uncompress both with no problem using WinRNR, I could not try WinZip because I do not have it on my machine.

Fernando
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article is for Object-Oriented Programming (OOP) beginners. An Interface contains declarations of events, indexers, methods and/or properties. Any class which implements the Interface should provide the concrete implementation for each Inter…
Exception Handling is in the core of any application that is able to dignify its name. In this article, I'll guide you through the process of writing a DRY (Don't Repeat Yourself) Exception Handling mechanism, using Aspect Oriented Programming.
Michael from AdRem Software explains how to view the most utilized and worst performing nodes in your network, by accessing the Top Charts view in NetCrunch network monitor (https://www.adremsoft.com/). Top Charts is a view in which you can set seve…
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…

729 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question