Telerik Forums
UI for WPF Forum
3 answers
363 views
I have an issue where the initial value of a RadNumericUpDown is not visible, when focused by FocusManager.FocusedElement in xaml.

If FocusManager is removed or you tab out of the input-field, the value showed correctly.

A little bug, but big usability-impact in our application.

Telerik version: 2014.3.1021.40
Visual Studio version: Premium 2012

Screendump attached.
I have a small POC app if required.
Kalin
Telerik team
 answered on 18 Nov 2014
1 answer
316 views
Hi,

I'm trying to add a tooltip to a radProgressBar and I'm having some issues.

I did something like that but it doesn't work, it gives an empty tooltip :
<telerik:RadProgressBar>
     <telerik:RadProgressBar.ToolTip>
          <ToolTip Content="{Binding Path=DataContext.SomeProperty, ElementName=SomeParent}"/>
     </telerik:RadProgressBar.ToolTip>
</telerik:RadProgressBar>

Same result for this :
<telerik:RadProgressBar telerik:RadToolTipService.ToolTipContent="{Binding Path=DataContext.SomeProperty, ElementName=SomeParent}"/>

The only way I've been able to have something interesting is by doing this :
<telerik:RadProgressBar ToolTip="{Binding Path=DataContext.SomeProperty, ElementName=SomeParent"/>

The problem is that I want to use ContentStringFormat and do something like this :
<telerik:RadProgressBar>
     <telerik:RadProgressBar.ToolTip>
          <ToolTip Content="{Binding Path=DataContext.SomeProperty, ElementName=SomeParent}" ContentStringFormat="{}{0:P2}"/>
     </telerik:RadProgressBar.ToolTip>
</telerik:RadProgressBar>

Am I doing somthing wrong or there is a bug with tooltip ?

Thank you,

Etienne
Petar Mladenov
Telerik team
 answered on 18 Nov 2014
1 answer
109 views
Hello,

How do I delete a thread I posted?

This one:
http://www.telerik.com/forums/radtileview-xaml-vm-of-tile-items-vary-change

Thx
Yana
Telerik team
 answered on 18 Nov 2014
14 answers
1.5K+ views
I have a gridview on a control.  I have set the grid to have a datasource relative to a property on the control:

<telerik:RadGridView Grid.Row="1" Name="adjustments" CanUserDeleteRows="False" CanUserInsertRows="False" CanUserResizeRows="False" ShowGroupPanel="False" SelectionChanged="adjustments_SelectionChanged"
        ItemsSource="{Binding Path=CurrentClaim.claimAdjustments, RelativeSource={RelativeSource FindAncestor, AncestorType=UserControl}}" AutoGenerateColumns="False" IsReadOnly="True" MouseDoubleClick="adjustments_MouseDoubleClick">
<telerik:RadGridView.Columns>
      <telerik:GridViewDataColumn Name="colCreatedOn" DataMemberBinding="{Binding createdOn}" Header="Posting Date" DataFormatString="{}{0:MM/dd/yyyy}" SortingState="Descending"  />
      <telerik:GridViewDataColumn DataMemberBinding="{Binding claimAdjustmentReason.description}" Header="Reason" />
</telerik:RadGridView.Columns>
</telerik:RadGridView>

The property CurrentClaim does notify the grid and the grid does update the data when the new claim is set in CurrentClaim.  The problem is that the grid is sorted based on the first column, but when new data is loaded into the grid it is not sorted by this column.  Can someone please tell me what I am doing wrong or why the sort doesn't work when new data is loaded?

-Lee


Anthony
Top achievements
Rank 1
Iron
Iron
Veteran
 answered on 17 Nov 2014
2 answers
136 views
Hi,

I'm trying to use the Slider with selection range enabled into a RadListBox item template. The items in the listbox are draggable to do some manual sorting. When I try to move the slider range values, the whole item is dragged and I cannot change the values. Is there a way to prevent item drag when the slide range values are been changed?

Thanks, Jose
Jose
Top achievements
Rank 1
 answered on 17 Nov 2014
1 answer
437 views
Hi,

in MVVM scenario I need dynamically generate columns for RadGridView.

I created attached property for this purpose.

ItemSource is bind to property ObservableCollection<Company> Companies from VM

where Company is

    
public class Company : INotifyPropertyChanged
    {
        public Company()
        {
            Dept = new Dictionary<string, User>();
        }
 
        private Dictionary<string,User> dept;
 
        public Dictionary<string,User> Dept
        {
            get { return dept; }
 
            set
            {
                dept = value;
                OnPropertyChanged("Dept");
            }
        }
    }

and User is

    
public class User : INotifyPropertyChanged
    {
 
        private string firstName;
 
        public string FirstName
        {
            get { return firstName; }
 
            set
            {
                firstName = value;
                OnPropertyChanged("FirstName");
            }
        }
 
        private string lastName;
 
        public string LastName
        {
            get { return lastName; }
 
            set
            {
                lastName = value;
                OnPropertyChanged("LastName");
            }
        }
    }


I generate columns in VM in this way.

In VM I have property ObservableCollection<ColumnDefinition> which is bind to attached property in View.

ColumnDefinition is abstraction for GridViewDataColumn.

<telerik:RadGridView ItemsSource="{Binding Path=Country.Companies, UpdateSourceTrigger=PropertyChanged}"
                     dynamicCol:RadGridViewColumnsBinding.ColumnsCollection="{Binding Path=Columns}">
    <telerik:RadGridView.Resources>
        <DataTemplate x:Key="UserTemplate"
                      DataType="{x:Type models:User}">
            <StackPanel>
                <TextBlock Text="LastName:" />
                <TextBlock Text="{Binding Path=LastName}" />
            </StackPanel>
        </DataTemplate>
    </telerik:RadGridView.Resources>
</telerik:RadGridView>


When I need add column to RadGridView I add ColumnDefinition obj to property Columns.

I need apply DataTemplate on GridViewDataColumn and this is which not work for me.

Exactly binding to property User.LastName in DataTemplate not work.

I use this binding exp for GridViewDataColumn 

                      
string bindingExp = string.Format("Dept[{0}]", columnName);
//string bindingExp = string.Format("Dept[{0}].LastName", columnName); // whithout datatemplate this work
 
                      var binding = new Binding(bindingExp)
                      {
                          UpdateSourceTrigger = UpdateSourceTrigger.PropertyChanged
 
                      };
 
                      Columns.Add(new ColumnDefinition
                      {
                          Header = columnName,
                          DataMemberBinding = binding,
                          Tag = ColumnTag,
                          UniqueName = Guid.NewGuid().ToString(),
                          CellTemplateName = "UserTemplate",
                      });




I try attached several times sample project but always get error:

The selected file(s) cannot be attached because it may exceed the maximum attachment size (2 MB) or is from not allowed type (allowed: .gif, .jpg, .jpeg, .png).

Attached file size is 74 KB.

Hence I uploded sample project to onedrive.

You can download here.
Dimitrina
Telerik team
 answered on 17 Nov 2014
3 answers
124 views
Hi, I would like to enquire on a solution to the problem as per title. I am dragging between 2 RadListBox. Below is an example of the desired effect I would like to achieve:

A drag drop event

Dragged 'Equipment' objects (with ID and Quantity properties):
ID: 2, Quantity: 2
ID: 5, Quantity: 3
ID: 9, Quantity: 1

Destination Objects ('Equipment' objects already in destination RadListBox):
ID: 1, Quantity: 3
ID: 2, Quantity: 3
ID: 9, Quantity: 2


Desired outcome in destination RadListBox after drag drop event:
ID: 1, Quantity: 3
ID: 2, Quantity: 5 (3+2)
ID: 5, Quantity: 3
ID: 9, Quantity: 3 (2+1)

Instead of:
ID: 1, Quantity: 3
ID: 2, Quantity: 3
ID: 9, Quantity: 2
ID: 2, Quantity: 2
ID: 5, Quantity: 3
ID: 9, Quantity: 1


Thanks a lot for your attention. Please let me know if further details is needed.
​





Kalin
Telerik team
 answered on 17 Nov 2014
12 answers
338 views
Hi support,

I want my Schedule View to look like  this. Please let me know how I can change a new Schedule to look exactly like this.

Please guide me or send me some code snippet or zip files. this is very critical because we are dedcing to use Schedule View or not.

Thanks for the help,
Vivek.
Yana
Telerik team
 answered on 17 Nov 2014
8 answers
171 views
Hello,

I'am using RadTileView as a Dashboard that will show status of 8 different stations. These stations follow a workflow and can be in different states. Each state has a specific Large View. The Small and Normal will all look similar. Also, as a station changes from StateX to StateY, I receive that info through an EventHandler and want to change thus the XAML + its associated ViewModel in its corresponding Large tile.

I think through the DataTemplate (see below) it is doable. However, from the codebehind, how do I :
1- Empty Large Content for the corresponding Tile,
2- Set it with a different XAML (currently existing as UserControl) and set its datacontext to its specific ViewModel.

<DataTemplate x:Key="ContentTemplate" >
                <telerik:RadFluidContentControl ContentChangeMode="Manual" Name="radFluidContentControl"
                        State="{Binding RelativeSource={RelativeSource AncestorType=telerik:RadTileViewItem}, Path=TileState, Converter={StaticResource fluidContentStateConverter}}">
                    <telerik:RadFluidContentControl.SmallContent>
                        <local:SmallContent x:Name="smallContent"/>
                    </telerik:RadFluidContentControl.SmallContent>
                    <telerik:RadFluidContentControl.Content>
                        <local:Content x:Name="normalContent" />
                    </telerik:RadFluidContentControl.Content>
                    <telerik:RadFluidContentControl.LargeContent>
                        <!-- ***************** -->
                        <!-- The XAML + its VM would vary for each items in tile view. How do I set these individually for each Tile????-->
                        <!-- ***************** -->
                        <local:LargeContentConfig x:Name="largeContent" />
                    </telerik:RadFluidContentControl.LargeContent>
                </telerik:RadFluidContentControl>
            </DataTemplate>

Thx
Chris

Thx
Pavel R. Pavlov
Telerik team
 answered on 17 Nov 2014
1 answer
162 views
Hi,

I have a WPF model with a table "table1" composed by "table1_column1", "table1_column2" and "table1_column3" and another table "table2" composed by "table2_column1", "table2_column2" and "table2_column3".
I have a 0..1 relation from "table1" to "table2", it means that an object from "table1" can be related with 0 or 1 "table2" object.
Now I have create a RadGridView that takes all the table1 objects as ItemsSource.
I have the following columns in the RadGridView: "table1_column1", "table1_column2", "table1_column3", "table2_column1" and everything is working fine, except for two problems: if I try to sort the grid by "table2_column1" or use a filter on "table2_column1", no entry is shown in the table, just the headers.
Sorting and filtering on "table1_column1", "table1_column2" and "table1_column3" work fine.
Here is the RadGridView code.

<telerik:RadGridView Name="dataGrid1" FrozenColumnCount="10" Margin="0,72,0,12" AllowDrop="True" AutoGenerateColumns="False" EnableColumnVirtualization="True" CanUserSortColumns="True" CanUserResizeColumns="True" CanUserReorderColumns="True" ShowGroupPanel="False" ShowColumnSortIndexes="False" MouseDoubleClick="showDetails">
 
            <telerik:RadGridView.Columns>
 
                <telerik:GridViewDataColumn x:Name="table1_column1" Header="table1_column1" DataMemberBinding="{Binding Path=table1_column1}" IsReadOnly="true"/>
                <telerik:GridViewDataColumn x:Name="table1_column2" UniqueName ="table1_column2" Header="table1_column2" DataMemberBinding="{Binding Path=table1_column2}" IsReadOnly="true" Width="100" IsAutoGenerated="False"/>
                <telerik:GridViewDataColumn x:Name="table1_column3" Header="table1_column3" DataMemberBinding="{Binding Path=table1_column3}" IsReadOnly="true"/>
                <telerik:GridViewDataColumn x:Name="table2.table2_column1" Header="table2_column1" DataMemberBinding="{Binding Path=table2_column1}" IsReadOnly="true"/>
                 
            </telerik:RadGridView.Columns>
        </telerik:RadGridView>


Any suggestion?

Thanks.
Dimitrina
Telerik team
 answered on 17 Nov 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
DataPager
PersistenceFramework
Styling
TimeBar
OutlookBar
TransitionControl
FileDialogs
Book
ToolBar
ColorPicker
TimePicker
MultiColumnComboBox
SyntaxEditor
VirtualGrid
NavigationView (Hamburger Menu)
Wizard
ExpressionEditor
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?