I am trying to create a report containing a statistical analysis. How can I programmatically (i.e., use code) insert tabs so that the output lines up vertically. For example:
Your did code not work for me, but it put me on the right track. Below is your code modified to do exactly what I wanted. I found that I had to set the number of tab spaces to 0 for this to work. I pass to this procedure the name of the statistic, its value (as a string), and its lower and upper confidence limits (as strings). They are then printed exactly as I wanted. Your RichView component is great, but figuring out how to make it do what I want can be frustrating. Thanks for your help.
Paul
PROCEDURE ADD_RESULTS(stat,value,LCL,UCL:string);
var ParaNo: Integer;
BEGIN
RVStyle1.ParaStyles.Add.Options := [rvpaoNoWrap];
ParaNo := RVStyle1.ParaStyles.Count-1;
rve.AddTextNL( stat + #09 + value +#09+#09 + LCL +
#09+#09 + UCL , 0 , ParaNo , ParaNo);
rve.Format;
END;
Default value of RVStyle.SpacesInTab is 0, since the time when tab stops (RVStyle.ParaStyles[].Tabs) were implemented.
Probably you created your project several years ago, and it was started with older version of TRichView.