Problem with one of Dan Diebolt's pasties for embedding a bar graph in a form

  • 0
  • 1
  • Question
  • Updated 2 years ago
  • Answered
  • (Edited)
So I am not sure where I am wondering off the path, but I can't follow Dan's Pastie #492

I created the newest version of IOL but in following these directions I had to make a change based on what I saw in the code-see below.

[iol] value is:

<img qbu='module' src='/i/clear2x2.gif' onload="javascript:if(typeof QBU=='undefined'){QBU={};$.getScript(gReqAppDBID+'?a=dbpage&pagename=

[/iol] value is:

module.js&rand='+new Date().getTime())};">

I created a Chart field of formula-text type:

[iol] & "module.js" & [/iol]
"<div class='QBU_Chart'" &
"  data-rid='" & [Record ID#] & "'" &

I copy & pasted the code from the site, changing the variables for dbid and dbidtable1 to reference my tables, plus created an app token and changed that variable.

In my table I created columns with the same fruit headings and populated them with numbers. Below is a shot of what I get back when I look at the records:

I know it's blurry, but in the charts field I just get the formula back.

Any help is greatly appreciated!
Photo of Neil Shepard

Neil Shepard

  • 1,248 Points 1k badge 2x thumb
  • frustrated

Posted 2 years ago

  • 0
  • 1
Photo of Ⲇanom the ultimate (Dan Diebolt)

Ⲇanom the ultimate (Dan Diebolt), Champion

  • 30,434 Points 20k badge 2x thumb
I am in a meeting on a tablet but I see two issues:

1) the IOL field should have the option "some HTML allowed" checked

2) your definition for [/iol] should not include the text "module.js".
Photo of Neil Shepard

Neil Shepard

  • 1,248 Points 1k badge 2x thumb
Sorry to take so long to reply back!

I know your IOL document says make sure to select "some HTML allowed" so of course I have to make sure to NOT select that :)

Anyway, that did make the plot show up with 4 lines, yay! But the lines do not actually extend for any length nor do the have a number count.

Photo of Neil Shepard

Neil Shepard

  • 1,248 Points 1k badge 2x thumb
I finally discovered the problem and I feel stupid for not seeing this part for what it is.

In the code below, I didn't know what the values were for.
    $.get(dbidTable1, {
      act: "API_DoQuery",
      query: "{3.EX." + kRid + "}",
      clist: ""
After reading I saw this referencing the Field ID number.