Telerik Forums
UI for WPF Forum
1 answer
103 views
Hi,

I have a SumFuncion in my gridviewThis summing all the column values.

I need that when the total sum is negative it appears on screen 0.

Can you help me?

Thanks,
Alexandre Rodrigues
Maya
Telerik team
 answered on 27 Sep 2010
2 answers
74 views
I have a master/detail hierarchy implementation (see attached picture).

I have coded to RowLoaded event to set GridViewRow.IsExpandable = false for master rows whose detail collection is empty.  I wanted to visually show that there were no associated details, and save the user from clicking on the (+) expander control needlessly.  I have set ShowInsertRow="True", and my preference is to keep ShowInsertRow="False".  Instead, I would like to have a button (elsewhere in the UI) to call the BeginInsert() method.  However, how do I target the detail level - particularly if the master row has an empty detail collection?
Wellpartner
Top achievements
Rank 1
 answered on 25 Sep 2010
1 answer
172 views
Hi!

I have a grid which has another grid in its row details. Both grids should have a context menu, however, if I right-click in the row details grid, it shows me the context menu of the parent grid. Is there a way to have it show the child grid's context menu when right-clicking on the child?
Veselin Vasilev
Telerik team
 answered on 24 Sep 2010
3 answers
140 views
Hi!

After I load my data in my bounded list, I'm doing an "ExpandAll" on my tree, but nothing is expanding. Why?

Thank you
Petar Mladenov
Telerik team
 answered on 24 Sep 2010
5 answers
199 views
Hi!

How can I programatically expand a Tree to a specified RadTreeItem?

I've an ItemPrepared method that select it, and I want to open all part of my tree to get my element visible:

private void RadTreeViewItemPrepared(object sender, Telerik.Windows.Controls.RadTreeViewItemPreparedEventArgs e)
{
    e.PreparedItem.IsSelected = true;
    //Do something on _uxRadTreeView to display my e.PreparedItem displayec
}
Hristo
Telerik team
 answered on 24 Sep 2010
2 answers
69 views
Hi,

I'm using the ToCsv method on the grid view. Some of my headers in that grid are TextBlock's (so that I can add a tooltip), i.e:

<Controls:GridViewDataColumn.Header>
    <TextBlock ToolTip="Product Quantity">Prod Qty</TextBlock>
</Controls:GridViewDataColumn.Header>

However, when in the CSV text, the column shows up as "System.Windows.Controls.TextBlock" as I guess it's just doing a ToString on whatever the column header is. Is there a way to change what is used by ToCsv to name headers?
Geoff Smith
Top achievements
Rank 1
 answered on 24 Sep 2010
5 answers
844 views
Hello

How do I set the top left form icon form via code?
I have attached a sample section of code and
given the Image a name of imgFormIcon but
I cannot reference via code?

Regards,
Simon

<telerik:RadWindow x:Class="Designer.Forms.LoginWindow"<br>        xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"<br>        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"<br>        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"<br>        Height="202" Width="406" FontFamily="Verdana" WindowStartupLocation="CenterScreen" Name="frmLogin" Loaded="frmLogin_Loaded" Header="Login"><br>    <telerik:RadWindow.IconTemplate><br>        <DataTemplate><br>            <Image Source="" Stretch="UniformToFill" MaxHeight="16" MaxWidth="16" Name="imgFormIcon" /><br>        </DataTemplate><br>    </telerik:RadWindow.IconTemplate><br>    <Grid><br>        <Grid.RowDefinitions><br>            <RowDefinition Height="12" /><br>            <RowDefinition Height="24" /><br>            <RowDefinition Height="36" /><br>            <RowDefinition Height="24" /><br>            <RowDefinition Height="24" /><br>            <RowDefinition Height="12" /><br>            <RowDefinition Height="24" /><br>            <RowDefinition Height="212*" /><br>        </Grid.RowDefinitions><br>        <Grid.ColumnDefinitions><br>            <ColumnDefinition Width="70" /><br>            <ColumnDefinition Width="120" /><br>            <ColumnDefinition Width="240" /><br>        </Grid.ColumnDefinitions><br>        <Image Height="48" HorizontalAlignment="Left" Margin="12,0,0,0" Name="imgIcon" Stretch="Fill" VerticalAlignment="Top" Width="48" Grid.Row="1" Grid.RowSpan="2" /><br>        <Label Content="Login Credentials:" Grid.Column="1" Grid.Row="1" Height="24" HorizontalAlignment="Left" Margin="0,0,0,0" Name="label1" VerticalAlignment="Top" FontSize="10" FontWeight="Bold" /><br>        <Label Content="Authentication:" Grid.Column="1" Grid.Row="2" Height="24" HorizontalAlignment="Left" Margin="0,0,0,0" Name="label2" VerticalAlignment="Top" FontSize="10" /><br>        <Label Content="Username:" Grid.Column="1" Grid.Row="3" Height="24" HorizontalAlignment="Left" Margin="0,0,0,0" Name="label3" VerticalAlignment="Top" FontSize="10" /><br>        <Label Content="Password:" Grid.Column="1" Grid.Row="4" Height="24" HorizontalAlignment="Left" Margin="0,0,0,0" Name="label4" VerticalAlignment="Top" FontSize="10" /><br>        <RadioButton Content="Windows Authentication" Grid.Column="2" Grid.Row="2" Grid.RowSpan="2" Height="16" HorizontalAlignment="Left" Margin="0,4,0,0" Name="rdbWindowsAuthentication" VerticalAlignment="Top" FontSize="10" GroupName="Authentication" IsChecked="True" /><br>        <RadioButton Content="Standard Authentication" Grid.Column="2" Grid.Row="2" Grid.RowSpan="2" Height="16" HorizontalAlignment="Left" Margin="0,20,0,0" Name="rdbStandardAuthentication" VerticalAlignment="Top" FontSize="10" GroupName="Authentication" /><br>        <telerik:RadMaskedTextBox Grid.Column="2" Grid.Row="3" HorizontalAlignment="Left" Name="txtUsername" VerticalAlignment="Top" Width="180" MaskType="None" Mask="" FontSize="10" /><br>        <telerik:RadMaskedTextBox Grid.Column="2" Grid.Row="4" HorizontalAlignment="Left" Name="txtPassword" VerticalAlignment="Bottom" Width="180" MaskedText="" Margin="0,0,0,2" MaskType="None" Mask="" FontSize="10" /><br>        <telerik:RadButton Content="Login" Grid.Column="2" Grid.Row="6" Height="22" Width="75" HorizontalAlignment="Left" Margin="0,0,0,0" Name="cmdLogin" VerticalAlignment="Top" IsDefault="True" /><br>        <telerik:RadButton Content="Close" Grid.Column="2" Grid.Row="6" Height="22" Width="75" HorizontalAlignment="Left" Margin="80,0,0,0" Name="cmdClose" VerticalAlignment="Top" IsCancel="True" /><br>    </Grid><br></telerik:RadWindow><br>
Simon
Top achievements
Rank 1
 answered on 24 Sep 2010
3 answers
70 views
How would I provide custom text (or whatever other content) to AxisX labels?
Evgenia
Telerik team
 answered on 23 Sep 2010
4 answers
201 views
First question:

Is it possible to have IsLoadOnDemand = true but NOT show the arrows on some items? (The arrows that indicate the items have items themselves). Not all our items have children, so we don't want to show the arrows in all of the items.

http://www.screencast.com/users/CarloToribio/folders/Jing/media/abe8d5f6-a1f0-4776-9812-b709f3ff4c97

Second question:

How can I make the items show the loading animation while I'm doing something in the LoadOnDemand event? We're trying to deserialize some objects in there, and it might take a second or two, but the animation doesn't show up, it just freezes for those two seconds. I tried it this way but no luck:

private void treeView_LoadOnDemand(object sender, RadRoutedEventArgs e)
{
    RadTreeViewItem clickedItem = e.Source as RadTreeViewItem;
 
    clickedItem.Dispatcher.BeginInvoke(new ThreadStart(delegate
        {
            clickedItem.Items.Add(new RadTreeViewItem() { Header = clickedItem.Header + "." + (clickedItem.Items.Count + 1) });
 
            Thread.Sleep(2000);
        }));
}

Any suggestions?

Thanks.

Thanks.
Viktor Tsvetkov
Telerik team
 answered on 23 Sep 2010
4 answers
176 views
Hi

Validating data on a property level causes a red rectagle around the cell but no error message is available.
Below an example and attached the snapshot.

<Window xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"  x:Class="TestRadGridView.MainWindow"
        Title="MainWindow" Height="350" Width="525">
    <Grid>
        <telerik:RadGridView Name="gridView"/>
    </Grid>
</Window>

and the code behind
using System;
using System.Collections.Generic;
using System.Windows;
using System.Windows.Documents;
  
namespace TestRadGridView
{
    public partial class MainWindow : Window
    {
        public MainWindow()
        {
            InitializeComponent();
            gridView.ItemsSource = User.AsList();
        }
    }
  
    class User
    {
        private string _username;
        public string Username 
        
            get { return _username; } 
            set { if ( _username == null) _username=value; else throw new Exception("Username can't be changed"); } 
        }
  
        public string Email { get; set; }
  
        public static List<User> AsList()
        {
            List<User> list = new List<User>();
            list.Add(new User() {Username="Username1", Email="username1@email"});
            list.Add(new User() {Username="Username2", Email="username2@email"});   
            return list;
        }
    }
}

I'm using WPF Q2 2010 SP1 on Windows 7.

Thanks
Ivano

Ivano
Top achievements
Rank 1
 answered on 23 Sep 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
Security
VirtualKeyboard
HighlightTextBlock
TouchManager
StepProgressBar
Badge
OfficeNavigationBar
ExpressionParser
CircularProgressBar
SvgImage
PipsPager
SlideView
AI Coding Assistant
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?