In QV, VBScript function calls from script it throws an error called "File not found <--=>" .
I am trying the following code.
dim flag
function VBin(prompt) VBin=inputbox(prompt) end function
function VBclearFlag() flag=0 end function
function VBrelPos(Ref, Current) if Ref=Current then VBRelPos="Reference" flag=1 elseif flag=0 then VBRelPos="Before "&Ref&" in table" else VBRelPos="After "&Ref&" in table" end if end function
Script Module
let MaxPop=VBin('Max population in millions :'); let RefCountry=VBin('Reference country :'); let dummy=VBclearFlag(); Load Country,recno(), Capital, "Area(km.sq)", "Population(mio)", VBrelPos('$(RefCountry)',Country) as RelativePos from country1.csv (ansi, txt, delimiter is ',', embedded labels) where "Population(mio)" <= $(MaxPop);