Windows 10: Question about Compressed Files for school project

Discus and support Question about Compressed Files for school project in Windows 10 Network and Sharing to solve the problem; I need some advice here: I have a school project where I need to learn how to open read and write a compressed file to a directory on the computer>... Discussion in 'Windows 10 Network and Sharing' started by TruthfulDuck433, Nov 21, 2018.

  1. Question about Compressed Files for school project


    I need some advice here:


    I have a school project where I need to learn how to open read and write a compressed file to a directory on the computer>

    So, far I have got this far with my code.


    #include <iostream>

    #include <fstream>

    #include <iomanip>

    #include <ostream>

    #include <string>

    using namespace std;

    int main(void){

    ofstream ofile;

    // Opening file for writing

    ofile.open ("master.rez");

    if(ofile.is_open()){

    std::cout << ofile << "this line will be written into master.rez."<< endl;

    std::cout << ofile << "this line also will be written into master.rez."<< endl;

    system("pause");

    ofile.close();

    }else{

    cerr<<"Error opening file!!"<<endl;

    }

    string buf;

    // Opening file for reading

    ifstream ifile;

    ifile.open("master.rez");

    if(ifile.is_open()){

    while(getline(ifile,buf))

    cout<<buf;

    ifile.close();

    }else{

    cerr<<"Error opening file!!"<<endl;

    }

    return 0;

    }



    So, there is my code I can open the compressed file and read it then open it again with "ifstream" and write the whole compressed file to my directory but I need to be able to read all the files inside of the compressed file and then use "ifstream" to write all the files from the compressed file to the directory like extracting them.

    What, is the steps I need to take now in order to do this.

    And, also for future terms if I wanted to do this with any compressed file type as long as its not encrypted how and what are the steps for that as well That I need to take thanks. Any help I get is gratefully appreciated.

    :)
     
    TruthfulDuck433, Nov 21, 2018
    #1
  2. PT
    pt Win User

    School Project

    project finshed but thanks for the suggestions *Smile Question about Compressed Files for school project :)
     
  3. Files in C: drive automatically compressing?

    As you may already know, if this feature is on, every new folder/file you add starts off automatically compressed. If you would like to turn it off for the whole drive, kindly follow these steps:

    • Start File Explorer . In the left pane, right-click on the drive that you would not want to be compressed.
    • Click Properties.
    • Make sure that the Compress this drive to save disk space box is unchecked.
    • Click OK then Apply.

    Let us know if you need further assistance.
     
    Darian Tab, Nov 21, 2018
    #3
  4. PT
    pt Win User

    Question about Compressed Files for school project

    School Project

    no more suggestions, i will probabily do some drawing tomorrow (on old school paper) *Laugh :laugh:
     
Thema:

Question about Compressed Files for school project

Loading...
  1. Question about Compressed Files for school project - Similar Threads - Question Compressed Files

  2. A question on copying files from a compressed folder to another compressed folder ..... ?

    in Windows 10 Network and Sharing
    A question on copying files from a compressed folder to another compressed folder ..... ?: Compressed folders are often shown in blue for user convenience. When Windows explorer copies files and also sub-folders from one compressed folder to another compressed folder, does it decompress the file data ON-THE-FLY, and then re-compress it again towards the...
  3. Compressing large files and uploading to Dropbox questions.

    in Windows 10 Ask Insider
    Compressing large files and uploading to Dropbox questions.: Hi, not too sure this post fits this page. I have an old laptop which uses Windows 10. I have a large 44Gb file with tones of separate different files inside it. There's some sort of file upload limit to Dropbox so I thought I'd compress my thousands of files within files...
  4. 3 General Questions about imaging, compression, and Hardware ID

    in Windows 10 Backup and Restore
    3 General Questions about imaging, compression, and Hardware ID: 1. How do you actually re-image a computer using an image? Do you HAVE to have a system repair disc made? Are there any programs that make your images into .iso files so you could boot from it somehow? 2. Is there any compression when creating a system image of Windows...
  5. Question about File History usage

    in Windows 10 Backup and Restore
    Question about File History usage: I was preparing to set up file history between my PC and a USB hard drive and before initiating the process, I went through the Bluetooth folder on the PC and dragged the photos and videos which were in there to their permanent storage place in my respective Photo and Video...
  6. Question about File History usage

    in Windows 10 Support
    Question about File History usage: I was preparing to set up file history between my PC and a USB hard drive and before initiating the process, I went through the Bluetooth folder on the PC and dragged the photos and videos which were in there to their permanent storage place in my respective Photo and Video...
  7. Question about Onedrive deleting files?

    in Windows 10 Network and Sharing
    Question about Onedrive deleting files?: I have a folder of work files that I just copy to Onedrive so I can access them from my other PC’s. When I update that folder I just want to delete it from Onedrive and recopy the entire folder. When I delete that folder will Onedrive try to delete the folder or files on my...
  8. A question about the prefetch files

    in Windows 10 Support
    A question about the prefetch files: What happens when you remove the prefetch files? Does this cause the system to stop? 94945
  9. Question about dump files

    in Windows 10 Support
    Question about dump files: Hi , is there does anyone knows how can i translate my sistem information and dump files to english ? I'm trying to fix these BSOD problems im having but i cant get the help i need because my information is in spanish sadly. If anyone could lend me a hand i would...
  10. Question about file explorer

    in Windows 10 Support
    Question about file explorer: Have recently opgraded from Windows 7 to windows 10. Most works fine, except the new file explorer. When I open a map, in the navigation panel on the left side, I have a list of maps, files, quick access, libraries, network links, recent maps and files etc etc. What I...