Telerik Forums
UI for WPF Forum
2 answers
153 views
Hi,
I get the following exception when I mark IsHierarchyRoot as "False".

   at Telerik.Windows.Controls.GridView.GridViewItemsControl.ExpandToAvailableSpace() in r:\WPF_Scrum\WPF_Team\Sources\Development\WPF\GridView\GridView\GridViewItemsControl.cs:line 1329 
   at Telerik.Windows.Controls.GridView.GridViewItemsControl.GridViewItemsControl_Loaded(Object sender, RoutedEventArgs e) in r:\WPF_Scrum\WPF_Team\Sources\Development\WPF\GridView\GridView\GridViewItemsControl.cs:line 852 
   at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs) 
   at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised) 
   at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args) 
   at System.Windows.UIElement.RaiseEvent(RoutedEventArgs e) 
   at System.Windows.BroadcastEventHelper.BroadcastEvent(DependencyObject root, RoutedEvent routedEvent) 
   at System.Windows.BroadcastEventHelper.BroadcastLoadedEvent(Object root) 
   at MS.Internal.LoadedOrUnloadedOperation.DoWork() 
   at System.Windows.Media.MediaContext.FireLoadedPendingCallbacks() 
   at System.Windows.Media.MediaContext.FireInvokeOnRenderCallbacks() 
   at System.Windows.Media.MediaContext.RenderMessageHandlerCore(Object resizedCompositionTarget) 
   at System.Windows.Media.MediaContext.RenderMessageHandler(Object resizedCompositionTarget) 
   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Boolean isSingleParameter) 
   at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Boolean isSingleParameter, Delegate catchHandler) 
   at System.Windows.Threading.Dispatcher.WrappedInvoke(Delegate callback, Object args, Boolean isSingleParameter, Delegate catchHandler) 
   at System.Windows.Threading.DispatcherOperation.InvokeImpl() 
   at System.Windows.Threading.DispatcherOperation.InvokeInSecurityContext(Object state) 
   at System.Threading.ExecutionContext.runTryCode(Object userData) 
   at System.Runtime.CompilerServices.RuntimeHelpers.ExecuteCodeWithGuaranteedCleanup(TryCode code, CleanupCode backoutCode, Object userData) 
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state) 
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state) 
   at System.Windows.Threading.DispatcherOperation.Invoke() 
   at System.Windows.Threading.Dispatcher.ProcessQueue() 
   at System.Windows.Threading.Dispatcher.WndProcHook(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled) 
   at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled) 
   at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o) 
   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Boolean isSingleParameter) 
   at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Boolean isSingleParameter, Delegate catchHandler) 
   at System.Windows.Threading.Dispatcher.WrappedInvoke(Delegate callback, Object args, Boolean isSingleParameter, Delegate catchHandler) 
   at System.Windows.Threading.Dispatcher.InvokeImpl(DispatcherPriority priority, TimeSpan timeout, Delegate method, Object args, Boolean isSingleParameter) 
   at System.Windows.Threading.Dispatcher.Invoke(DispatcherPriority priority, Delegate method, Object arg) 
   at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam) 
   at MS.Win32.UnsafeNativeMethods.DispatchMessage(MSG& msg) 
   at System.Windows.Threading.Dispatcher.PushFrameImpl(DispatcherFrame frame) 
   at System.Windows.Threading.Dispatcher.PushFrame(DispatcherFrame frame) 
   at System.Windows.Threading.Dispatcher.Run() 
   at System.Windows.Application.RunDispatcher(Object ignore) 
   at System.Windows.Application.RunInternal(Window window) 
   at System.Windows.Application.Run(Window window) 
   at System.Windows.Application.Run() 
   at Imis.Kinetik.TeamPlayer.Client.App.Main() in C:\Projects\TeamPlayerClient\TeamPlayer.Client\obj\Development\App.g.cs:line 0 
   at System.AppDomain._nExecuteAssembly(Assembly assembly, String[] args) 
   at System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args) 
   at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly() 
   at System.Threading.ThreadHelper.ThreadStart_Context(Object state) 
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state) 
   at System.Threading.ThreadHelper.ThreadStart() 

My define the grid like this (Info.Fields is a list):

<Telerik:RadGridView  MinHeight="200"   IsHierarchyRoot="False"  ShowGroupPanel="False" Grid.Row="7" Grid.ColumnSpan="2" Margin="5" AutoGenerateColumns="False" ItemsSource="{Binding Path=Info.Fields, ElementName=workunitNodeUC}" > 
            <Telerik:RadGridView.Columns> 
                <Telerik:GridViewDataColumn AutofitWidth="0" UniqueName="{x:Null}"
                    <Telerik:GridViewDataColumn.CellStyle> 
                        <Style TargetType="{x:Type Telerik:GridViewCell}"
                            <Setter Property="Template"
                                <Setter.Value> 
                                    <ControlTemplate  TargetType="{x:Type Telerik:GridViewCell}"
                                        <CheckBox x:Name="chbChosen" HorizontalAlignment="Center"/> 
                                    </ControlTemplate> 
                                </Setter.Value> 
                            </Setter> 
                        </Style> 
                    </Telerik:GridViewDataColumn.CellStyle> 
                </Telerik:GridViewDataColumn> 
                <Telerik:GridViewDataColumn AutofitWidth="0" HeaderText="Description" UniqueName="Description" DataMemberPath="Name" /> 
                <Telerik:GridViewDataColumn AutofitWidth="0" HeaderText="Comment" UniqueName="Comment" DataMemberPath="InnerValue"  /> 
            </Telerik:RadGridView.Columns> 
        </Telerik:RadGridView> 

Thanks
Tal
Top achievements
Rank 1
 answered on 11 Feb 2009
1 answer
330 views
Hello guys,

I have two questions:
  1. How can I bind a gridview from an Anonymous Type returned LINQ query?
  2. How can I get the key value from a grid bound from an Anonymous Type? On ASP.Net Ajax we use GetDataKeyValue method. Do you have a similar on WPF?

Regards,

Henrique
Hristo Deshev
Telerik team
 answered on 11 Feb 2009
1 answer
108 views
Hi,

I have a very simple project that contains tabs.  And inside one of the tabs is a grid.  If I filter the grid then switch to another tab and then back to the tab with the grid is no longer filtered.  However the filter is still selected.

Thanks

Guido Tapia
Hristo Deshev
Telerik team
 answered on 11 Feb 2009
3 answers
168 views
Hello,
 I want to bind textboxes and comboboxes to the columns of the Grid, In the textbox i want to validate the ip addresses, 
Is it possible to achieve?
A sample code would be helpful.

Thanks in advance 
Hristo Deshev
Telerik team
 answered on 11 Feb 2009
3 answers
494 views
I am trying to implement a simple drag and drop procedure in a RadGridView.  Using the SelectedItem property, I am able to tell which item in the grid I am using when I start dragging, but I also need to know which item they are dropping the item on.  How can I find which item in the list is at a specific position  (e.GetPosition)?

Sterling
Vlad
Telerik team
 answered on 11 Feb 2009
1 answer
124 views

Hello

I want to make carousel items 100% width, but unable to achieve that. Any help would be appreciated.

Here's the code

  <Grid>
<Grid.Resources>
<DataTemplate DataType="{x:Type local:XTraItem}">
<Grid Grid.Column="0" Grid.Row="0" Width="1000">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="100"/>
<ColumnDefinition Width="900"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition/>
</Grid.RowDefinitions>

<Image Source="{Binding Path=ImageURI}" Grid.Column="0" Grid.Row="0" />
<TextBlock Text="{Binding Path=Name}" Foreground="AliceBlue" Grid.Column="1" Grid.Row="0" />
</Grid>
</DataTemplate>
</Grid.Resources>
<telerik:RadCarousel x:Name="XTraCarousel" AutoGenerateDataPresenters="False" HorizontalAlignment="Stretch" VerticalAlignment="Stretch"/>

Milan
Telerik team
 answered on 10 Feb 2009
3 answers
601 views

Hello,


I have the following requirements/queries regarding the grid:

1) How easy is to accommodate other controls (like combobox,textbox,maskedtexbox) in the cell.

2) How easy is to template grid/cell/datarow

3) Binding with observable collection

4) What about validation, do we have any numeric text box, date time picker, ip address text box support.

5) Can we template grouping row.

6) Triggers/Data triggers/Multi triggers support

7) Icon/Card view support

8) Read only level (I.e. it should be at cell, column, row level)

9) Selective sorting support (i.e. can we specify which column to sort and which to not)

10) Does column adjust its width according to data content.

11) Templating datarow/datacell (for ex. Placing image in place of text content) is possible or not.

12) Inplace editing with two way binding.

13) Selective readonly support (i.e. can we specify which column should be readonly and which should not)

14) Can we get cell validation exception so that we can handle it accordingly.

15) In case the validation fails at certain cell does the focus remain on the same cell.

16) Validation exception - can we get them on grid lost focus.

17) Do we have support for events like – grouping, sorting, gridlostfocus, Celllostfocus, rowlostfocus,mouse events at cell/row/grid level etc.

18) Add new row support.

19) Support for deferred/Immediate scrolling.

20) Do we have automatic support for checkbox column (ie. If we bind a column to bool field then automatic checkbox should appear in that column, if not how to place checkbox in a clolumn bound to a bool field)

21) Can we template header row to say have a checkbox in header row to select all checkboxes of all the rows

22) Do we have support for fixed header and footers.

23) Number of themes available.

24) Do we have sample that shows ip address masking in the cell.

25) Context menu on grid rows.

26) Do we have functions to get object/item from the row/container and vice versa

Please suggest me how to achieve above requirements, a sample code will certainly help in meeting this requirements and preparing a demo application.

It will be helpful if you answer the queries with a yes/no.

Thanks in advance

 

 

 

Prash
Top achievements
Rank 1
 answered on 10 Feb 2009
1 answer
136 views
When I am trying to bind the grid by itemSource then i get the following exception

Method not found: 'System.Windows.Threading.DispatcherOperation System.Windows.Threading.Dispatcher.BeginInvoke(System.Delegate, System.Object[])'

Please suggest the cause and the solution.
Thanks and regards
Stefan Dobrev
Telerik team
 answered on 09 Feb 2009
3 answers
291 views
Hi,
 I want custom context menu for parent and child node. I am binding my tree with a collection in code behind. How can I achive my goal?
 
Tihomir Petkov
Telerik team
 answered on 09 Feb 2009
1 answer
135 views
Hi,
Is there any way to get the selected node in the tree(WPF). I want to get the selected item(node) when I click on the context menu.
I want ot add a node in the tree dynamically on selection of new from the context menu. 
Tihomir Petkov
Telerik team
 answered on 09 Feb 2009
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
DataPager
PersistenceFramework
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
LayoutControl
ProgressBar
Sparkline
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
Callout
PasswordBox
SplashScreen
Localization
Rating
Accessibility
CollectionNavigator
AutoSuggestBox
Security
VirtualKeyboard
HighlightTextBlock
TouchManager
StepProgressBar
Badge
OfficeNavigationBar
ExpressionParser
CircularProgressBar
SvgImage
PipsPager
SlideView
AI Coding Assistant
+? more
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?