Wednesday, August 11, 2010

Add Control To Crystal Report Viewer Toolbar

Call This Method In To Page Loload(It will Remove Business Object Image)
private void customizeToolbar()
            Control ts = CrystalReportViewer1.Controls[2];
            if (ts.ToString().Contains("ViewerToolbar"))
                var BtnBack = new Button();
                BtnBack.ID = "btnBack";
                BtnBack.Text = "Back";
                BtnBack.ToolTip = "Back";
                BtnBack.Click += Button1_Click;
                ts.Controls.AddAt(16, BtnBack);

1 comment:

  1. hi!
    i try used your code.
    But it had error.
    Message error "Specified argument was out of the range of valid values.
    Parameter name: index "
    please help me!