VOGONS

Common searches


Editing files in Dosbox directory?

Topic actions

  • This topic is locked. You cannot reply or edit posts.

First post, by wilf4

User metadata
Rank Newbie
Rank
Newbie

Hi!
I would like to amend AUTOEXEC.BAT to mount, etc.
There doesn't seem to be any command in Dosbox to do this, and Windows 7 can't see the directory.
How can I edit AUTOEXEC.BAT, or create a batch file, please?
Wilf

Who remembers why I,J,K,L,M and N are counters!

Reply 3 of 21, by wilf4

User metadata
Rank Newbie
Rank
Newbie

Only thing in Dosbox folder is a Readme file.
Nothing else to help.
And nothing in there that helps this particular query.
Am I missing something?
(Particularly some help!!!)

Who remembers why I,J,K,L,M and N are counters!

Reply 4 of 21, by ripa

User metadata
Rank Oldbie
Rank
Oldbie

Readme.txt is the manual. The manual tells you the following:

Q: Do I always have to type these commands? Automation? A: In the DOSBox configuration file is an [autoexec] section. The comman […]
Show full quote

Q: Do I always have to type these commands? Automation?
A: In the DOSBox configuration file is an [autoexec] section. The commands
present there are run when DOSBox starts, so you can use this section
for the mounting.

The manual also tells you this:

==================== 11. The Config File: ==================== […]
Show full quote

====================
11. The Config File:
====================

A config file can be generated by CONFIG.COM, which can be found on the
internal DOSBox Z: drive when you start up DOSBox. Look in the internal
programs section of the readme for usage of CONFIG.COM.
You can edit the generated configfile to customize DOSBox.

The file is divided into several sections (the names have [] around it).
Some sections have options you can set.
# and % indicate comment-lines.
The DOSBox configuration file contains the current settings. You can
alter them and start DOSBox with the -conf switch to load the file and
use these settings.

DOSBox will parse configuration files that are specified with -conf. If
none were specified it will try to load "dosbox.conf" from the local
directory. If there is none, DOSBox will load the user configuration
file. This file will be created if it doesn't exist. The file can be
found in ~/.dosbox (Linux) or "~/Library/Preferences" (MAC OS X).
Windows users should use the shortcuts in the startmenu to find it.

Reply 5 of 21, by wilf4

User metadata
Rank Newbie
Rank
Newbie

Many thanks!
But.
I had read that, and tried it.
When I enter any combination of write.... conf.... -write.... or indeed anything other than those words listed with DIR command, all I get is
illegal command: and whatever I have entered.
I must be missing something!!!!!!!!!!!

?

Wilf

Who remembers why I,J,K,L,M and N are counters!

Reply 8 of 21, by wilf4

User metadata
Rank Newbie
Rank
Newbie

THat's the problem!
There is NO mention of configuration anywhere.
Folder or files.
In the Dosbox folder there is only the exe files, some .txt ones and and two .dll's.
When I run dosbox, there is autoexec, which I can't edit, and some .com files.
But nothing like config.

There must be something missing!

Wilf

Who remembers why I,J,K,L,M and N are counters!

Reply 9 of 21, by ripa

User metadata
Rank Oldbie
Rank
Oldbie

Let's start from scratch. Did you install the official dosbox (dosbox.com -> downloads -> "Windows 0.73 Win32 installer")?

If you did, you'll have an entry for Dosbox in the start menu -> programs (I don't know what the start menu looks like in Windows 7). There is an entry called Configuration, and under that is an entry called Edit configuration. That's the simpliest way to find and edit the configuration file. I highlighted this piece of information in my last reply.

The configuration file is NOT located in the dosbox directory (c:\program files\DOSBox-0.73 by default) because it's bad practice to put configuration files there. The configuration files are located in:
C:\<USERS DIRECTORY>\<USER>\Local Settings\Application Data\DOSBox
where <USERS DIRECTORY> is "Users" by default (in XP it was called Documents and Settings) and <USER> is your username. But using the start menu shortcut works so you shouldn't even care. Furthermore, dosbox displays the location where it loads a configuration file from in the status window. If you want to, you can put a dosbox.conf in the dosbox directory (as mentioned by the manual) and dosbox will use that.

Reply 11 of 21, by wilf4

User metadata
Rank Newbie
Rank
Newbie

Yes, I did download from the DosBox site.
It was the version "windows", no XP, 7 or any qualification.
There is, of course, the folder DosBox-0.73.
There is no file, or anything, "config" in that folder.
Which is where I came in!

If something failed to download, perhaps I should uninst. and start again.

Wilf

Who remembers why I,J,K,L,M and N are counters!

Reply 12 of 21, by robertmo

User metadata
Rank l33t++
Rank
l33t++

press the button on your keyboard that is located in the left bottom corner of the keyboard, between ctrl and alt. there is a windows logo/flag on it

a menu will appear, and in that menu Go to Programs > DOSBox-0.73 > Configuration > Edit Configuration

Reply 13 of 21, by wilf4

User metadata
Rank Newbie
Rank
Newbie

Right!

If I search for "DosBos", open the folders in turn, go via c:\..etc. then the config is not there!
However, as previous reply, opening with "all programs" there it is!

So, my only excuse is that the usual (for me) way to find files failed.

Very sorry all for the trouble caused.
And many thanks for the patience shown by the helpers.

wilf

Who remembers why I,J,K,L,M and N are counters!

Reply 16 of 21, by DosFreak

User metadata
Rank l33t++
Rank
l33t++

Nothing if configured correctly for that scenario.

I *think* if you copy dosbox.conf into that folder or create a new dosbox.conf in that folder then the rights would be inherited and the user would only have read-only access to that file. Only way around that would be to run DOSBox as administrator or modify the rights to grant write permission to dosbox.conf.

But let's say:

1. User installs DOSBox 0.73.
2. User wants to ignore warnings and copy or create dosbox.conf to the DOSBox directory.
3. Assuming user is doing like they are supposed to and running DOSBox as a standard user then whever they want to change a setting in dosbox.conf they will not be able to and they will spam the forum wondering wtf stupid DOSBox won't let them change their settings so then they will do ignorant things like the following to get DOSBox to work (either one of the below or a combination):

Run DOSBox in compatibility mode (don't ask).
Change permissions on C:\ or Program files to grant write access. (Hey it fixed their problem right?)
Add themselves to Local Admins (Because it makes things so much easier)
Turn off UAC (Because it makes things so much easier)
Create a new folder in C:\ or C:\Program Files and then copy the contents of the DOSBox directory into it (So they can write to the DOSbox directory.

Yes I have seen all of the above and more in reference to DOSBox.

Last edited by DosFreak on 2010-04-18, 19:54. Edited 1 time in total.

How To Ask Questions The Smart Way
Make your games work offline

Reply 18 of 21, by SKARDAVNELNATE

User metadata
Rank Oldbie
Rank
Oldbie
wilf4 wrote:

So, my only excuse is that the usual (for me) way to find files failed.

It's not really a file. It's a command.

Edit Configuration
"C:\Program Files\DOSBox-0.73\dosbox.exe" -editconf notepad.exe -editconf "%SystemRoot%\system32\notepad.exe" -editconf "%WINDIR%\notepad.exe"

Reply 19 of 21, by frobme

User metadata
Rank Member
Rank
Member

If I search for "DosBos", open the folders in turn, go via c:\..etc. then the config is not there!
However, as previous reply, opening with "all programs" there it is!

So, my only excuse is that the usual (for me) way to find files failed.

It's that way on purpose, because newer versions of Windows are completely anal about what the user can and cannot do on their own machine in certain directories, in the name of "security" - even though they don't work as well as *nix security has for the past 30 years, but whatever.

Anyway, as mentioned, use the Start menu command under Dosbox to edit the configuration for the global use of Dosbox. If you want to have individual config files for each game, you should probably look at getting a front end that manages them for you (D-Fend, DBGL, etc).

-Frob