This is a migrated thread and some comments may be shown as answers.

[Solved] Popup Heading

2 Answers 124 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Anto (DLL Version : 2008.3.1314.35)
Top achievements
Rank 2
Anto (DLL Version : 2008.3.1314.35) asked on 11 Jun 2009, 04:50 AM
Hi All,

I have a radgrid with datas

I have set the EditMode=Popup

I have set int EditFormSettings (CaptionFormatString="Edit This Record : {0}" )

So that while the edit is clicked, a popup appears with the heading Edit This Record.

But while clicking the add new record, the popup appears without any heading.

Is there any option for setting the heading for add new record also.

Thank you

-Anto


2 Answers, 1 is accepted

Sort by
0
Accepted
Princy
Top achievements
Rank 2
answered on 11 Jun 2009, 06:26 AM
Hello Anto,

You can try out the following code to display two different captions for the popup edit form, for Edit and Insert modes respectively:
c#:
 protected void RadGrid1_ItemCommand(object source, GridCommandEventArgs e) 
    {          
         if (e.CommandName == "Edit"
         { 
             RadGrid1.MasterTableView.EditFormSettings.CaptionDataField = "ContactName"
             RadGrid1.MasterTableView.EditFormSettings.CaptionFormatString = "Edit This Record : {0}"
         } 
         else if (e.CommandName == "InitInsert"
         { 
             RadGrid1.MasterTableView.EditFormSettings.CaptionDataField = ""
             RadGrid1.MasterTableView.EditFormSettings.CaptionFormatString = "New Record"
 
         }       
    } 

Thanks
Princy.
0
Anto (DLL Version : 2008.3.1314.35)
Top achievements
Rank 2
answered on 11 Jun 2009, 06:49 AM
Thank You Princy,

Thank You very much.

-Anto
Tags
Grid
Asked by
Anto (DLL Version : 2008.3.1314.35)
Top achievements
Rank 2
Answers by
Princy
Top achievements
Rank 2
Anto (DLL Version : 2008.3.1314.35)
Top achievements
Rank 2
Share this question
or