Infrastructure Map Server Forum
Welcome to Autodesk’s Infrastructure Map Server Forums. Share your knowledge, ask questions, and explore popular Infrastructure Map Server topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

MS ActiveX update (KB912945) and MapGuide 6.x

6 REPLIES 6
Reply
Message 1 of 7
Anonymous
200 Views, 6 Replies

MS ActiveX update (KB912945) and MapGuide 6.x

If your users are having to manually activate ActiveX Controls this Technical Solution will step through a process to get around the issue.

http://usa.autodesk.com/getdoc/id=TS1056367
6 REPLIES 6
Message 2 of 7
bdurant
in reply to: Anonymous

That seems to solve the ActiveX problem, but it breaks my vbScript event listener. Either the "onViewChanged" doesn't fire or the javascript doesn't get called. But I'm not getting any JavaScript errors when the map loads. We have a lot of javascript that runs when the map loads to add layers to the map based on user roles and to collapse all the layergroups, etc.

Any ideas?

-- Brook Durant
Message 3 of 7
Anonymous
in reply to: Anonymous

Hi Brook,
Maybe you would have to programatically write the VBScript statements for
the events within that same function (or call another function) as well?
Here's some code pulled from one of my apps where there is browser checking
making this the reliable method to build the page embed code depending on
the browser:

function initVB()
{
if (navigator.appName == "Microsoft Internet Explorer")
{
document.write('
Message 4 of 7
bdurant
in reply to: Anonymous

Andy,

I tried that but I can't get it to work at all. The code you included is a Javascript function, right? And where do you put it: in the head? The body? A separate js page? I seem to get different error messages if I put the code in different places.

I notice you don't have an opening document.write('script language="VBScript"'); in your code, but you do close it. How does that work? Or did the forum remove that for you?

If I put the document.writes for the VBScript after the document.writes for the ActiveX, then I get a Javascript error "Type Mismatch: 'onViewChanged'".

It seems like maybe the map object is not getting passed to the javascript, but I can't tell why.
Message 5 of 7
Anonymous
in reply to: Anonymous

Yes, it's a JavaScript function using the document.write method to actually
write the page contents. You could include that code in your new
InsertControl (or whatever you called it) JavaScript funtion that writes the
object tag. It is generally placed in the head, so you may have to use
JavScript to generate the entire page.

I see the closing script tag in Outlook Express and on the web forums, so
maybe your news reader is stripping it out. In any case, yes, it needs to
be there. It sounds like there might be a problem in the order in which
things are being written and read in the page. The onViewChanged JS
function is probably being read first and it's object reference is broken
since the map object does not exist yet.

I'm hoping that Autodesk can look at this further and let us know what to do
in this case.

Andy

wrote in message news:5136492@discussion.autodesk.com...
Andy,

I tried that but I can't get it to work at all. The code you included is a
Javascript function, right? And where do you put it: in the head? The body?
A separate js page? I seem to get different error messages if I put the code
in different places.

I notice you don't have an opening document.write('script
language="VBScript"'); in your code, but you do close it. How does that
work? Or did the forum remove that for you?

If I put the document.writes for the VBScript after the document.writes for
the ActiveX, then I get a Javascript error "Type Mismatch:
'onViewChanged'".

It seems like maybe the map object is not getting passed to the javascript,
but I can't tell why.
Message 6 of 7
bdurant
in reply to: Anonymous

Andy,

I see the closing tag, in your code, but not the opening tag. If you have JavaScript write out the VBScript, doesn't the JS have to write an opening script tag as well?

The onViewChanged JavaScript is definitely being called: I have JS for the onSelectionChanged event and that gives me the same error when I change the selection in the map. I feel like I'm close, but not quite there.

Thanks for all your help.


Brook
Message 7 of 7
Anonymous
in reply to: Anonymous

The opening tag is there as well, that might have gotten stripped out by the
forum...... Is there any way you can post the page contents? Or you can PM
it to me if you want.

Andy

wrote in message news:5136539@discussion.autodesk.com...
Andy,

I see the closing tag, in your code, but not the opening tag. If you have
JavaScript write out the VBScript, doesn't the JS have to write an opening
script tag as well?

The onViewChanged JavaScript is definitely being called: I have JS for the
onSelectionChanged event and that gives me the same error when I change the
selection in the map. I feel like I'm close, but not quite there.

Thanks for all your help.


Brook

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report