f



Tricky javascript/activex object problem

This is a multi-part message in MIME format.

------=_NextPart_000_001C_01C44D87.C1A22810
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

The following script if run in Internet Explorer should
display a thumbview of a webpage that you point it to.
To test it, replace test.htm with a valid html file.

The problem I'm having is that I can't get onclick to
fire on the rendered Thumbview object.  What's strange
is that onmouseover fires.  Can anyone see a way?

<html><head><title>test</title></head>
<body onload=3D"Init()">
<a onclick=3Dalert() href=3D"file:///C:/test.htm">
<object id=3D"Thumbview"=20
classid=3D"clsid:1D2B4F40-1F10-11D1-9E88-00C04FDCAB92"
width=3D120 height=3D100 onclick=3Dalert()>
</object><br><br>this works
</a>
<script>
function Init(){
Thumbview.displayFile('C:\\test.htm');
}
</script>
</body></html>
------=_NextPart_000_001C_01C44D87.C1A22810
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1400" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff background=3D"">
<DIV>The following script if run in Internet Explorer should</DIV>
<DIV>display a thumbview of a webpage that you point it to.</DIV>
<DIV>To test it, replace test.htm with a valid html file.</DIV>
<DIV>&nbsp;</DIV>
<DIV>The problem I'm having is that I can't get onclick to</DIV>
<DIV>fire on the rendered Thumbview object.&nbsp; What's strange</DIV>
<DIV>is that onmouseover fires.&nbsp; Can anyone see a way?<BR></DIV>
<DIV>&lt;html&gt;&lt;head&gt;&lt;title&gt;test&lt;/title&gt;&lt;/head&gt;=
<BR>&lt;body=20
onload=3D"Init()"&gt;<BR>&lt;a onclick=3Dalert()=20
href=3D"file:///C:/test.htm"&gt;<BR>&lt;object id=3D"Thumbview"=20
<BR>classid=3D"clsid:1D2B4F40-1F10-11D1-9E88-00C04FDCAB92"<BR>width=3D120=
 height=3D100=20
onclick=3Dalert()&gt;<BR>&lt;/object&gt;&lt;br&gt;&lt;br&gt;this=20
works<BR>&lt;/a&gt;<BR>&lt;script&gt;<BR>function=20
Init(){<BR>Thumbview.displayFile('C:\\test.htm');<BR>}<BR>&lt;/script&gt;=
<BR>&lt;/body&gt;&lt;/html&gt;</DIV></BODY></HTML>

------=_NextPart_000_001C_01C44D87.C1A22810--

0
joebob (1)
6/9/2004 1:38:13 AM
comp.lang.javascript 38370 articles. 2 followers. javascript4 (1315) is leader. Post Follow

4 Replies
530 Views

Similar Articles

[PageSpeed] 17

joebob wrote:

> The following script if run in Internet Explorer shoulddisplay
> a thumbview of a webpage that you point it to.To test it,
> replace test.htm with a valid html file. The problem I'm having
> is that I can't get onclick tofire on the rendered Thumbview
> object.  What's strangeis that onmouseover fires.  Can anyone
> see a way?<html><head><title>test</title></head>
> <body onload="Init()">
> <a onclick=alert() href="file:///C:/test.htm">
> <object id="Thumbview"
> classid="clsid:1D2B4F40-1F10-11D1-9E88-00C04FDCAB92"
> width=120 height=100 onclick=alert()>
> </object><br><br>this works
> </a>
> <script>
> function Init(){
> Thumbview.displayFile('C:\\test.htm');
> }
> </script>
> </body></html>

onclick and ondblclick just aren't honored by that ActiveX
component. You can probably get onmousedown working, you'll just
have to set it up so that it doesn't fire repeatedly.

Something like:

Thumbview.onmousedown = function() {
    if (!this.mouseDownFired) {
        this.mouseDownFired = true;
        // do whatever
        return true;
    }
    return false;
}

--
| Grant Wagner <gwagner@agricoreunited.com>

* Client-side Javascript and Netscape 4 DOM Reference available
at:
*
http://devedge.netscape.com/library/manuals/2000/javascript/1.3/reference/frames.html

* Internet Explorer DOM Reference available at:
*
http://msdn.microsoft.com/workshop/author/dhtml/reference/dhtml_reference_entry.asp

* Netscape 6/7 DOM Reference available at:
* http://www.mozilla.org/docs/dom/domref/
* Tips for upgrading JavaScript for Netscape 7 / Mozilla
* http://www.mozilla.org/docs/web-developer/upgrade_2.html


0
Grant
6/10/2004 4:06:07 PM
This is a multi-part message in MIME format.

------=_NextPart_000_000F_01C44F14.510BBB00
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

"Grant Wagner" <gwagner@agricoreunited.com> wrote in message =
news:40C887EE.1B9083D5@agricoreunited.com...
  joebob wrote:

  > The following script if run in Internet Explorer shoulddisplay
  > a thumbview of a webpage that you point it to.To test it,
  > replace test.htm with a valid html file. The problem I'm having
  > is that I can't get onclick tofire on the rendered Thumbview
  > object.  What's strangeis that onmouseover fires.  Can anyone
  > see a way?<html><head><title>test</title></head>
  > <body onload=3D"Init()">
  > <a onclick=3Dalert() href=3D"file:///C:/test.htm">
  > <object id=3D"Thumbview"
  > classid=3D"clsid:1D2B4F40-1F10-11D1-9E88-00C04FDCAB92"
  > width=3D120 height=3D100 onclick=3Dalert()>
  > </object><br><br>this works
  > </a>
  > <script>
  > function Init(){
  > Thumbview.displayFile('C:\\test.htm');
  > }
  > </script>
  > </body></html>

  onclick and ondblclick just aren't honored by that ActiveX
  component. You can probably get onmousedown working, you'll just
  have to set it up so that it doesn't fire repeatedly.

  Something like:

  Thumbview.onmousedown =3D function() {
      if (!this.mouseDownFired) {
          this.mouseDownFired =3D true;
          // do whatever
          return true;
      }
      return false;
  }

  --
  | Grant Wagner <gwagner@agricoreunited.com>

  * Client-side Javascript and Netscape 4 DOM Reference available
  at:
  *
  =
http://devedge.netscape.com/library/manuals/2000/javascript/1.3/reference=
/frames.html

  * Internet Explorer DOM Reference available at:
  *
  =
http://msdn.microsoft.com/workshop/author/dhtml/reference/dhtml_reference=
_entry.asp

  * Netscape 6/7 DOM Reference available at:
  * http://www.mozilla.org/docs/dom/domref/
  * Tips for upgrading JavaScript for Netscape 7 / Mozilla
  * http://www.mozilla.org/docs/web-developer/upgrade_2.html

------=_NextPart_000_000F_01C44F14.510BBB00
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1400" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV>
<DIV>"Grant Wagner" &lt;<A=20
href=3D"mailto:gwagner@agricoreunited.com">gwagner@agricoreunited.com</A>=
&gt;=20
wrote in message <A=20
href=3D"news:40C887EE.1B9083D5@agricoreunited.com">news:40C887EE.1B9083D5=
@agricoreunited.com</A>...</DIV></DIV>
<BLOCKQUOTE=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
  <DIV>joebob wrote:<BR><BR>&gt; The following script if run in Internet =

  Explorer shoulddisplay<BR>&gt; a thumbview of a webpage that you point =
it=20
  to.To test it,<BR>&gt; replace test.htm with a valid html file. The =
problem=20
  I'm having<BR>&gt; is that I can't get onclick tofire on the rendered=20
  Thumbview<BR>&gt; object.&nbsp; What's strangeis that onmouseover =
fires.&nbsp;=20
  Can anyone<BR>&gt; see a=20
  =
way?&lt;html&gt;&lt;head&gt;&lt;title&gt;test&lt;/title&gt;&lt;/head&gt;<=
BR>&gt;=20
  &lt;body onload=3D"Init()"&gt;<BR>&gt; &lt;a onclick=3Dalert() =
href=3D"<A=20
  href=3D"file:///C:/test.htm">file:///C:/test.htm</A>"&gt;<BR>&gt; =
&lt;object=20
  id=3D"Thumbview"<BR>&gt;=20
  classid=3D"clsid:1D2B4F40-1F10-11D1-9E88-00C04FDCAB92"<BR>&gt; =
width=3D120=20
  height=3D100 onclick=3Dalert()&gt;<BR>&gt; =
&lt;/object&gt;&lt;br&gt;&lt;br&gt;this=20
  works<BR>&gt; &lt;/a&gt;<BR>&gt; &lt;script&gt;<BR>&gt; function=20
  Init(){<BR>&gt; Thumbview.displayFile('C:\\test.htm');<BR>&gt; =
}<BR>&gt;=20
  &lt;/script&gt;<BR>&gt; &lt;/body&gt;&lt;/html&gt;<BR><BR>onclick and=20
  ondblclick just aren't honored by that ActiveX<BR>component. You can =
probably=20
  get onmousedown working, you'll just<BR>have to set it up so that it =
doesn't=20
  fire repeatedly.<BR><BR>Something like:<BR><BR>Thumbview.onmousedown =
=3D=20
  function() {<BR>&nbsp;&nbsp;&nbsp; if (!this.mouseDownFired)=20
  {<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; this.mouseDownFired =
=3D=20
  true;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // do=20
  whatever<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; return=20
  true;<BR>&nbsp;&nbsp;&nbsp; }<BR>&nbsp;&nbsp;&nbsp; return=20
  false;<BR>}<BR><BR>--<BR>| Grant Wagner &lt;<A=20
  =
href=3D"mailto:gwagner@agricoreunited.com">gwagner@agricoreunited.com</A>=
&gt;<BR><BR>*=20
  Client-side Javascript and Netscape 4 DOM Reference=20
  available<BR>at:<BR>*<BR><A=20
  =
href=3D"http://devedge.netscape.com/library/manuals/2000/javascript/1.3/r=
eference/frames.html">http://devedge.netscape.com/library/manuals/2000/ja=
vascript/1.3/reference/frames.html</A><BR><BR>*=20
  Internet Explorer DOM Reference available at:<BR>*<BR><A=20
  =
href=3D"http://msdn.microsoft.com/workshop/author/dhtml/reference/dhtml_r=
eference_entry.asp">http://msdn.microsoft.com/workshop/author/dhtml/refer=
ence/dhtml_reference_entry.asp</A><BR><BR>*=20
  Netscape 6/7 DOM Reference available at:<BR>* <A=20
  =
href=3D"http://www.mozilla.org/docs/dom/domref/">http://www.mozilla.org/d=
ocs/dom/domref/</A><BR>*=20
  Tips for upgrading JavaScript for Netscape 7 / Mozilla<BR>* <A=20
  =
href=3D"http://www.mozilla.org/docs/web-developer/upgrade_2.html">http://=
www.mozilla.org/docs/web-developer/upgrade_2.html</A><BR></DIV></BLOCKQUO=
TE></BODY></HTML>

------=_NextPart_000_000F_01C44F14.510BBB00--

0
joebob
6/11/2004 12:56:55 AM
This is a multi-part message in MIME format.

------=_NextPart_000_004B_01C44F22.DDE17840
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

"Grant Wagner" <gwagner@agricoreunited.com> wrote in message =
news:40C887EE.1B9083D5@agricoreunited.com...
  joebob wrote:

  > The following script if run in Internet Explorer shoulddisplay
  > a thumbview of a webpage that you point it to.To test it,
  > replace test.htm with a valid html file. The problem I'm having
  > is that I can't get onclick tofire on the rendered Thumbview
  > object.  What's strangeis that onmouseover fires.  Can anyone
  > see a way?<html><head><title>test</title></head>
  > <body onload=3D"Init()">
  > <a onclick=3Dalert() href=3D"file:///C:/test.htm">
  > <object id=3D"Thumbview"
  > classid=3D"clsid:1D2B4F40-1F10-11D1-9E88-00C04FDCAB92"
  > width=3D120 height=3D100 onclick=3Dalert()>
  > </object><br><br>this works
  > </a>
  > <script>
  > function Init(){
  > Thumbview.displayFile('C:\\test.htm');
  > }
  > </script>
  > </body></html>

  onclick and ondblclick just aren't honored by that ActiveX
  component. You can probably get onmousedown working, you'll just
  have to set it up so that it doesn't fire repeatedly.

  Something like:

  Thumbview.onmousedown =3D function() {
      if (!this.mouseDownFired) {
          this.mouseDownFired =3D true;
          // do whatever
          return true;
      }
      return false;
  }

  --
  | Grant Wagner <gwagner@agricoreunited.com>

  * Client-side Javascript and Netscape 4 DOM Reference available
  at:
  *
  =
http://devedge.netscape.com/library/manuals/2000/javascript/1.3/reference=
/frames.html

  * Internet Explorer DOM Reference available at:
  *
  =
http://msdn.microsoft.com/workshop/author/dhtml/reference/dhtml_reference=
_entry.asp

  * Netscape 6/7 DOM Reference available at:
  * http://www.mozilla.org/docs/dom/domref/
  * Tips for upgrading JavaScript for Netscape 7 / Mozilla
  * http://www.mozilla.org/docs/web-developer/upgrade_2.html


Hi Grant,

I discovered that onmousedown works.  Also in conjunction with Overlib =
which is pretty cool.

I haven't done anything to ensure that it doesn't fire repeatedly, but I =
haven't found that to be a problem.  Can you tell me what could cause =
that to occur?  Thank you

------=_NextPart_000_004B_01C44F22.DDE17840
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1400" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV>"Grant Wagner" &lt;<A=20
href=3D"mailto:gwagner@agricoreunited.com">gwagner@agricoreunited.com</A>=
&gt;=20
wrote in message <A=20
href=3D"news:40C887EE.1B9083D5@agricoreunited.com">news:40C887EE.1B9083D5=
@agricoreunited.com</A>...</DIV>
<BLOCKQUOTE=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
  <DIV>joebob wrote:<BR><BR>&gt; The following script if run in Internet =

  Explorer shoulddisplay<BR>&gt; a thumbview of a webpage that you point =
it=20
  to.To test it,<BR>&gt; replace test.htm with a valid html file. The =
problem=20
  I'm having<BR>&gt; is that I can't get onclick tofire on the rendered=20
  Thumbview<BR>&gt; object.&nbsp; What's strangeis that onmouseover =
fires.&nbsp;=20
  Can anyone<BR>&gt; see a=20
  =
way?&lt;html&gt;&lt;head&gt;&lt;title&gt;test&lt;/title&gt;&lt;/head&gt;<=
BR>&gt;=20
  &lt;body onload=3D"Init()"&gt;<BR>&gt; &lt;a onclick=3Dalert() =
href=3D"<A=20
  href=3D"file:///C:/test.htm">file:///C:/test.htm</A>"&gt;<BR>&gt; =
&lt;object=20
  id=3D"Thumbview"<BR>&gt;=20
  classid=3D"clsid:1D2B4F40-1F10-11D1-9E88-00C04FDCAB92"<BR>&gt; =
width=3D120=20
  height=3D100 onclick=3Dalert()&gt;<BR>&gt; =
&lt;/object&gt;&lt;br&gt;&lt;br&gt;this=20
  works<BR>&gt; &lt;/a&gt;<BR>&gt; &lt;script&gt;<BR>&gt; function=20
  Init(){<BR>&gt; Thumbview.displayFile('C:\\test.htm');<BR>&gt; =
}<BR>&gt;=20
  &lt;/script&gt;<BR>&gt; &lt;/body&gt;&lt;/html&gt;<BR><BR>onclick and=20
  ondblclick just aren't honored by that ActiveX<BR>component. You can =
probably=20
  get onmousedown working, you'll just<BR>have to set it up so that it =
doesn't=20
  fire repeatedly.<BR><BR>Something like:<BR><BR>Thumbview.onmousedown =
=3D=20
  function() {<BR>&nbsp;&nbsp;&nbsp; if (!this.mouseDownFired)=20
  {<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; this.mouseDownFired =
=3D=20
  true;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // do=20
  whatever<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; return=20
  true;<BR>&nbsp;&nbsp;&nbsp; }<BR>&nbsp;&nbsp;&nbsp; return=20
  false;<BR>}<BR><BR>--<BR>| Grant Wagner &lt;<A=20
  =
href=3D"mailto:gwagner@agricoreunited.com">gwagner@agricoreunited.com</A>=
&gt;<BR><BR>*=20
  Client-side Javascript and Netscape 4 DOM Reference=20
  available<BR>at:<BR>*<BR><A=20
  =
href=3D"http://devedge.netscape.com/library/manuals/2000/javascript/1.3/r=
eference/frames.html">http://devedge.netscape.com/library/manuals/2000/ja=
vascript/1.3/reference/frames.html</A><BR><BR>*=20
  Internet Explorer DOM Reference available at:<BR>*<BR><A=20
  =
href=3D"http://msdn.microsoft.com/workshop/author/dhtml/reference/dhtml_r=
eference_entry.asp">http://msdn.microsoft.com/workshop/author/dhtml/refer=
ence/dhtml_reference_entry.asp</A><BR><BR>*=20
  Netscape 6/7 DOM Reference available at:<BR>* <A=20
  =
href=3D"http://www.mozilla.org/docs/dom/domref/">http://www.mozilla.org/d=
ocs/dom/domref/</A><BR>*=20
  Tips for upgrading JavaScript for Netscape 7 / Mozilla<BR>* <A=20
  =
href=3D"http://www.mozilla.org/docs/web-developer/upgrade_2.html">http://=
www.mozilla.org/docs/web-developer/upgrade_2.html</A><BR><BR></DIV></BLOC=
KQUOTE>
<DIV>Hi Grant,</DIV>
<DIV>&nbsp;</DIV>
<DIV>I discovered that onmousedown works.&nbsp; Also in conjunction with =
Overlib=20
which is pretty cool.</DIV>
<DIV>&nbsp;</DIV>
<DIV>I haven't done anything to ensure that it doesn't fire repeatedly, =
but I=20
haven't found that to be a problem.&nbsp; Can you tell me what could =
cause that=20
to occur?&nbsp; Thank you</DIV>
<DIV>&nbsp;</DIV></BODY></HTML>

------=_NextPart_000_004B_01C44F22.DDE17840--

0
joebob
6/11/2004 2:41:04 AM
joebob wrote:

> "Grant Wagner" <gwagner@agricoreunited.com> wrote in message
> news:40C887EE.1B9083D5@agricoreunited.com...
>
>      joebob wrote:
>
>      > The following script if run in Internet Explorer
>      shoulddisplay
>      > a thumbview of a webpage that you point it to.To
>      test it,
>      > replace test.htm with a valid html file. The
>      problem I'm having
>      > is that I can't get onclick tofire on the rendered
>      Thumbview
>      > object.  What's strangeis that onmouseover fires.
>      Can anyone
>      > see a way?<html><head><title>test</title></head>
>      > <body onload="Init()">
>      > <a onclick=alert() href="file:///C:/test.htm">
>      > <object id="Thumbview"
>      >
>      classid="clsid:1D2B4F40-1F10-11D1-9E88-00C04FDCAB92"
>      > width=120 height=100 onclick=alert()>
>      > </object><br><br>this works
>      > </a>
>      > <script>
>      > function Init(){
>      > Thumbview.displayFile('C:\\test.htm');
>      > }
>      > </script>
>      > </body></html>
>
>      onclick and ondblclick just aren't honored by that
>      ActiveX
>      component. You can probably get onmousedown working,
>      you'll just
>      have to set it up so that it doesn't fire repeatedly.
>
>      Something like:
>
>      Thumbview.onmousedown = function() {
>          if (!this.mouseDownFired) {
>              this.mouseDownFired = true;
>              // do whatever
>              return true;
>          }
>          return false;
>      }
>
>
> Hi Grant, I discovered that onmousedown works.  Also in
> conjunction with Overlib which is pretty cool. I haven't done
> anything to ensure that it doesn't fire repeatedly, but I
> haven't found that to be a problem.  Can you tell me what could
> cause that to occur?  Thank you

By "fire repeatedly" I mean that the native behavior of the
operating system causes an event like "onmousedown" to fire over
and over again at say, 500ms intervals because the native
behavior of the operating system sends an event every 500ms when
a mouse button is held down. If the onmousedown event doesn't
fire repeatedly if you hold the mouse button down then it's fine.
I wasn't sure if it did. Using an alert() to test made it hard to
determine if the event was firing repeatedly.

Good examples of  "repeatedly firing" events are "onkeydown" or
"onkeypress", which _do_ fire over and over again when you hold a
key down. A simple example of this is (IE only):

<form>
<input type="text" onkeydown="putInTa(this);">
<textarea name="output"></textarea>
</form>
<script type="text/javascript">
function putInTa(inp) {
 inp.form.elements['output'].value += window.event.keyCode;
}
</script>

--
| Grant Wagner <gwagner@agricoreunited.com>

* Client-side Javascript and Netscape 4 DOM Reference available
at:
*
http://devedge.netscape.com/library/manuals/2000/javascript/1.3/reference/frames.html

* Internet Explorer DOM Reference available at:
*
http://msdn.microsoft.com/workshop/author/dhtml/reference/dhtml_reference_entry.asp

* Netscape 6/7 DOM Reference available at:
* http://www.mozilla.org/docs/dom/domref/
* Tips for upgrading JavaScript for Netscape 7 / Mozilla
* http://www.mozilla.org/docs/web-developer/upgrade_2.html


0
Grant
6/11/2004 3:21:04 PM
Reply:

Similar Artilces:

tricky javascript problem requires javascript guru !
Hi, I am complete JavaScript novice and would really appreciate some help with this code: ===================================================================== <%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%> <!--#include file="Connections/ssdb.asp" --> <% Dim rs_news_edit Dim rs_news_edit_numRows Set rs_news_edit = Server.CreateObject("ADODB.Recordset") rs_news_edit.ActiveConnection = MM_ssdb_STRING rs_news_edit.Source = "SELECT * FROM tblnews" rs_news_edit.CursorType = 0 rs_news_edit.CursorLocation = 2 rs_news_edit.LockType = 1 rs_news_edit.Open() rs_news_edit_numRows = 0 %> <% Dim Repeat1__numRows Dim Repeat1__index Repeat1__numRows = -1 Repeat1__index = 0 rs_news_edit_numRows = rs_news_edit_numRows + Repeat1__numRows %> <% Dim MM_paramName %> <% ' *** Go To Record and Move To Record: create strings for maintaining URL and Form parameters Dim MM_keepNone Dim MM_keepURL Dim MM_keepForm Dim MM_keepBoth Dim MM_removeList Dim MM_item Dim MM_nextItem ' create the list of parameters which should not be maintained MM_removeList = "&index=" If (MM_paramName <> "") Then MM_removeList = MM_removeList & "&" & MM_paramName & "=" End If MM_keepURL="" MM_keepForm="" MM_keepBoth="" MM_keepNone="" ' add the URL parameters to the MM_keepURL string For Each MM_item In Request.QueryStrin...

javascript within a javascript
Hello, I have a multi-frame page. The frames are named Frame_1, Frame_2 and Frame_3. Frame_1 has a drop down box. When a value is selected in this drop down box, Frame_2 is updated using an asp file (as I have to read from a back-end access database). In turn in the asp file, I have a Body onload tag to execute a javascript function within Frame_2. this function updates the contents of Frame_3. Till now this is working fine. Here is the problem. Frame_3 has a form with a radio button. When a radio button is selected, I want that a function be executed in Frame_3. However since conte...

Disable ActiveX object in a javascript method at runtime.
Hi, I am using an ActiveX object in my ASP web page. I want to disable it at the runtime when a user clicks on a link, by using a Javascript method. Is it possible by any means? Any ideas n clues are most welcome. Thanks, Manoj Pandit wrote: > Hi, > > I am using an ActiveX object in my ASP web page. I want to disable it > at the runtime when a user clicks on a link, by using a Javascript > method. > > Is it possible by any means? > > Any ideas n clues are most welcome. > http://msdn.microsoft.com/library/default.asp?url=/workshop/author/dhtml/reference/prop...

To detect the errors with javascript when downloading the activex object?
I create the ATL Object control and wrap it in the cab file. If a user downlaods .cab file from the HTML document successfully, my control can correctly work. But I want to show the error messages with javascript if the user cannot download the file or the error occurs when downloading the .cab file. What should I do for my ATL object control or add some check codes with javascript? Maybe I guess it should be like as follows but it can not work correctly: <script language="javascript"> <!-- function UA_OnInit() { if(test2==null) alert("A error occurs when downloading"); } --> </script> <HTML> <HEAD> <TITLE>ATL 3.0 test page for object test2</TITLE> </HEAD> <BODY bgcolor="#ffffff" language=javascript onload="UA_OnInit()"> <OBJECT ID="test2" CLASSID="CLSID:5C836C70-4909-477C-A1E1-643602ADD810"></OBJECT> </BODY> </HTML> Can anyone give some suggestions for me? Regards. ...

Calling ActiveX dll with OBJECT Tag from javascript
Hi, Im supposed to write an activeX dll that will be called by javascript (with the OBJECT TAG) and was wondering if its supposed to have any special features or its a regular activeX dll. Its supposed to be able to send and recieve events . Also I would like to know if it matters if its written in C++ or VB, and if someone has sample C++ code that does this i will be grateful to see! Thanks, Hilla ...

Permission Denied error
Hi, I have written a javascript function that acceses properties from an activex object. - <OBJECT id="alertObj" classid="clsid:AEE77194-B98F-4E0E-A27F-4AD6B23F0038"></OBJECT> function onLoadfunc() { //document.writeln("<table>"); var alertObject = document.alertObj; var value; if((value = alertObject.Alert1Prop) == true ) { document.writeln("<tr><td>Alert1!</td></tr>"); } else if((value = alertObject.Alert1Prop) == false ) { document.writeln("<tr>&...

Javascript problem.
Try out the code below in an HTML file please. The problem is with the javascript. I can't get the body to change. The code below is PHP generated. Firefox says the problem is show() does not exist AFTER I click on the link display[ link displayed says: test ] <html> <script> function show( s ){ document.write("<table><tr><td>"+ body( s ) +"</td></tr></table>"); return 0; } function body( s ){ t = ' '; if ( s == "home" ){ t += "hi home<BR><BR>";t += "<a href=\&quo...

Javascript problem?
Hello, I have a small javascript on page that seems to affect the spacing further down on the page. That is, I have a large space between two unrelated HTML sections and when I remove the script, the space goes away. The page does validate with or without the script. You can see this on a test page at http://www.usernomics.com/ergonomic-products-data%20NEW.html . Note the space between the red text and the first table. The javascript is below. Can anyone see what might be causing the problem? Thanks, Bob The section containing the javascript looks like this: ...

dynamic load javascript from javascript
hi, from here: http://www.activewidgets.com/javascript.forum.6114.15/dynamic-load-javascript-from-javascript.html there is a method to load js from js, e.g. //--------------------------------------------------------------------------------------- var script = document.createElement('script'); script.type = 'text/javascript'; script.src = 'snip.js'; document.getElementsByTagName('head')[0].appendChild(script); //--------------------------------------------------------------------------------------- this method works great, but there is a bug(?) when using wit...

JavaScript and objects again ;-)
I have pointed some example of oop in JavaScrip; Here it is: <quote> --- function Foo(){}; function Bar(){}; var foo = new Foo(); var bar = new Bar(); Foo.prototype.baz = 42; alert(foo.baz); // alerts 42! the prototype link is live Bar.prototype = Foo.prototype; /* [AAA] */ alert(bar.baz); // alerts undefined. Inheritance is between objects, // the function is not important afterwards. alert(foo instanceof Bar); // alerts true - really tests if // Bar.prototype is in foo's prototype chain. // Again, th...

Javascript and IE? Javascript and C#?
While my question might be simple, the environment around it is terribly messy and so I will try to keep this clear and simple by only including the relevant code - however, as I will soon suggest, I worry that the problem isnt in what would seem to be the relevant code but instead is lost somewhere in the do-and-donts of the peripheral code. So at the end, i'll try to include all the affected code and you can see if any of its actually relevant. I know there is a lot going on... sorry, but I tried to write this clearly. So here is what I imagine to be relevant. I'm working with a page that uses a very simple javascript function change the style of an <li> element (display=block;). The code is simple...which is why I cant understand my problem. This function is being called by <body onload="fop()"> // Javascript function function fop() { var dropDown = document.getElementById("region"); var firstName = dropDown.name; var fload = document.getElementById(firstName); fload.style.display = "block"; } // This is where it grabs the name value. "View Source" confrims the values work, (eg. name="ZHT") <select name="<%=Request.QueryString("lang")%>" id="region" onchange="selectMenu();"> //This is one of the <li> tags <li class="operatorLI" id="ZHT"> // Later for testing, I tried this (see below) <li class="op...

Objects in javascript
Could someone pont me to a link, where one can see howto create, read and w= rite to objects in java. I have a program that basicly, hook up a number with a color and render col= ored squares to canvas depending on state of checkboxes and the properties = of the number, right now it is very stupid it just render in order of execu= tion so it paint over in sequential order, however it does it in the paint = section. So the control of checkboxes and the values is within the render l= oop. Not that beautiful, and also very time consuming. Can i create an object in Javascript like a number with color attribute, th= at is set before i start to render, that i write out in the render loop? The object really have 7 attributes (number, rect, rsize, rcolor, font, fsi= ze, fcolor) How would i create such an object and how would i update and read from it? = On Sun, 12 Jan 2014 23:07:19 -0800 (PST), jonas.thornvall@gmail.com wrote: >Could someone pont me to a link, where one can see howto create, read and write to objects in java. > >I have a program that basicly, hook up a number with a color and render colored squares to canvas depending on state of checkboxes and the properties of the number, right now it is very stupid it just render in order of execution so it paint over in sequential order, however it does it in the paint section. So the control of checkboxes and the values is within the render loop. Not that beautiful, and also very time con...

JavaScript Objects
I'm a C++ programmer. When I program I use Visual Studio for my environment & can easily get help with the Object Names and their Definitions (what they do). Java (or JavaScript) has nearly the same syntax, however; I don't know where to go to get a list of all objects and definitions. I do my website in FrontPage. All website end up with JavaScript as part of the code. I purchased a JavaScript book, it simply has examples of code in several common areas concerning websites. Is there a Java Help file that allows me to search through the definitions that will lead me to the Ob...

Is this a javascript problem?
Hi there, I'm developing a site http://camshag.co.uk/art_architecture/ and I'm having a problem with the menu system at the top of the page (The News & Events one). There are two links that should allow the user to navigate the posts but only some of them look the way they are supposed to, the others end up having big gaps between the links. There is no problem with Mozilla, Opera has a different problem from the one with IE as it shortens the bar...? I'm racking my brains here and wondering if it's the onmouseover thing that is causing the problems and would welcome...

problems with JavaScript
Hi, I need help to JavaScript. I am new to this, and am trying to the page online ASAP. I have two submit buttons on one form, and each button will have to do different things. I named both button "but1". The first button has the value "Continue", the second button has the value "new page". If someone click on the button with the value "Continue", I need to check if certain information has been filled in before proceeding, and if yes, I need to go to page1.php (which is the second page of the form) and I have to save the result o...

problems with JavaScript
Hi, I need help to JavaScript. I am new to this, and am trying to the page online ASAP. I have two submit buttons on one form, and each button will have to do different things. I named both button "but1". The first button has the value "Continue", the second button has the value "new page". If someone click on the button with the value "Continue", I need to check if certain information has been filled in before proceeding, and if yes, I need to go to page1.php (which is the second page of the form) and I have to save the result o...

How to read dynamically generated XML with Javascript and ActiveX XMLHTTP object?
Ive been banging my head on the wall for hours with this one, hopefully someone will know what Im doing wrong here :\ The Goal: I have an xml file that is generated on the fly via JSP which I want to load into a Microsoft.XMLHTTP ActiveX object and manipulate via javascript on the client side. Data is retreived from the server at the request of the javascript without having to reload the page. The Problem: For the JSP to dynamically output xml, the file must have the extension JSP, which is set to the mime type of dynamo-internal/html on the server side (as we are using ATG Dynamo). But the ...

Copy Java Object into JavaScript Object
HiI need to copy the entire ArrayList object into the JavaScript Array,so that I can display the list on the page and move the list elementsup and down without any server side call.Can someone help me out, how can I accomplish this.Rahul Srivastava Rahul wrote:...>I need to copy the entire ArrayList object..Coming from what? A Java applet, application, servlet, ..banana?>... into the JavaScript Array,>so that I can display the list on the page and move the list elements>up and down without any server side call.>>Can someone help me out, how can I accomplish this.Java program...

Javascript Problem!
I am developing a site at http://www.nwlmi.org.uk The problem lies with the CSS/XHTML Menu which relies on JavaScript to open and close the sections. The parent sections open and close fine but when you click on one of the subsection items and go to the desired page the menu fails to remain open. The javascript code is embeded inthe html for reference. Is this a JS issue I wonder. The original script/code derived from Alsacreations but there is no documentation to aid this problem. Thanks in advance for any tips :) Chris cedwa wrote: > I am developing a site at http://www.nwlmi.org....

how to create file upload using activeX object using javascript
hi frnds , I need to create file upload dialog box using activeX control using javascript ... Can anyone tell me , how to di it ? ... Thanks Dinesh ... ...

a javascript problem
In IE this javascript cod for Date works perfectly, for a eksample: 25.12.2004. but in other Internet Viewers like Firefox or Natescape, it writes 25.12.104. Can enybody help me. And Happy Christmas to you all! here is the code myvar = new Date(); Month = (myvar.getMonth() + 1) Year = (myvar.getYear()) if (Month == 1) {WordMonth = "1";} if (Month == 2) {WordMonth = "2";} if (Month == 3) {WordMonth = "3";} if (Month == 4) {WordMonth = "4";} if (Month == 5) {WordMonth = "5";} if (Month == 6) {WordMonth = "6";} if (Month == 7) {WordM...

JavaScript and ActiveX
How big a security risk are JavaScript and ActiveX where PCs are fully patched? The reason I ask is that they have implemented Surfingate where I work ( I work in IT) and this is causing more and more problems everyday. A lot of websites use JavaScript for menus and buttons and this is causing particular problems with support sites. We can get around it most times by searching for what we want on Google, but it's a time wasting process and when you are trying to resolve problems as quickly as possible it's not helpful. If we can give valid business justification, we can g...

Problem with 'undefined' object In server side JavaScript
Hello all I have this problem: I'm displaying a loggin page. If the user entered an invalid UserName/Password I display the page again. When this happens I want to give the user a different message then the one displayed when the page was initially displayed. I use the Response.Redirect method from the page checking the submition. When I do that I call the page with a parameter like this Response.Redirect("Page.asp?FROM=1"). When I get the parameter in the page I know I need to show a different message. The problem is that if the page is called without the parameter, I can...

Trying to use the GoTo method of the Word.Application ActiveX object in JavaScript
Hi There I am trying to use the Goto method of the Word ActiveX object. I am trying to open a document and go to a named bookmark. If I use this code in VB it works, so I'm sure the approach is possible, I just can't get JavaScript to work with it. Here is the code I am using, the error I get from IE is Object Expected: Hope someone can help! Any help would be much appreciated function PageLoad() { var WordApp = new ActiveXObject('Word.Application'); WordApp.Visible = true; var documentlocation = crmForm.all.new_documentlocation.DataValue; var wd = WordApp.Documents.Open(d...

Web resources about - Tricky javascript/activex object problem - comp.lang.javascript

JavaScript Kit- Your comprehensive JavaScript, DHTML, CSS, and Ajax stop
Your comprehensive JavaScript, DHTML, CSS, and Ajax stop

Let's Code: Test-Driven Javascript by James Shore — Kickstarter
James Shore is raising funds for Let's Code: Test-Driven Javascript on Kickstarter! A screencast series focusing on rigorous, professional Javascript ...

Eloquent JavaScript: A Modern Introduction to Programming
... and pragmatics. I loved the tutorial-style game-like program development. This book rekindled my earliest joys of programming. Plus, JavaScript! ...

Lightbox (JavaScript) - Wikipedia, the free encyclopedia
On a Lightbox-enabled page, a user can click an image to have it magnified in a Lightbox window, which resizes itself according to the size of ...

Open Directory - Computers: Programming: Languages: JavaScript: Tools: Obfuscators
about dmoz - help Top : Computers : Programming : Languages : JavaScript : Tools : Obfuscators Tools for obfuscation/compression JavaScript code. ...

Facebook Open-Sources JavaScript Static-Type Checker Flow
The latest software to be open-sourced by Facebook is Flow , a static-type checker for JavaScript . (more…) New Career Opportunities Daily: ...

Under the Hood: The JavaScript SDK - The use of polyfills - Facebook
Facebook Engineering hat eine Notiz mit dem Titel Under the Hood: The JavaScript SDK - The use of polyfills geschrieben. Du kannst den vollständigen ...

Quickstart: Facebook SDK for JavaScript
This quickstart will show you how to setup the SDK, load social plugins, trigger a dialog, and get it to make some basic Graph API calls.

Facebook App Devs Get Javascript
It has been an oft-lamented fact of the Facebook Platform thus far in its life that, in order to use all but the most simple of Javascript functionality–the ...

Badass JavaScript (@badass_js) on Twitter
WebGLWorker is an open source library that allows using WebGL from Web Workers. Great work as always from @kripken . blog.mozilla.org/research/2014/… ...

Resources last updated: 3/12/2016 7:49:29 AM