If you are unable to create a new account, please email support@bspsoftware.com

 

News:

MetaManager - Administrative Tools for IBM Cognos
Pricing starting at $2,100
Download Now    Learn More

Main Menu

Google Maps Script Won't Load - google undefined

Started by andy_mason_84, 28 Oct 2015 05:41:49 AM

Previous topic - Next topic

andy_mason_84

Hi All,

We have a Cognos report that has a: -

Prompt Page - Several Prompts on, nothing special

Cognos Map Page: Uses the Cognos UK Map to show Value - this is drill enabled so the user can click on a County and then it takes them to ...

Google Map Page: Loads a Google Map, Centred on the selected County and adds the markers at various location.

Now when I run it without making any selections on the prompt page (i.e all the data) it all works fine.  It also works fine if I select just a few selections on the prompt page.

However if I make a lot of selections on the prompt page, say I 'Select All' on all prompts then when I drill through from Cognos Map (which loads fine) to Google Map I get a 'google undefined' error where it hasn't loaded the google script.  As if because of the complexity of the SQL it is generating in the query is somehow impacting it's ability to load the script?

Has anyone else had issues like this and have any advice or is there anyone out there that knows what is going on?

Thanks,

Andy

bdbits

It could be a timing problem, if making these selections slows the response time of the report. Basically, you need your script to be sure it runs after the data has been returned. To see if this is the problem, trigger your Google Maps scripts with a setTimeout() with a long enough delay that the rest of the report has finished.

andy_mason_84

Hi,

Thanks for the reply.  We have set the timeout to be a number of different values and it doesn't seem to make a difference.  That's what we thought it was initially but that doesn't seem to be the problem.

Any more ideas? :)

Cheers.

bdbits

Hmmm... are you embedding the script in the page and allowing it to run inline, or is it linked to some event, and if so which one? What if you set it up to trigger the code to run from a button? If it is embedded, is it at the very bottom of the page?

These may seem like elementary things if you've done much javascript, but since I do not know I had to ask. This might also give me time to think up some other idea. :)