Home > Net >  C # files particularly large more than the memory size of the case, to read the first 100 bytes of h
C # files particularly large more than the memory size of the case, to read the first 100 bytes of h

Time:09-18

Files especially large over the memory size of the case, how to read the first 100 bytes do

CodePudding user response:

Open the file, read it

CodePudding user response:

Open the file does not mean that will read the file content into memory, just read the first 100 bytes directly

CodePudding user response:

So please give you read the File code I to want to look at how you one-time read the File. The ReadAllXX ()?
Or is there just isn't you tried? I return true have never seen such FileStreaqm must be one-time finish but instead must specify the size of the data you will read

CodePudding user response:

Direct reading, the program will only put the 100 - byte read into memory,
  •  Tags:  
  • C#
  • Related