The following is insterted into a formula and biulds a string: For the life of me I cant figure out what I have done wrong????.
WhilePrintingRecords;
local StringVar txt;
local StringVar tx;
txt:="";
tx:="";
if not isnull({database.value}) then
tx:=tx+MID(totext({data.minvalue}),1,length(totext({data.minvalue}))-1)+"/";
if not isnull({data.maxvalue}) then
tx:=tx+MID(totext({data.maxvalue}),LENGTH(totext({data.maxvalue}))-1);
if length(tx)<>0 then
txt:=txt+space(9-length(tx))+tx;
tx:="";
if not isnull({data.tminvalue}) then
tx:=tx+MID(totext({data.tminvalue}),1,length(totext({data.tminvalue}))-1)+"/";
if not isnull({data.tmaxvalue}) then
tx:=tx+MID(totext({data.tmaxvalue}),1,length(totext({data.tmaxvalue}))-1);
if length(tx)<>0 then
txt:=txt+space(9-length(tx))+tx;
tx:="";
WhilePrintingRecords;
local StringVar txt;
local StringVar tx;
txt:="";
tx:="";
if not isnull({database.value}) then
tx:=tx+MID(totext({data.minvalue}),1,length(totext({data.minvalue}))-1)+"/";
if not isnull({data.maxvalue}) then
tx:=tx+MID(totext({data.maxvalue}),LENGTH(totext({data.maxvalue}))-1);
if length(tx)<>0 then
txt:=txt+space(9-length(tx))+tx;
tx:="";
if not isnull({data.tminvalue}) then
tx:=tx+MID(totext({data.tminvalue}),1,length(totext({data.tminvalue}))-1)+"/";
if not isnull({data.tmaxvalue}) then
tx:=tx+MID(totext({data.tmaxvalue}),1,length(totext({data.tmaxvalue}))-1);
if length(tx)<>0 then
txt:=txt+space(9-length(tx))+tx;
tx:="";