Call a page without button click in formula url

  • 0
  • 1
  • Question
  • Updated 2 years ago
  • Answered

Hi All,

I want to call a page automatically on check of condition.

My requirement is if comparedates field  returns false call a html  page.

My code  is as follows:

If([comparedates]="false",URLRoot()&"db/" &Dbid() & "?a=dbpage&PageName=removeaccess.html")

I know that this is possible onclick of button .But i want it to be executed automatically

I too dont want to use image onload technique as well.

Please give me suggestion on this.

Photo of Ananth

Ananth

  • 0 Points

Posted 3 years ago

  • 0
  • 1
Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 65,806 Points 50k badge 2x thumb
I don't have an answer for you, but when they roll out the Webhooks feature into general release in a few months, then similar to firing off an email Notification, you will be able to fire off a webservice call.
Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 65,806 Points 50k badge 2x thumb
Here is a place to register for early access. http://apps.quickbase.intuit.com/integrate
Photo of Ⲇanom the ultimate (Dan Diebolt)

Ⲇanom the ultimate (Dan Diebolt), Champion

  • 30,064 Points 20k badge 2x thumb
It isn't clear to me what you are trying to accomplish. What do you mean by "Call a page"? If you mean load a user defined HTML page you will unload the current page without saving the current record and load your user defined HTML page. If you mean execute a script saved as a user defined page you need to call $.getScript() which will not in itself unload the current page. In any event you will not be able to do any of this automatically without getting your JavaScript to execute when the current page loads and that is the whole purpose of the IOL technique.
Photo of Ananth

Ananth

  • 0 Points
Hi dandiebolt_QB_Pirate , As per my requirement I need to load a html page when a field called  comparedates is false .I have written like this

If([comparedates]="false",URLRoot()&"db/" &Dbid() & "?a=dbpage&PageName=removeaccess.html")

I am new to quickbase can you please help me with an example.
Photo of Ⲇanom the ultimate (Dan Diebolt)

Ⲇanom the ultimate (Dan Diebolt), Champion

  • 30,064 Points 20k badge 2x thumb
The workflow you are describing does not make any sense to me. What page (?a=dr, ?a=nwr, ?a=er etc) are you on when you want this functionality to be implemented? Whatever page you are on the only way to automatically load a html page is by assigning a value to document.location.href using JavaScript and this will happen in a blink of the eye if [comparedates] is false. In other words you will not even see the page you are on because it will immediately load the new page if [comparedates] is false.

Let me ask you this: What function does removeaccess.html perform?
Photo of Ananth

Ananth

  • 0 Points
Can you help me in writing document.location.href in quickbase code.That will solve my requirement.
Photo of Ⲇanom the ultimate (Dan Diebolt)

Ⲇanom the ultimate (Dan Diebolt), Champion

  • 30,064 Points 20k badge 2x thumb
I do not understand what you are trying to accomplish. You need to elaborate what you are trying to accomplish and answer my two questions. This code will be trivial to write once the requirements are known.
Photo of Ananth

Ananth

  • 0 Points
Ok. My Requirement is if comparedates field is false it has to redirect to removeaccess.html page.

In removeaccess.html page i have written an API to remove access of user.

So please guide me how to achieve this
Photo of Ⲇanom the ultimate (Dan Diebolt)

Ⲇanom the ultimate (Dan Diebolt), Champion

  • 30,064 Points 20k badge 2x thumb
What page (?a=dr, ?a=nwr, ?a=er etc) are you on when you want this functionality to be implemented?
Photo of Ananth

Ananth

  • 0 Points
i want in edit record .so I want in ?a=er
Photo of Raghda Ziada

Raghda Ziada

  • 82 Points 75 badge 2x thumb
so you were able to implement it at the end or not?
as I want to do the exact thing but don't know how yet