OpenDatafile

Tim Vandermeersch wrote:

Hi,

In windows, Avogadro now looks for plugins in the
QCoreApplication::applicationDirPath(). It is now possible to load the
tools, engines and extensions when the current working directory isn’t
the application directory (e.g. when opening a file by double clicking
it). However, it is still not possible to use optimization etc.,
because openbabel can’t find the data files.I’ve tried setting
BABEL_DATADIR, but this didn’t seem to work, any ideas?

OpenDataFile works with BABEL_DATADIR for me (in OpenBabel).
If you are using Visual Studio, it loads the environment variables when
it starts. If you change any, you have to restart Visual Studio. I have
been caught out by this in the past.

Chris

On Fri, May 30, 2008 at 9:48 PM, Chris Morley c.morley@dsl.pipex.com wrote:

Tim Vandermeersch wrote:

Hi,

In windows, Avogadro now looks for plugins in the
QCoreApplication::applicationDirPath(). It is now possible to load the
tools, engines and extensions when the current working directory isn’t
the application directory (e.g. when opening a file by double clicking
it). However, it is still not possible to use optimization etc.,
because openbabel can’t find the data files.I’ve tried setting
BABEL_DATADIR, but this didn’t seem to work, any ideas?

OpenDataFile works with BABEL_DATADIR for me (in OpenBabel).
If you are using Visual Studio, it loads the environment variables when it
starts. If you change any, you have to restart Visual Studio. I have been
caught out by this in the past.

And do you use BABEL_DATADIR/version/ or just BABEL_DATADIR/ ?

thanks,
Tim

Tim Vandermeersch wrote:

On Fri, May 30, 2008 at 9:48 PM, Chris Morley c.morley@dsl.pipex.com wrote:

Tim Vandermeersch wrote:

Hi,

In windows, Avogadro now looks for plugins in the
QCoreApplication::applicationDirPath(). It is now possible to load the
tools, engines and extensions when the current working directory isn’t
the application directory (e.g. when opening a file by double clicking
it). However, it is still not possible to use optimization etc.,
because openbabel can’t find the data files.I’ve tried setting
BABEL_DATADIR, but this didn’t seem to work, any ideas?

OpenDataFile works with BABEL_DATADIR for me (in OpenBabel).
If you are using Visual Studio, it loads the environment variables when it
starts. If you change any, you have to restart Visual Studio. I have been
caught out by this in the past.

And do you use BABEL_DATADIR/version/ or just BABEL_DATADIR/ ?

The latter, e.g.
E:\My Documents\MSVC\Openbabel-HEAD\openbabel-2-2-0\data\fragments.txt
But I can see the former being tried first:
E:\My Documents\MSVC\Openbabel-HEAD\openbabel-2-2-0\data\2.2\fragments.txt

Could the . in 2.2 be a problem? The version needs to be set properly in
babelconfig.h, possibly “2_2_0” ?

Chris