I am trying to use ListBox in a M:M database relationship.
Here are my tables
Users Table (UserID,UserName)
Event Table (EventID, EventDescription)
Attendees (AttendeeID, EventID, UserID)
How I can do something to select users from the User Table
that are going to attend an Event, and storage that in Attendees Table!
Since the Users table have a different ID than the Attendees table... It not filling the proper information in the Attendees Table.
here is my code:
<telerik:RadListBox runat="server" ID="RadListBox1" DataSourceID="SourceDataSource"
DataKeyField="UserID" DataTextField="UserName" Width="240px"
Height="200px" AllowTransfer="True" TransferToID="RadListBox2" AutoPostBackOnTransfer="True"
AllowTransferOnDoubleClick="True" DataValueField="UserID" TransferMode="Copy" ButtonSettings-ShowTransferAll="False">
<ButtonSettings TransferButtons="All" ShowTransferAll="False"></ButtonSettings>
</telerik:RadListBox>
<asp:SqlDataSource ID="SourceDataSource" runat="server" ConnectionString="<%$ ConnectionStrings:CalendarsConnectionString %>"
SelectCommand="SELECT UserID, FirstName + ' ' + LastName AS UserName FROM Users ORDER BY UserName"></asp:SqlDataSource>
<telerik:RadListBox runat="server" ID="RadListBox2" DataSourceID="DestinationDataSource"
DataKeyField="AttendeeID" DataTextField="UserName" DataValueField="UserID"
Width="240px" Height="200px"
AllowDelete="True" AutoPostBackOnDelete="true" AllowAutomaticUpdates="True" >
</telerik:RadListBox>
<asp:SqlDataSource ID="DestinationDataSource" runat="server" ConnectionString="<%$ ConnectionStrings:CalendarsConnectionString %>"
SelectCommand="SELECT Attendees.AttendeeID, Attendees.CalendarID, Attendees.UserID, Users.FirstName + ' ' + Users.LastName AS UserName FROM Attendees INNER JOIN Users ON Attendees.UserID = Users.UserID WHERE (Attendees.CalendarID = @CalendarID) ORDER BY UserName"
DeleteCommand="DELETE FROM Attendees WHERE (AttendeeID = @AttendeeID)"
InsertCommand="INSERT INTO Attendees( CalendarID, UserID) VALUES ( @CalendarID, @UserID)" UpdateCommand="UPDATE Attendees SET UserID = @UserID WHERE (AttendeeID = @AttendeeID)">
<DeleteParameters>
<asp:Parameter Name="AttendeeID" />
</DeleteParameters>
<InsertParameters>
<asp:Parameter DefaultValue="4" Name="CalendarID" Type="Int32" />
<asp:Parameter Name="UserID" Type="Int32" />
</InsertParameters>
<SelectParameters>
<asp:Parameter DefaultValue="4" Name="CalendarID" />
</SelectParameters>
<UpdateParameters>
<asp:Parameter Name="UserID" />
<asp:Parameter Name="AttendeeID" />
</UpdateParameters>
</asp:SqlDataSource>
any suggestions?
Regards
Jose-Miguel
Hi,
I have Designed my page with RadMenu, and there are some RadSubmenu added. RadSubMenu is not displaying in MAC Safari browser.
THis is the css which is reffered,
.RadMenu .rmSlide, .RadMenu_Context
In normal safari browser it is displayed. But this Css is not applying for the safari browser in only MAC. Is there any solution for this issue?
Is there a way for me to change the ContentAreaMode client side? I see there is a get_contentArea() method, but nowhere in the documentation do I see what you can do with the object returned. The example just shows how to change styles. What else can I do with it? Can I use it to change the ContentAreaMode?
Thanks for the help,
Jim
Hi,
In radAsyncUpload can we remove drop zone and enable only Localization-select.If yes,can you please tell me how.
Thanks in advance
Vinod
Requirements |
|
Telerik Product and Version |
RadGrid 2016.3.914 |
Supported Browsers and Platforms |
IE 11 |
Components/Widgets used (JS frameworks, etc.) |
PROJECT DESCRIPTION
I'm working on Exporting a Grouped RadGrid, but I'm only getting the top level rows. I've followed the examples I found here but must be doing something else wrong.
My grid is defined as follows:
<
MasterTableView
>
<
SortExpressions
>
<
telerik:GridSortExpression
FieldName
=
"FULLNAME"
SortOrder
=
"Ascending"
/>
</
SortExpressions
>
<
NoRecordsTemplate
>
<
asp:Label
ID
=
"Label1"
Text
=
"No Records Found"
runat
=
"server"
/>
</
NoRecordsTemplate
>
<
Columns
>
<
telerik:GridTemplateColumn
UniqueName
=
"FULLNAME"
ShowFilterIcon
=
"false"
DataField
=
"FULLNAME"
SortExpression
=
"FULLNAME"
HeaderText
=
"Name"
CurrentFilterFunction
=
"Contains"
AutoPostBackOnFilter
=
"true"
>
<
ItemTemplate
>
<
asp:LinkButton
ID
=
"lbUserName"
runat
=
"server"
CommandArgument='<%# Eval("USERID") %>'
Text='<%# Eval("FULLNAME") %>' OnClick="lbUserName_Click" />
</
ItemTemplate
>
</
telerik:GridTemplateColumn
>
<
telerik:GridBoundColumn
UniqueName
=
"COMPANY"
HeaderText
=
"CO"
DataField
=
"COMPANY"
ShowFilterIcon
=
"false"
CurrentFilterFunction
=
"Contains"
AutoPostBackOnFilter
=
"true"
DataType
=
"System.String"
/>
<
telerik:GridBoundColumn
UniqueName
=
"PLATOON"
HeaderText
=
"PLT"
DataField
=
"PLATOON"
ShowFilterIcon
=
"false"
CurrentFilterFunction
=
"Contains"
AutoPostBackOnFilter
=
"true"
DataType
=
"System.String"
/>
<
telerik:GridBoundColumn
UniqueName
=
"SQUADRON"
HeaderText
=
"SQD"
DataField
=
"SQUADRON"
ShowFilterIcon
=
"false"
CurrentFilterFunction
=
"Contains"
AutoPostBackOnFilter
=
"true"
DataType
=
"System.String"
/>
<
telerik:GridBoundColumn
UniqueName
=
"TOTALCOUNT"
HeaderText
=
"Soldiers"
DataField
=
"TOTALCOUNT"
ShowFilterIcon
=
"false"
CurrentFilterFunction
=
"EqualTo"
AutoPostBackOnFilter
=
"true"
DataType
=
"System.Int32"
Aggregate
=
"Sum"
/>
</
Columns
>
<
GroupByExpressions
>
<
telerik:GridGroupByExpression
>
<
GroupByFields
>
<
telerik:GridGroupByField
FieldName
=
"FULLNAME"
HeaderText
=
" "
/>
</
GroupByFields
>
<
SelectFields
>
<
telerik:GridGroupByField
FieldName
=
"FULLNAME"
HeaderText
=
" "
HeaderValueSeparator
=
" "
/>
<
telerik:GridGroupByField
FieldName
=
"TOTALCOUNT"
HeaderText
=
" "
HeaderValueSeparator
=
"Soldiers: "
Aggregate
=
"Sum"
/>
</
SelectFields
>
</
telerik:GridGroupByExpression
>
</
GroupByExpressions
>
</
MasterTableView
>
</
telerik:RadGrid
>
My code in the ItemCommand is:
grid.MasterTableView.HierarchyDefaultExpanded = true;
grid.MasterTableView.GroupsDefaultExpanded = true;
grid.MasterTableView.ExportToExcel();
I'm having the same problem with a grid with DetialTables. the code for that is as follows:
<
MasterTableView
DataKeyNames
=
"COMPANYID"
>
<
DetailTables
>
<
telerik:GridTableView
DataKeyNames
=
"PLATOONID"
Name
=
"PLATOONVIEW"
runat
=
"server"
AllowNaturalSort
=
"false"
AllowMultiColumnSorting
=
"false"
ShowHeader
=
"false"
>
<
DetailTables
>
<
telerik:GridTableView
DataKeyNames
=
"SQUADRONID"
Name
=
"SQUADRONVIEW"
runat
=
"server"
AllowNaturalSort
=
"false"
AllowMultiColumnSorting
=
"false"
ShowHeader
=
"false"
>
<
SortExpressions
>
<
telerik:GridSortExpression
FieldName
=
"SQUADRON"
SortOrder
=
"Ascending"
/>
</
SortExpressions
>
<
Columns
>
<
telerik:GridTemplateColumn
UniqueName
=
"SQUADRON"
AllowFiltering
=
"false"
DataField
=
"SQUADRON"
SortExpression
=
"SQUADRON"
CurrentFilterFunction
=
"Contains"
AutoPostBackOnFilter
=
"true"
>
<
ItemTemplate
>
<
asp:LinkButton
ID
=
"lbSquadName"
runat
=
"server"
CommandName
=
"VIEWSQUADRON"
CommandArgument='<%# Eval("SQUADRONNAME") %>' Text='<%# Eval("SQUADRON") %>' />
</
ItemTemplate
>
</
telerik:GridTemplateColumn
>
<
telerik:GridBoundColumn
UniqueName
=
"COMPANYNAME"
DataField
=
"COMPANYNAME"
Display
=
"false"
/>
<
telerik:GridBoundColumn
UniqueName
=
"PLATOON"
DataField
=
"PLATOON"
Display
=
"false"
/>
<
telerik:GridBoundColumn
UniqueName
=
"TOTALSQUADCOUNT"
HeaderText
=
"Soldiers"
DataField
=
"TOTALSQUADCOUNT"
ShowFilterIcon
=
"false"
AllowFiltering
=
"false"
DataType
=
"System.Int32"
/>
</
Columns
>
</
telerik:GridTableView
>
</
DetailTables
>
<
SortExpressions
>
<
telerik:GridSortExpression
FieldName
=
"PLATOON"
SortOrder
=
"Ascending"
/>
</
SortExpressions
>
<
Columns
>
<
telerik:GridTemplateColumn
UniqueName
=
"PLATOON"
AllowFiltering
=
"false"
DataField
=
"PLATOON"
SortExpression
=
"PLATOON"
HeaderText
=
"PLT Name"
CurrentFilterFunction
=
"Contains"
AutoPostBackOnFilter
=
"true"
>
<
ItemTemplate
>
<
asp:LinkButton
ID
=
"lbPlatoonName"
runat
=
"server"
CommandName
=
"VIEWPLATOON"
CommandArgument='<%# Eval("PLATOONNAME") %>' Text='<%# Eval("PLATOON") %>'/>
</
ItemTemplate
>
</
telerik:GridTemplateColumn
>
<
telerik:GridBoundColumn
UniqueName
=
"COMPANYNAME"
DataField
=
"COMPANYNAME"
Display
=
"false"
/>
<
telerik:GridBoundColumn
UniqueName
=
"PLATOONID"
DataField
=
"PLATOONID"
ShowFilterIcon
=
"false"
AllowFiltering
=
"false"
Display
=
"false"
/>
<
telerik:GridBoundColumn
UniqueName
=
"TOTALPLATOONCOUNT"
HeaderText
=
"Soldiers"
DataField
=
"TOTALPLATOONCOUNT"
ShowFilterIcon
=
"false"
AllowFiltering
=
"false"
DataType
=
"System.Int32"
/>
</
Columns
>
</
telerik:GridTableView
>
</
DetailTables
>
<
CommandItemSettings
ShowExportToPdfButton
=
"false"
ShowAddNewRecordButton
=
"false"
ShowRefreshButton
=
"false"
/>
<
SortExpressions
>
<
telerik:GridSortExpression
FieldName
=
"COMPANYNAME"
SortOrder
=
"Ascending"
/>
</
SortExpressions
>
<
NoRecordsTemplate
>
<
asp:Label
ID
=
"Label1"
Text
=
"No Records Found"
runat
=
"server"
/>
</
NoRecordsTemplate
>
<
Columns
>
<
telerik:GridTemplateColumn
UniqueName
=
"COMPANYNAME"
AllowFiltering
=
"false"
DataField
=
"COMPANYNAME"
SortExpression
=
"COMPANYNAME"
HeaderText
=
"CO Name"
>
<
ItemTemplate
>
<
asp:LinkButton
ID
=
"lbCompanyName"
runat
=
"server"
CommandName
=
"VIEWCOMPANY"
CommandArgument='<%# Eval("COMPANYNAME") %>' Text='<%# Eval("COMPANYNAME") %>' />
</
ItemTemplate
>
</
telerik:GridTemplateColumn
>
<
telerik:GridBoundColumn
UniqueName
=
"COMPANYID"
DataField
=
"COMPANYID"
ShowFilterIcon
=
"false"
AllowFiltering
=
"false"
Display
=
"false"
/>
<
telerik:GridBoundColumn
UniqueName
=
"TOTALCOMPANYCOUNT"
HeaderText
=
"Soldiers"
DataField
=
"TOTALCOMPANYCOUNT"
ShowFilterIcon
=
"false"
AllowFiltering
=
"false"
DataType
=
"System.Int32"
/>
</
Columns
>
</
MasterTableView
>
Any help would be appreciated.
I have a box and whisker plot (boxplotseries)
I have a server version and a local version of the same project.
The only difference between the projects is that I upgraded my local project from 2015.2 to 2016.3.914 this morning.
I have NarrowRange="true" set both in the front side and in the code behind for this graph. 2015.2 shows a non-zero based chart in production, and local shows zero based regardless of range.
Is there a different way to define narrowrange in the latest release, or is this a bug?
I have reverted back to 2015.2 via the VS/Telerik upgrade wizard and have resolved my issue for now.
<
telerik:RadHtmlChart
runat
=
"server"
ID
=
"rcBP"
Width
=
"250px"
Height
=
"300px"
>
<
Legend
>
<
Appearance
Visible
=
"True"
BackgroundColor
=
"Yellow"
></
Appearance
>
</
Legend
>
<
PlotArea
>
<
XAxis
></
XAxis
>
<
Series
>
<
telerik:BoxPlotSeries
>
<
TooltipsAppearance
Color
=
"White"
BackgroundColor
=
"#4f99d2"
>
<
ClientTemplate
>
Avg: #=kendo.format(\'{0:N2}\',dataItem.Avg)# <
br
/>
P10: #=kendo.format(\'{0:N0}\',dataItem.D10)# <
br
/>
P25: #=kendo.format(\'{0:N0}\',dataItem.D25)# <
br
/>
P50: #=kendo.format(\'{0:N0}\',dataItem.P50)# <
br
/>
P75: #=kendo.format(\'{0:N2}\',dataItem.P75)# <
br
/>
P90: #=kendo.format(\'{0:N2}\',dataItem.P90)#
</
ClientTemplate
>
</
TooltipsAppearance
>
<
Appearance
FillStyle-BackgroundColor
=
"#4f99d2"
></
Appearance
>
</
telerik:BoxPlotSeries
>
</
Series
>
<
XAxis
Visible
=
"False"
>
<
Items
>
<
telerik:AxisItem
LabelText
=
""
/>
</
Items
>
<
MajorGridLines
Visible
=
"False"
/>
<
MinorGridLines
Visible
=
"False"
/>
</
XAxis
>
<
YAxis
MinorTickType
=
"None"
MajorTickType
=
"None"
NarrowRange
=
"true"
>
<
MinorGridLines
Visible
=
"False"
/>
<
MajorGridLines
Visible
=
"False"
/>
<
LabelsAppearance
DataFormatString
=
"{0:C2}"
>
</
LabelsAppearance
>
</
YAxis
>
</
PlotArea
>
</
telerik:RadHtmlChart
>
<telerik:RadComboBox ID="rdCombotxtToUser" runat="server" Width="397px" Height="140px" Enabled="false"
EmptyMessage="Please enter your contacts (e.g John Doe;Jane Doe)" AllowCustomText="true" AutoCompleteSeparator=";" EnableAutomaticLoadOnDemand="true" EnableItemCaching="true" MarkFirstMatch="true" OnClientKeyPressing="OnClientKeyPressing">
<WebServiceSettings Method="GetContactName" Path="~/WebServices.asmx" />
</telerik:RadComboBox>
When users enters ; im firing following below javascript
function OnClientKeyPressing(sender, e)
{
var strSelecteditem
if (e._domEvent.keyCode == "186")
{
var combo = $find("<%= rdCombotxtToUser.ClientID %>");
strSelecteditem = combo._selectedItem;
if (strSelecteditem == null) {
var mdlPopup = $find("mdladdContactPopupBId");
document.getElementById(
"<%=txtName.ClientID %>").value = combo._filterText;
mdlPopup.show();
}
}
Can anyone suggest me any other method or solution to prompt user only when mail id or items not in combo is entered.
I have a XML file for users to click a link to display a help pdf. The XML is using Node Text = Course and I can use Text to display the PDF in an iframe. The XML has attributes of PDFFile and Permissions, also.
A part of the xml file:
<Node Text="System Software Requirements" PDFName="SystemSoftware" Permissions="Administrator,Installer">
<Node Text="Client PC System Software" PDFName="SystemSoftwareClientPC" Permissions="Administrator,Installer"/>
<Node Text="Server System Software" PDFName="SystemSoftwareServer" Permissions="Administrator,Installer"/>
</Node>
In the C# code behind, I am using Telerik.Web.UI.RadTreeNodeEventArgs e
string PDFName = e.Node.Text
to display the pdf file
I would like to use PDFName to display the PDF file and remove the link if the person is not an Administrator or Installer. I have tried selectedName.Attribute("PDFName"), but it is giving me an error. What attribute should I use?
Thanks,
Jeff
Hi
Is it possible to edit treelist view only for a few row ??
After searching, i did not find a way to view my gantt row...
I would like to edit some value of row from one column and represented them by a different color.
Thanks
Salvatore
I have a problem where after I dragged Branch ID into the Row Area and update, the pivotgrid will load for some time and show empty result. Results will show if Branch ID is not dragged into row area.
I have tried the same scenario in Visual Studio 2008 SSAS and it successfully shows the result.
Thanks.