#9 "Inadmissible value or data type error" in Openoffice 2.4


I'm reposting this from forum


I've just updated openoffice to version 2.4.0 from 2.3.1 and started experiencing following error: "Inadmissible value or data type. Data type mismatch." here (i've marked the line with >>>>):

Sub DefaultSysConfig()
' (...)
' Create the user directory if it doesn't exist...
>>>> if Not oFileAccess.exists(sUserPath) then MkDir(sUserPath)
if Not oFileAccess.exists(sTmpPath) then MkDir(sTmpPath)

It complains about an expression "Not oFileAccess.exists(sUserPath)". I have noticed that the problem is caused by Not operator. When I tried to remove it (i know that this will break the script, but that was an experiment) the script breaks on next line.
Similarly following "hack" causes the line passes without error:

if Not (oFileAccess.exists(sUserPath)=True) then MkDir(sUserPath)

I started thinking that oFileAccess.exists returns something other than Boolean, but surprisingly this:
MsgBox TypeName(oFileAccess.exists(sUserPath))

gives "Boolean" so I completely don't know why the hack above makes it works. I have started wondering if there is some bug in OOBasic in ver. 2.4, or so. I don't have any experience with basic and openoffice api so I would be very thankful if you could investigate this further. If you need additional information please do not hesitate to contact me directly by email.

I must say that this script is REALLY GREAT JOB. I am looking forward for next releases.

Best regards,
Jaroslaw Rosiek


  • Jarosław Rosiek

    Logged In: YES
    Originator: YES

    I don't know why but it seems that the patch I attach to this post fixes the problem.
    File Added: OOoLatex.patch

  • Jarosław Rosiek

    Logged In: YES
    Originator: YES

    One note more. The problem still persist in Expand macro.

  • gpiroux

    gpiroux - 2008-03-28

    Logged In: YES
    Originator: NO

    Well, I don't have this problem with OpenOffice 2.4 on MacOSX PPC...
    Did you tried with the official openoffice build ?


  • Andrzej Wasowski

    Logged In: YES
    Originator: NO

    I am seeing the same with OO 2.4 on Linux (arch linux).


Log in to post a comment.