Sign in to follow this  
ciscchamps

C++ how to find file version

Recommended Posts

Hi all. Im not sure if this is a beginner topic but this forum seemed most appropriate. How would you go about finding the file version and/or file size of a random access file? ( I mean during runtime) Language: C++ Thanks in advance. Nick

Share this post


Link to post
Share on other sites
Which file version do you mean exactly? Generally, files don't carry version information at the level of file systems. But of course, specific file formats could do that (consider e.g. a text file, with the first line saying "Interpreter.Version = 0.3" or something like that). There are versioning file systems, but this isn't reliable information for your program (except you are writing some low level piece of software, that is targetted at ext3fs, for example; or some other specific file system).

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this