Page 1 of 1

Own SetActiveGadget()

Posted: Thu Nov 17, 2022 9:23 am
by Stefan
I'm currently trying to create my own Setactivegadget() because Spider's doesn't work properly.
Unfortunately I don't know any Javascript and I can't really get any further.
With the code below, Spider hangs.

Can someone help?

Code: Select all

Procedure SetActiveGadget1(gadget)
Protected id.s

 ! var GadgetElement = $(spider_GadgetID(v_gadget).div);
  ! if (GadgetElement.attr("id")) {
  !   v_id = GadgetElement.attr("id");
  ! } else {
  !   GadgetElement.attr("id", "SB_Gadget_" + v_gadget);
  !   v_id = GadgetElement.attr("id");
  ! }
  
  
  
  !  var obj = document.getElementById (id);
  !          If (obj.setActive) {
   !             obj.setActive ();
   !         }
     
    
   
EndProcedure

Re: Own SetActiveGadget()

Posted: Fri Nov 25, 2022 2:09 pm
by Fred
It's fixed in the new beta.