Code::Blocks Forums

User forums => Help => Topic started by: rjm on August 21, 2009, 09:54:40 am

Title: File associations on Vista
Post by: rjm on August 21, 2009, 09:54:40 am

Hello, I would like to use Code::Blocks as my default editor for .txt/.ini etc.. yet when I set this association in Vista or even execute codeblocks.exe examplefile.ini from a command prompt, CB opens to a blank workspace and does not say anything about a file failing to open.

What could be the issue here?

Thanks for reading;
rjm
Title: Re: File associations on Vista
Post by: zabzonk on August 21, 2009, 10:37:02 am
Use the --file command line option:

codeblocks --file=somefile.ini

To see a full list of command line options, use:

codeblocks --help

Title: Re: File associations on Vista
Post by: rjm on August 22, 2009, 05:24:54 am
when I try your suggestion, it gives me "Unknown long option 'file'" two times in a row, then CB comes up with an empty window with a dialog asking if I want to associate CB filetypes, and after that does nothing, just shows the blank/empty workspace.


Use the --file command line option:

codeblocks --file=somefile.ini

To see a full list of command line options, use:

codeblocks --help


Title: Re: File associations on Vista
Post by: Jenna on August 22, 2009, 10:31:00 am
You did not write which version of C::B you use.

That's something very many posters forget. The best way to get an answer that does not really help you.

I guess you use the 8.02 release.
If I remember right the --file parameter came later.

You can try a more recent nightly build or wait for the next release (no, no timeline yet, due to massive code-changes like wxAuiNotebook instead of wxFlatNotebook).