Start a new topic

When html page has completely loaded

When html page has completely loaded

How owuld I notify the Java class that the html page has been loaded successfully?  And one another question on that is how would I then set an image invisible that is on the top of the html.  I have tried this this.findViewById(R.id.button_infone_radar).setVisibility(View.GONE); and this this.architectView.findViewById(R.id.button_infone_radar).setVisibility(View.GONE); and neither seem to work.

Thanks,
Notifications from HTML/Javascript can be sent by opening a url starting with architectsdk:// (e.g.: architectsdk://opendetails?id=123) anything after that is up to you and will be included in the notification. In your Android application you must add an ArchitectUrlListener to the ArchitectView which urlWasInvoked(String url) method will get called. You can then parse the url to react on the notification. For details please refere to the included SDKDocumentation.pdf and Android javadoc api reference.

As for your second question: This highly depends on your application and ArchtiectView should not interefere with the standard Android behavoir. If you still suspect that ArchitectView is interfering please provide addtional information and problem description.
I apologize for not being specific enough in my question.  Here is what I did and the only request that actually works is the first one NOT the second one to architectsdk://.  This in spite of the fact that urlWasInvoked(String) is working right if I click on a POI, but does not run at all with the other code.

   function makeHttpObject() {
    console.log("Making HTTP Object")
      try {return new XMLHttpRequest();}
      catch (error) {}
      try {return new ActiveXObject("Msxml2.XMLHTTP");}
      catch (error) {}
      try {return new ActiveXObject("Microsoft.XMLHTTP");}
      catch (error) {}
      throw new Error("Could not create HTTP request object.");
   }
   
   function loadComplete() {
    console.log("Starting to create HTTP Object")
    var request = makeHttpObject();
    console.log("Sending HTTP Object")
    request.open("POST", "http://mobileapps.realestatedelivered.com/favorites_steve.cfm?deviceID=00000000-5ff8-f23d-2b61-873f0033c587", false);
    request.send();
    console.log("responseText: " + request.responseText);    console.log("Starting to create HTTP Object")
    var request2 = makeHttpObject();
    console.log("Sending HTTP Object")
    request2.open("POST", "architectsdk://tellParentDone?done=1", false);
    request2.send();
    console.log("responseText: " + request2.responseText);
   }

And the other question about the Visible had to do with the fact that the call to the architectsdk://. URL is NOT being called or executed properly.
I could really use an answer to this question.

Steve Saxton.
Unfortunately ajax requests are not picked up. You can use the document.location property to set the url (as done in the included example) or create an iframe with the location set the url. Let me know if there is anything else.
Thank you. 
Login or Signup to post a comment