Telerik Forums
UI for WPF Forum
1 answer
100 views
By default each column can be sorted in 3 ways: Ascending, Descending, No Sort. How do I get rid of the third state, but have each the column can only be sorted either in ascending or descending order when I click the column header?

Thanks,
Yang
Ваня
Top achievements
Rank 1
 answered on 21 Jun 2010
3 answers
150 views
Hi All

I have bound the ItemSource of the RadBook to an ObservableCollection of classes, then I am using the item template to create a user control that binds it DataContext to the object. This is working well. I found however that I need to ensure that all the UserControls are loaded as soon as the ItemSource of the RadBook is Updated. Right now they only load when you navigate to that page.

Is there any method that I can call that does not require me to cause the book to iterate through all the pages?

Thanks for you help

Nick
Kiril Stanoev
Telerik team
 answered on 21 Jun 2010
1 answer
302 views

       Hello!  you may have a look at the attach.why the horizontal scrollbar can't auto hide? how to solve this problem ?

          

<Telerik:RadTreeView Name="_treeView" ScrollViewer.VerticalScrollBarVisibility="Auto"  ScrollViewer.HorizontalScrollBarVisibility="Auto"  SelectionMode="Extended" ExpanderStyle="{StaticResource Expander}" local:TreeViewHelper.EnableRightClickSelection="True" MouseRightButtonDown="_treeView_MouseRightButtonDown" PreviewMouseRightButtonDown="_treeView_PreviewMouseRightButtonDown">  
            <telerikNavigation:RadContextMenu.ContextMenu > 
                <telerikNavigation:RadContextMenu  x:Name="radTreeViewMenu">  
                    <telerikNavigation:RadMenuItem Header="View In Master Document" Tag="View in Master Document"/>  
                    <telerikNavigation:RadMenuItem Header="Show PDF" Tag="SHOW PDF" IsEnabled="False"/>  
                    <telerikNavigation:RadMenuItem Header="Show PDF AT Division" Tag="Show PDF AT Division" IsEnabled="False"/>  
                    <telerikNavigation:RadMenuItem Header="Copy Division" Tag="Copy Division" IsEnabled="False"/>  
                    <telerikNavigation:RadMenuItem Header="Job Ticket" Tag="Job Ticket" IsEnabled="False"/>  
                </telerikNavigation:RadContextMenu> 
            </telerikNavigation:RadContextMenu.ContextMenu> 
</Telerik:RadTreeView> 

If you see this message,please reply as soon as possible.I 'm very anxious. Thanks my friend.

Dimitrina
Telerik team
 answered on 21 Jun 2010
1 answer
93 views
Hi,

I've set up a RadComboBox with the following configuration:

IsTextSearchEnabled="True" 
IsFilteringEnabled="True" 
TextSearchMode="Contains"

SelectedItem, SelectedText, IsDropDownOpen and Text are bound to my data.  I can start typing and click to select an item once, but if I search (type) again and click on the same item a second time, it is not selected.  Only the text I typed is displayed in the combobox.

After removing IsFilteringEnabled and TextSearchMode, clicking the item a second time works as expected.  Adding either of them will re-create the problematic behavior.

Is anyone aware of a workaround?

Thanks,
Andrew
George
Telerik team
 answered on 21 Jun 2010
1 answer
86 views
Hello, how do I change the image for a WPF Radbutton for onClick or other events like onHover etc?

Thanks
Dimitrina
Telerik team
 answered on 21 Jun 2010
4 answers
284 views
I have a grid view containing several hundred rows, each of which will need to contain an image referenced via a URL. These images will come from a remote server via http.

Using an imagecolumn, with the image source bound to my arraylist containing the URL, the grid does not display until all images are downloaded, which takes some time and causes the UI thread to be unresponsive. I need to add the images asynchronously so that the rest of the row data is visible but the images appear one by one as they are downloaded (as a standard web page would).

How can I best achieve this?

Many thanks.
Vlad
Telerik team
 answered on 21 Jun 2010
3 answers
148 views
Hi,

I use a RadTimePicker as a CellEditTemplate in a RadGridView with binding a DataTable.
I managed to bind the data to the TimePicker and it displays correctly (e.g. 12:23:59), but I can change its value only to timestamps in hour (e.g. 12:00:00). How can I change its value to such a date as 23:34:56?

Thanks in advance!

Feri
Konstantina
Telerik team
 answered on 21 Jun 2010
1 answer
314 views
Hi,

I am using Telerik Controls for WPF Q3 2009 (2009.3.1314.35), .NET 3.5 SP1, Windows XP SP2. I have two problems.

(1)
I have a grid bound to a (strongly typed) DataTable which has two dependent columns (in my project they're bound to the same data but display it differently). My goal is to have one column update when another changes, meaning on CellEditEnded (preferably) or RowEditEned.

For example:
<telerik:RadGridView Name="RadGridView" AutoGenerateColumns="False">
    <telerik:RadGridView.Columns>
        <telerik:GridViewDataColumn DataMemberBinding="{Binding Product_Name}" Header="Product Name"/>
        <telerik:GridViewDataColumn DataMemberBinding="{Binding Product_Name}" Header="Product Name Again"/>
    </telerik:RadGridView.Columns>
</telerik:RadGridView>

I want "Product Name Again" to refresh after "Product Name" is edited.

Searching through the forums and experimenting, I couldn't find a solution that completely works.
I should note that the same situation, but when binding to an ObservableCollection of CLR objects, works with no problem.

I tried the following:

When binding to DataTable.DefaultView, the dependent column is affected when UPDATING an existing row, but not when INSERTING a new row.
When inserting, the dependent column refreshes only after entering edit mode again and committing.

When binding directly to DataTable, updating works, but when inserting the new row visually disappears when the editing is finished. I implemented AddingNewDataItem and RowEditEnded to enable inserting.

I did something like this (assuming null is valid for all columns of the products table):
        private void RadGridView_AddingNewDataItem(object sender, Telerik.Windows.Controls.GridView.GridViewAddingNewEventArgs e)
        {
            // _productsDataTable is a strongly typed reference to the DataTable
            var product = _productsDataTable.NewProductsRow();
            e.NewObject = product;
        }

        private void RadGridView1_RowEditEnded(object sender, Telerik.Windows.Controls.GridViewRowEditEndedEventArgs e)
        {
            if (e.EditOperationType == Telerik.Windows.Controls.GridView.GridViewEditOperationType.Insert &&
                e.EditAction == Telerik.Windows.Controls.GridView.GridViewEditAction.Commit)
            {
                _productsDataTable.AddProductsRow(e.NewData as ProductsRow);
            }
        }
       
(I also tried adding the row to the table in AddingNewDataItem instead of in RowEditEnded, but got the same result)

Do have any suggestions on what might work?

=============

(2)
I have a grid ordered by a non-visible "priority" field, with CanUserReorderColumns=False. I'm unable to make the ordering refresh when the "priority" changes.

The grid has one column that looks something like this:

Change priority
---------------
   [+] [-]
   [+] [-]
   [+] [-]

If for example, the user clicks [+] on the second row, a command is invoked on a ViewModel class which changes the "priority" values of the first and second rows, so that after reordering the rows will swap places.

A requirement is that the user will always be able to click the buttons in one step, without needing to enter edit-mode first with F2/click etc.
To achieve this, I defined the buttons in the column's CellTemplate and prevented it from ever entering edit mode.

The problem is, after clicking the buttons, the underlying data changes but the grid isn't automatically reordered (which I guess is because the grid isn't aware of any edit action). The underlying data implements INotifyPropertyChanged.

I tried triggering reordering manually, but the buttons' OnClick/OnMouseUp events fire before their commands, so it had no effect.

Thanks in advance,
Yuri
Stefan Dobrev
Telerik team
 answered on 21 Jun 2010
2 answers
403 views
Good day!

I have a form with a stack panel of questions. Each question has a number of answers which look like a list of radiobuttons.
I make my xaml dynamically:

<StackPanel x:Name="spQuestions" Orientation="Vertical" Grid.Column="1" Grid.Row="8" Grid.ColumnSpan="3" HorizontalAlignment="Left">
</StackPanel>


foreach (QuestionDTO question in questions)
            {
                StackPanel newsp = new StackPanel();
                newsp.Orientation = Orientation.Vertical;
                TextBlock textBlock = new TextBlock();
                textBlock.Text = question.Text;
                newsp.Children.Add(textBlock);
                   RadGridView gridView = new RadGridView();
                    gridView.Name = "grAnsw" + question.Id.ToString();
                    gridView.ItemsSource = question.Answers;
                    gridView.AutoGenerateColumns = false;
                    gridView.IsReadOnly = true;
                    GridViewRadioButtonColumn col = new GridViewRadioButtonColumn();    
                    gridView.Columns.Add(col);
                    newsp.Children.Add(gridView);
                    spQuestions.Children.Add(newsp);
       }


where

public class GridViewRadioButtonColumn : GridViewDataColumn
{
        public override FrameworkElement CreateCellElement(GridViewCell cell, object dataItem)
        {
            var radioButton = cell.Content as RadioButton;
            if (radioButton == null)
            {
                radioButton = new RadioButton();
                radioButton.SetBinding(RadioButton.ContentProperty, new Binding("Text")
                {
                  Source = dataItem
                });
                cell.Content = radioButton;
            }
            return radioButton;
        }
}


In the result I have the page which I wanted, but all radio buttons look like they are in the same list. So I can check only one radiobutton on the page, but I want to check one radiobutton in one question, but there are a number of questions on the page =(
How can I make the page see that there are different lists of radiobuttons for each question?

Thank you.
lina fetisova
Top achievements
Rank 1
 answered on 21 Jun 2010
5 answers
120 views
Has anyone else found the level of changes to public members in each new release very frustrating?

I have a few developers working with the Calendar, GridView and Charts and with each new release we find ourselves spending a significant amount of time recreating templates because of breaking changes introduced by the latest binaries. We have customized the look of these controls to suit our needs and in many cases we found it necessary to provide our own template.

I've attached a screenshot of the Calendar after applying the 2010.1 603 release. I'd like to hear from others using this forum if you have had similar experiences.

Thanks,
Mike


Hristo
Telerik team
 answered on 19 Jun 2010
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
Book
FileDialogs
ToolBar
ColorPicker
TimePicker
SyntaxEditor
MultiColumnComboBox
VirtualGrid
Wizard
ExpressionEditor
NavigationView (Hamburger Menu)
DesktopAlert
WatermarkTextBox
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
VirtualKeyboard
HighlightTextBlock
Security
TouchManager
StepProgressBar
Badge
OfficeNavigationBar
ExpressionParser
CircularProgressBar
SvgImage
PipsPager
SlideView
AI Coding Assistant
+? more
Top users last month
Ambisoft
Top achievements
Rank 2
Iron
Pascal
Top achievements
Rank 2
Iron
Matthew
Top achievements
Rank 1
Sergii
Top achievements
Rank 1
Iron
Iron
Andrey
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Ambisoft
Top achievements
Rank 2
Iron
Pascal
Top achievements
Rank 2
Iron
Matthew
Top achievements
Rank 1
Sergii
Top achievements
Rank 1
Iron
Iron
Andrey
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?