Telerik Forums
UI for WPF Forum
3 answers
137 views
I have dragging working functionally (dragging from inside the application and from an external application), but I cannot for the life of me get the DragCue to show up when dragging from outside the program (it works fine when dragging items around the same application).  What I realized is the DragCue is null inside the DropInfo event when dragging items from external programs.  I tried to hook the DragInfo event (as shown in the WPF GridView Reorder Rows sample) to manually create the DragCue item, but this event is never fired for externally dragged items.  As a last attempt, in the DropInfo event I created a DragCue item if it is null, but it is never displayed.

Is there a way to show the DragCue for externally dragged items?


Travis
Kalin
Telerik team
 answered on 24 Mar 2014
2 answers
719 views
Maybe I'm missing something very simple, but I can't seem to set the focus to a cell after I've already entered a row. 

If add a row and use telerik:RadGridViewCommands.BeginInsert, the first time it works great, and puts the cursor on the 1st editable cell.
But after I insert it, and clicks the add again, it puts the cursor on the last column, or the column I last used in my edit.

I tried to set the focus on AddingNewDataItem trigger, but that doesn't seem to work, or I'm doing it wrong.
Should I just do: 
myGrid.Columns[1].Focus();  //1 is the column I want, the first is a delete button
because the row isn't in edit mode yet.
BeginningEdit doesn't work because that applies to any cell.  
danparker276
Top achievements
Rank 2
 answered on 21 Mar 2014
2 answers
171 views
Hi there!

When i'm over RadMaskedNumericInput control the scroll screen not work. In short, RadMaskedNumericInput's MouseWheel Event no trigger although the control is set  <telerik:RadMaskedNumericInput SpinMode="None"/>

Thank you.
Best regards.


Ezequiel
Top achievements
Rank 1
 answered on 21 Mar 2014
7 answers
392 views
Hi all,

I am using RadDataPager and GridView to export data spans multiple pages. I followed the demo here:
http://demos.telerik.com/silverlight/#GridView/ExportingPagedData

No errors are reported in Visual Studio. I compile and run the application, and click on my "export" button - at the prompt, I enter a file name for the .xls and hit "save." Then I get the following error:
                            An unhandled exception ("Unhandled Error in Silverlight Application
                            Code: 4004
                            Category: ManagedRuntimeError
                            Message: System.ArgumentOutOfRangeException: PageIndex cannot be negative when PageSize is positive.
Where would the PageIndex set to a negative number? I'm overlooking something obvious - a value I should have set somewhere or something - but I can't find it. I followed the demo closely and it seemed to be working for me until I tried to export the file.

Any ideas? I'm using Telerik Reporting Q3 and Visual Studio 2010. Thanks!
Hristo
Telerik team
 answered on 21 Mar 2014
6 answers
390 views
Hi,

I would like display the editing controls for all of the columns in a GridViewRow when the GridViewRow is in edit mode.

I have tried handling the RadGridView's BeginningEdit, PreparedCellForEdit, and PrepairingCellFor events to set every cell's InEditMode=True; however, it only ever shows one cell in edit mode.

For example, it seems like the following accomplishes nothing at any point in the edit life cycle for the RadGridView:
Dim row As Telerik.Windows.Controls.GridView.GridViewRow = DirectCast(e.Row, Telerik.Windows.Controls.GridView.GridViewRow)
 
For Each cell As Telerik.Windows.Controls.GridView.GridViewCell In row.Cells
    If Object.Equals(cell.Column, e.Column) = False Then
      cell.IsInEditMode = True
    End If
Next


I also tried using DataTriggers on the GridViewCell to accomplish this like so:
<Style TargetType="telerik:GridViewCell">
    <Style.Triggers>
        <DataTrigger Binding="{Binding Path=IsInEditMode, RelativeSource={RelativeSource AncestorType={x:Type telerik:GridViewRow}}}" Value="True">
            <Setter Property="Foreground" Value="Aqua" />
            <Setter Property="IsInEditMode" Value="True" />
        </DataTrigger>
    </Style.Triggers>
</Style>

This sets the foreground for all of the cells in the row when the row is in edit mode, however only 1 cell displays the edit controls even though I have set the IsInEditMode to true for every cell if the row is in edit mode. Not only that, but the cell that is displaying the controls for editing isn't the one that I double clicked on, but is the cell to the right of it.

I have tried a few other approaches but none of them have been successful.

I look forward to hearing back to you on how to accomplish this.

Thank you,

-Rebecca
Vikas
Top achievements
Rank 1
 answered on 21 Mar 2014
1 answer
98 views
Hi 

I have developed a small screen ruler control.  The purpose was to help team members to design UI that conforms to golden ratio.  My boss and teammates think it is very cool and suggest I share it with the community.

I am not sure if I am allowed to share it somewhere.  If you guys are interested to publish it,  I am happy to send you the code as well.


Cheers

Bill
Yana
Telerik team
 answered on 21 Mar 2014
3 answers
121 views
When I click on the empty space on the scroll bar on a grid that has frozen columns, it scrolls too far, so you skip some columns every time you click-scroll.  I think it's skipping the width of the frozen columns.  
Yoan
Telerik team
 answered on 21 Mar 2014
6 answers
1.2K+ views
Setting row color based on cell value data trigger doesn't work with custom theme/style.

   We used to be able to have this Data Trigger work and it still does if we were to use any of the pre-packaged themes.  However we have developed our theme/style and now this data trigger no longer works for setting a row's background color.  We are using alternate row color so I fail to see how to apply the possible Converter strategy as an alternate solution that I've seen in other posts.

 

 

<telerik:RadGridView Height="200" Width="545" Name="gvNoteList" Grid.Row="1" Grid.Column="1" RowStyle="{StaticResource GridViewRowStyle}" AlternateRowStyle="{StaticResource GridViewAlternateRowStyle}" Style="{StaticResource GridReadOnly}" SelectionChanged="gvNoteList_SelectionChanged">

 

 

 

<telerik:RadGridView.Resources>

 

 

 

<Style TargetType="{x:Type telerik:GridViewRow}">

 

 

 

<Style.Triggers>

 

 

 

<DataTrigger Binding="{Binding Path=IsSticky}" Value="True">

 

 

 

<DataTrigger.Setters>

 

 

 

<Setter Property="Background" Value="#FFFF80" />

 

 

 

<Setter Property="Foreground" Value="#000000" />

 

 

 

<Setter Property="FontSize" Value="12" />

 

 

 

</DataTrigger.Setters>

 

 

 

</DataTrigger>

 

 

 

</Style.Triggers>

 

 

 

</Style>

 

 

 

</telerik:RadGridView.Resources>

 

 

 

</telerik:RadGridView>

 

Yoan
Telerik team
 answered on 21 Mar 2014
2 answers
176 views
I have the following data structure in my view model:

ViewModel{
    List of ClientInfos
}

ClientInfos{
    double HourlyRate
    List of ProjectInfos
}

ProjectInfos{
    TimeSpan TimeSpent
    List of WorkItems
}

After much playing around, I have managed to reflect this structure in the UI using a GridView, two child table relations alongside HierachicalChildTemplates as detailed below:

<telerik:RadGridView x:Name="gridView" AutoGenerateColumns="False" IsReadOnly="True" ItemsSource="{Binding ClientInfos}">
            <telerik:RadGridView.Columns>
                <telerik:GridViewDataColumn DataMemberBinding="{Binding Name}" Header="Client" />
            </telerik:RadGridView.Columns>            
            <telerik:RadGridView.ChildTableDefinitions>
                <telerik:GridViewTableDefinition  />
            </telerik:RadGridView.ChildTableDefinitions>
            
            <telerik:RadGridView.HierarchyChildTemplate>
                <DataTemplate>
                    <telerik:RadGridView x:Name="ProjectList" ShowGroupPanel="False" IsFilteringAllowed="False" CanUserSortColumns="False" CanUserFreezeColumns="False" AutoGenerateColumns="False" ItemsSource="{Binding Projects}">
                        <telerik:RadGridView.Columns>
                        <telerik:GridViewDataColumn DataMemberBinding="{Binding Name}" Header="Project" />
                        <telerik:GridViewDataColumn DataMemberBinding="{Binding WorkingHours}" Header="Day length (hr)" />
                            <telerik:GridViewDataColumn DataMemberBinding="{Binding DailyRate}" Header="Day Rate" DataFormatString="{}{0:F}" />
                            <telerik:GridViewDataColumn DataMemberBinding="{Binding HourlyRate}" Header="Hourly Rate" DataFormatString="{}{0:F}" />
                        </telerik:RadGridView.Columns>

                        <telerik:RadGridView.ChildTableDefinitions>
                            <telerik:GridViewTableDefinition  />
                        </telerik:RadGridView.ChildTableDefinitions>

                        <telerik:RadGridView.HierarchyChildTemplate>
                            <DataTemplate>
                                <telerik:RadGridView x:Name="WorkItemList" ShowGroupPanel="False" IsFilteringAllowed="False" CanUserSortColumns="False" CanUserFreezeColumns="False" AutoGenerateColumns="False" ItemsSource="{Binding WorkItems}">
                                    <telerik:RadGridView.Columns>
                                        <telerik:GridViewDataColumn DataMemberBinding="{Binding Description}" Header="Work Item" />
                                        <telerik:GridViewDataColumn DataMemberBinding="{Binding DateLogged}" Header="Logged" DataFormatString="{}{0:dd/MM/yyyy}" />
                                        <telerik:GridViewDataColumn DataMemberBinding="{Binding TimeSpent}" Header="Time Spent" />
                                        <telerik:GridViewExpressionColumn Header="Total value in stock" UniqueName="TotalValue" Expression="???" />
                                    </telerik:RadGridView.Columns>
                                </telerik:RadGridView>
                            </DataTemplate>
                        </telerik:RadGridView.HierarchyChildTemplate>

                    </telerik:RadGridView>
                </DataTemplate>
            </telerik:RadGridView.HierarchyChildTemplate>
        </telerik:RadGridView>


The issue I am querying here is associated with the second child table responsible for listing the "WorkItems" within the rows "Projects" collection.   I desire a column in the work items child table which lists the financial value of that work item.  This is calculated by taking the "HourlyRate" property which is stored in the associated item for the WorkItem entity and multiplying that by the TimeSpent property value on the WorkItem entity.

My question is what is the syntax I must use in the Expression property of this expression column?  I am using an MVVM architecture so a pure-xaml solution is preferable.  I am not invested in the idea of using the child relation table setup so if anyone has any better ideas on how to represent this hierarchical data on the UI, im all ears.

Thank you for your time and effort.


Nick
Telerik team
 answered on 21 Mar 2014
3 answers
167 views

Hi,

In a self-referencing radgridview, I wanted to completely eliminate the vertical scroll bars for the child records only when a row in the grid is expanded. Is this possible ? what about the case, when the child records are fetched dynamically at run time, when the parent row is expanded by user click ?

Thanks,
Atul

Nick
Telerik team
 answered on 21 Mar 2014
Narrow your results
Selected tags
Tags
GridView
General Discussions
Chart
RichTextBox
Docking
ScheduleView
ChartView
TreeView
Diagram
Map
ComboBox
TreeListView
Window
RibbonView and RibbonWindow
PropertyGrid
DragAndDrop
TabControl
TileView
Carousel
DataForm
PDFViewer
MaskedInput (Numeric, DateTime, Text, Currency)
AutoCompleteBox
DatePicker
Buttons
ListBox
GanttView
PivotGrid
Spreadsheet
Gauges
NumericUpDown
PanelBar
DateTimePicker
DataFilter
Menu
ContextMenu
TimeLine
Calendar
Installer and Visual Studio Extensions
ImageEditor
BusyIndicator
Expander
Slider
TileList
PersistenceFramework
DataPager
Styling
TimeBar
OutlookBar
TransitionControl
FileDialogs
Book
ToolBar
ColorPicker
TimePicker
MultiColumnComboBox
SyntaxEditor
VirtualGrid
Wizard
ExpressionEditor
NavigationView (Hamburger Menu)
WatermarkTextBox
DesktopAlert
BarCode
SpellChecker
DataServiceDataSource
EntityFrameworkDataSource
RadialMenu
ChartView3D
Data Virtualization
BreadCrumb
ProgressBar
Sparkline
LayoutControl
TabbedWindow
ToolTip
CloudUpload
ColorEditor
TreeMap and PivotMap
EntityFrameworkCoreDataSource (.Net Core)
HeatMap
Chat (Conversational UI)
VirtualizingWrapPanel
Calculator
NotifyIcon
TaskBoard
TimeSpanPicker
BulletGraph
Licensing
WebCam
CardView
DataBar
FilePathPicker
PasswordBox
Rating
SplashScreen
Accessibility
Callout
CollectionNavigator
Localization
AutoSuggestBox
Security
VirtualKeyboard
HighlightTextBlock
TouchManager
StepProgressBar
Badge
OfficeNavigationBar
ExpressionParser
CircularProgressBar
SvgImage
PipsPager
SlideView
AI Coding Assistant
+? more
Top users last month
Top achievements
Rank 1
Iron
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ivory
Top achievements
Rank 1
Iron
Nurik
Top achievements
Rank 2
Iron
Iron
YF
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Top achievements
Rank 1
Iron
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ivory
Top achievements
Rank 1
Iron
Nurik
Top achievements
Rank 2
Iron
Iron
YF
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?