Cant add themeBasedFoi to map

    I am trying to add a themeBasedFoi layer to a map which works ok in IE8 but fails in FireFox 14.0.1 and Google Chrome 20.0.1132.57 m.

    I have two wayson the page to load this layer. One is via a button click on the page and one is via a mouse click on the map. The code executed to add the layer is the same ie: it calls the same method with the same parameters for both actions, however the button click works for all the above browsers but the mouse click only works for IE8.

    The map mouse click is handled in a ThemeBasedFOI event listener bycalling the addLinkFoi method.

    The error I get in chrome and FireFox is: Uncaught TypeError: Cannot set property 'minX' of null on the oraclemaps.js file.
    This is the code:

    the _f1 object is null for the mouse click.

    the code to add the layer is:

    function addLinkFoi(roadNo, linkNo){
    addLinkFoi_noZoom(roadNo, linkNo);

    function addLinkFoi_noZoom(roadNo, linkNo){
    var themeName = "link_theme" + themeNum;
    linkTheme = addTheme(datasource, themeName, "OV1_DIER_ROADS", linkClick);
    linkTheme.setQueryParameters(roadNo, linkNo);


    function addTheme(datasrc, themeName, layerName, clickFunc){
    var themeToAdd = new MVThemeBasedFOI(themeName, datasrc + layerName);

    themeToAdd.attachEventListener(MVEvent.MOUSE_CLICK, clickFunc);
    return themeToAdd

    the parameters being passed in are strings eg: roadNo "A0087", linkNo: "13", the datasource parameter is set elsewhere.

    I have tried changing the layer that is loaded but still get the same result.

    The version of MapViewer is

    Can anyone provide some insight on what, possibly, is happening?