Improve company productivity with a Business Account.Sign Up

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 427
  • Last Modified:

How do I open a *.PCX file with VB

Does anyone know how I can open a PCX file using VB?
0
Steve2
Asked:
Steve2
  • 7
  • 2
  • 2
  • +2
1 Solution
 
polygonCommented:
you must either find a control to do so, or you must make your own algorithm to do it. You must then know the format PCX files are stored and read then in binary mode.
The PCX file starts with some 128 bytes of info, then the actual pixels and at the end - 768 bytes difining the 256 colors used. Just search the internet for detailed description as I don't want to write it all here.
0
 
Steve2Author Commented:
Thanks Polygon,

    I have been searching the internet, but I must be looking in all the wrong places because I can't seem to find any information. If anybody knows of anyplace I can either find these tools or information on the algorithim of the PCX file please let me know.

0
 
idcanadaCommented:

You will need to convert PCX to BMP before.
Have a look at http://www.total.net/~idc/
I will post a small sample their that will show you this process.


0
Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
Steve2Author Commented:
The reason I'm trying to learn how to open this format is because of its space saving format. I've tried BMP's, but they start to take up WAYYY too much space after a few. A 44KB PCX file weighs in at about 62KB, I know this may not seem like much of a difference, but when you get a couple hundred rendered beleive me, you need as much space as possible. Thanks just the same though.
0
 
Steve2Author Commented:
Allow me to correct the spelling errors of my last comment.

The reason I'm trying to learn how to open a PCX file is because of it's small size in comparison to other image formats. I would do my program in BMP's but they begin to take up way too much space. A PCX file I've rendered is 44KB, but the BMP version of that rendering weighs in at about 62KB. Although this may not seem like a biug difference in size, when you have a couple hundred BMP's the size difference does become VERY noticeable. That is the reason for my question.
0
 
Steve2Author Commented:
Does anyone know of any FREE 3rd party OCX controls that can do this for me?
0
 
MirkwoodCommented:
Use JPG iso PCX. Much smaller. And viewable in VB
0
 
chabaudCommented:
Use GIF for 256 colors looseless compressed bitmap
or JPEG for photo bitmap.

This format can be open directly with VB from VB5 (see the Picture property or the LoadPicture() function).


0
 
Steve2Author Commented:
Yeah thanks, I figured it out a little bit ago myself. I was jsut waiting for someone to answer it because I couldn't figure out how to delete it, good answer!
0
 
MirkwoodCommented:
Steve2: Please don't accept answers that has been listed as comments before. If you want to remove a question tell an expert to answer the question.
Chabaud: I already told steve2 to use JPG iso GIF. Please don't answer using another person's comment
0
 
chabaudCommented:
Sorry mirkwood my "new" answer was for GIF (that don't appear upper).
0
 
Steve2Author Commented:
Sorry Chabaud I was trying to figure out if there was a way to give points for a comment but I guess there isn't. So I figured it would've been best to delete it, but I didn't know how to go about doing that unless someone answered it. I don't use this Experts Exchange program very much. Once again I apologize and will try not to let it happen in the future.
0
 
Steve2Author Commented:
I also apologize to you too Mirkwood, I was aware of our comment and it was very helpful, I had just figured it out a day in advance to your comment, and was in the process of figuring out how to delete the question without having an answer, but apparently was unsuccessful.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 7
  • 2
  • 2
  • +2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now