Hello,
I have placed the radgrid in a panel to invoke with a ModalPopupExtender. The modal is invoked on a link button click and upon radgrid column header click for sorting, the modal popup closes. I want the radgrid to stay there whenever column sorting is done in the modal popup.
The following is my piece of code:
<
asp:UpdatePanel
ID
=
"upMPE"
runat
=
"server"
>
<
ContentTemplate
>
<
asp:Panel
ID
=
"pnlTopPatientException"
runat
=
"server"
>
<
asp:Panel
ID
=
"pnlPatientException"
runat
=
"server"
Style
=
"display: none; z-index: 8888;"
CssClass
=
"modalPopup"
>
<
table
border
=
"0"
style
=
"width: 100%; height: 30%; border-color: transparent;"
>
<
tr
>
<
td
align
=
"left"
>
<
h1
>
<
asp:Label
ID
=
"lblMessage"
runat
=
"server"
Text
=
"Patient Exceptions"
Style
=
"color: Green"
/>
</
h1
>
</
td
>
</
tr
>
<
tr
>
<
td
>
<
SJ:SJRadGrid
ID
=
"grdPatientExceptionList"
runat
=
"server"
AllowSorting
=
"true"
Skin
=
"SJ"
OnNeedDataSource
=
"GetData"
PageSize
=
"5"
ShowFooter
=
"true"
>
<
PagerStyle
Mode
=
"NextPrevAndNumeric"
></
PagerStyle
>
<
ItemStyle
CssClass
=
"altrow"
/>
<
MasterTableView
PagerStyle-AlwaysVisible
=
"true"
Width
=
"100%"
AllowSorting
=
"true"
AllowMultiColumnSorting
=
"true"
DataKeyNames
=
"ID"
>
<
Columns
>
<
SJ:CustomFilteringTemplateColumn
DataField
=
"FromDate"
HeaderStyle-Wrap
=
"false"
HeaderText
=
"From Date"
HeaderStyle-HorizontalAlign
=
"Center"
SortExpression
=
"FromDate"
FilterControlWidth
=
"105"
DropDownBoxWidth
=
"105"
HeaderStyle-Width
=
"8%"
AllowFiltering
=
"false"
>
<
ItemTemplate
>
<
asp:Label
ID
=
"lblFromDate"
runat
=
"server"
Text='<%#Eval("FromDate","{0:MM/dd/yyyy}")%>'
CausesValidation="false">
</
asp:Label
>
</
ItemTemplate
>
</
SJ:CustomFilteringTemplateColumn
>
<
SJ:CustomFilteringTemplateColumn
DataField
=
"ToDate"
HeaderStyle-Wrap
=
"false"
HeaderText
=
"To Date"
HeaderStyle-HorizontalAlign
=
"Center"
SortExpression
=
"ToDate"
FilterControlWidth
=
"105"
DropDownBoxWidth
=
"105"
HeaderStyle-Width
=
"8%"
AllowFiltering
=
"false"
>
<
ItemTemplate
>
<
asp:Label
ID
=
"lblToDate"
runat
=
"server"
Text='<%#Eval("ToDate","{0:MM/dd/yyyy}")%>'
CausesValidation="false">
</
asp:Label
>
</
ItemTemplate
>
</
SJ:CustomFilteringTemplateColumn
>
<
SJ:CustomFilteringTemplateColumn
HeaderStyle-Wrap
=
"false"
DataField
=
"ExceptionDesc"
HeaderText
=
"Exception Description"
HeaderStyle-HorizontalAlign
=
"Left"
SortExpression
=
"ExceptionDesc"
FilterControlWidth
=
"105"
DropDownBoxWidth
=
"105"
HeaderStyle-Width
=
"52%"
AllowFiltering
=
"false"
>
<
ItemTemplate
>
<
asp:Label
ID
=
"lblExceptionDesc"
runat
=
"server"
Text='<%#Eval("ExceptionDesc") %>'
CausesValidation="false">
</
asp:Label
>
</
ItemTemplate
>
</
SJ:CustomFilteringTemplateColumn
>
</
Columns
>
</
MasterTableView
>
</
SJ:SJRadGrid
>
</
td
>
</
tr
>
<
tr
>
<
td
align
=
"right"
>
<
asp:Button
ID
=
"btnCloseModal"
runat
=
"server"
CssClass
=
"button"
Text
=
"Close"
ToolTip
=
"Close"
OnClientClick
=
"return CloseModalPopup();"
OnClick
=
"btnCloseModal_Click"
/>
</
td
>
</
tr
>
</
table
>
</
asp:Panel
>
<
asp:ModalPopupExtender
ID
=
"mpePatientException"
runat
=
"server"
PopupControlID
=
"pnlPatientException"
BehaviorID
=
"ModalBehaviour"
BackgroundCssClass
=
"modalBackground"
TargetControlID
=
"dummyButton1"
Enabled
=
"false"
/>
<
input
type
=
"button"
runat
=
"server"
style
=
"display: none"
id
=
"dummyButton1"
/>
</
asp:Panel
>
</
ContentTemplate
>
</
asp:UpdatePanel
>
In the server side, I have the following on the click of the link button:
mpePatientException.Enabled = true;
mpePatientException.Show();
Any help would be appreciated. Thanks in advance.
Regards,
Santosh Varma.
Hello,
I'm trying to upload an image after editing it the file size increase and bit depth increase,
is there any solution to keep the bit depth as it is and reduce file size.
Thanks.
For some reason in "design view" (in VS 2015) having any comments within the scope of RadPageLayout triggers errors?
<telerik:RadPageLayout ID="RadPageLayout1" runat="server" BorderWidth="1px">
<!-- Online -->
<Rows>
....
Designer triggers error that on <!-- Online --> ?? This is valid syntax so no sure why the design has a probelm with it?
Cheers, Rob.
Hello,
I use RadCheckBox in my RadGrid in a template column, but I don't want to set any labels for the checkboxes, and I can't use a checkbox column. I realize that when I give no value to the "Text" attribute of the checkbox no text will be displayed, however, there is a space after the checkbox where the label would be. This label makes the checkbox look off-centered in the column when I set the "HorizontalAlign" attribute of the ItemStyle to "Center". I would like to assign a CSS style to any individual checkbox, and I don't want to create a whole new skin to achieve this. Is there a way to do this? Can anyone show me an example of a CSS style that will hide the label associated to a RadCheckBox? Thanks.
I have a grid that allows inserting and updating. I would like to set the default value of three fields in the grid and not allow the user to change those values. It would be even better if these fields weren't even visible. The "ScoreGroupId" should get it's value from a hidden field titled "hdnScoreGroupId". "ScoreCrtdBy" should be the current user - "HttpContext.Current.User.Identity.Name". And "ScoreCrtdDt" is the current date and time and should use "DateTime.Now.ToString()". How can I do this for the following grid:
<
telerik:RadGrid
ID
=
"rgScores"
runat
=
"server"
Skin
=
"Office2010Black"
DataSourceID
=
"sdsRgScores"
AutoGenerateColumns
=
"False"
>
<
MasterTableView
DataKeyNames
=
"Id"
DataSourceID
=
"sdsRgScores"
CommandItemDisplay
=
"Top"
InsertItemPageIndexAction
=
"ShowItemOnCurrentPage"
>
<
Columns
>
<
telerik:GridEditCommandColumn
></
telerik:GridEditCommandColumn
>
<
telerik:GridBoundColumn
DataField
=
"Id"
ReadOnly
=
"True"
HeaderText
=
"Id"
SortExpression
=
"Id"
UniqueName
=
"Id"
DataType
=
"System.Int32"
FilterControlAltText
=
"Filter Id column"
></
telerik:GridBoundColumn
>
<
telerik:GridBoundColumn
DataField
=
"ScoreGroupId"
HeaderText
=
"ScoreGroupId"
SortExpression
=
"ScoreGroupId"
UniqueName
=
"ScoreGroupId"
DataType
=
"System.Int32"
FilterControlAltText
=
"Filter ScoreGroupId column"
></
telerik:GridBoundColumn
>
<
telerik:GridBoundColumn
DataField
=
"ScoreCrtdBy"
HeaderText
=
"ScoreCrtdBy"
SortExpression
=
"ScoreCrtdBy"
UniqueName
=
"ScoreCrtdBy"
FilterControlAltText
=
"Filter ScoreCrtdBy column"
></
telerik:GridBoundColumn
>
<
telerik:GridBoundColumn
DataField
=
"ScoreCrtdDt"
HeaderText
=
"ScoreCrtdDt"
SortExpression
=
"ScoreCrtdDt"
UniqueName
=
"ScoreCrtdDt"
DataType
=
"System.DateTime"
FilterControlAltText
=
"Filter ScoreCrtdDt column"
></
telerik:GridBoundColumn
>
<
telerik:GridBoundColumn
DataField
=
"Score"
HeaderText
=
"Score"
SortExpression
=
"Score"
UniqueName
=
"Score"
DataType
=
"System.Int32"
FilterControlAltText
=
"Filter Score column"
></
telerik:GridBoundColumn
>
</
Columns
>
</
MasterTableView
>
</
telerik:RadGrid
>
I am trying to add a Table of Contents to a RadFlowDocument. I then export it to PDF. However, there is never anything in the TOC. If I replace the second parameter in the InsertField statement with "results", I see the word results on top of the document. The below snippet has what I think are the important parts of the code.
I am hoping that this is something obvious that I am missing, but either way, any help would be appreciated.
public
static
IFormatProvider < RadFlowDocument > GetFormatProvider (
string
extension )
{
if
( !extension.StartsWith (
"."
) ) extension =
"."
+ extension;
switch
( extension.ToLower() )
{
case
".docx"
:
return
new
DocxFormatProvider();
case
".html"
:
return
new
HtmlFormatProvider();
case
".pdf"
:
return
new
PdfFormatProvider();
case
".rtf"
:
return
new
RtfFormatProvider();
case
".txt"
:
return
new
TxtFormatProvider();
default
:
return
null
;
}
}
...
var editor =
new
RadFlowDocumentEditor(doc);
var tocField = editor.InsertField(
"TOC \\o \"1-3\" \\h \\z \\u"
,
""
);
tocField.IsDirty =
true
;
tocField.UpdateField();
using
(var ms =
new
MemoryStream())
[
requestedDocType.Provider?.Export ( doc, ms );
return
ms.ToArray();
}
...