how to add TextObject into ReportTitle.and display now!

when I add a TextObject item into RepeortTitle. it can be done.
But the TextObject control cannot visible.
when I move other control ,it can be visible.


============== code ================

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using FastReport.Design.StandardDesigner;
using FastReport;

namespace FastReportTest
{
public partial class frmDesigner : Form
{
DesignerControl designer = new DesignerControl();
Report report = new Report();

public frmDesigner()
{
InitializeComponent();
this.WindowState = FormWindowState.Maximized;

designer.Dock = DockStyle.Fill;
panel1.Controls.Add(designer);

report.Load(@report.frx);

designer.Report = report;

designer.RefreshLayout();
}

private void button1_Click(object sender, EventArgs e)
{
TextObject text2 = new TextObject();
text2.Name = "Text2";
text2.Text = "test";
text2.Bounds = new RectangleF(0, 0, 100, 20);
text2.ZOrder = 99;

ReportPage p = (ReportPage)report.Pages[0];
p.ReportTitle.Objects.Add(text2);

// here are problem
}

private void frmDesigner_Load(object sender, EventArgs e)
{

}
}
}

Leave a Comment

Rich Text Editor. To edit a paragraph's style, hit tab to get to the paragraph menu. From there you will be able to pick one style. Nothing defaults to paragraph. An inline formatting menu will show up when you select text. Hit tab to get into that menu. Some elements, such as rich link embeds, images, loading indicators, and error messages may get inserted into the editor. You may navigate to these using the arrow keys inside of the editor and delete them with the delete or backspace key.