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

We have a RadGridView with some custom column implementations, changeing the original value bound to this columns. Now we have the problem, that the default sort mechanism sorts the rows with the original values from the data source, but it should be sorted with the displayed column values. I also can not use the expression sort descriptors, I have no access to the displayed type at compoleing time.

Is there a way to change this behavior?

Thanks for help,
Michael
Rossen Hristov
Telerik team
 answered on 14 Sep 2012
0 answers
248 views
Hi,

I tried adding and event trigger on my GridViewDataColumn but it doesn't seem to fire the command.

<telerik:GridViewDataColumn CellStyle="{StaticResource IndexColumnStyle}"
                                            DataMemberBinding="{Binding Index}"
                                            Header="Index"
                                            IsReadOnly="True">
<i:Interaction.Triggers>
<i:EventTrigger EventName="CellDoubleClick">
<GalaSoft_MvvmLight_Command:EventToCommand Command="{Binding EditCommand}"
CommandParameterValue="Edit"
PassEventArgsToCommand="True" />
</i:EventTrigger>
</i:Interaction.Triggers>
</telerik:GridViewDataColumn>

Is it actually possible to add event trigger to GridViewDataColumn?
Mark
Top achievements
Rank 1
 asked on 14 Sep 2012
1 answer
128 views
sorry new to WPF
i'm having trouble understanding how to load the RadDiagramToolbox from codebehind with the standard shape.

Any help is greatly appreciated

FF
Petar Mladenov
Telerik team
 answered on 14 Sep 2012
0 answers
457 views
I have a column

       <telerik:GridViewDataColumn

                    UniqueName="CarrierCommission"

                                  DataFormatString="c"

                                  IsVisible="{Binding Path=SearchCriteria, Converter={StaticResource CarrierColumnConverter}}"

                                  Header="{StaticResource CarrierCommission}"

                                  DataMemberBinding="{Binding Path=CarrierRepCommission}"

                                  Width="{StaticResource CommissionColumnWidth}">

        </telerik:GridViewDataColumn>

I would like to programmatically refresh the IsVisible property by calling UpdateTarget on the IsVisible binding expression.  However, it seems that no matter when I call

 

Dim exp As BindingExpression = column.GetBindingExpression(Telerik.Windows.Controls.GridViewDataColumn.IsVisibleProperty)


I always get null for the value of exp.  When is it safe to call GetBindingExpression or is there another way to refresh the binding.

Thanks,

Patrick
Top achievements
Rank 1
 asked on 13 Sep 2012
2 answers
149 views
Hello,

I"m having some troubles. I'm using this VirtualQueriableCollectionView with a RadCarousel. It's working well up until i change the VirtualItemCount in the ItemsLoading event. 

little more information:
We're using this VirtualQueriableCollectionView to load only a portion of the entire file. that part is working great.
On this control we have a TextBox that we use to search each column. unfortunately we're not using sql so we need to read each record and check the fields to see if any of them mach the TextBox text value. Doing it this way we wont know how many records we have in total so when we're finally done searching all of the records we will have a total count of records that match the textbox value and we'll need to change the VirtualItemCount in the ItemsLoading EventHandler. Now when i change the VirtualItemCount in my test wpf application it works just fine. But when i change it when it's hosted in WindowsForms (our main app is using winforms) I get "Collection was modified after the enumerator was instantiated.". 

I'm curious if you have any ideas of how i can work around this issue?

I hope that makes sense. If you need more information please let me know. I can hook you up with a test application too if needed.

Thanks Much,
~Boots
Boots
Top achievements
Rank 1
 answered on 13 Sep 2012
2 answers
205 views
Hi Team,

I have purchased the telerik licences  recently. I am using  RadBooK control for showing PDF file as needed the functionality  to change the pages horizontally(Swipe functionality).
But my requirement is also to have Zoom in/out and Panning feature by touch(and multi-touch also).

Please guide me for achieving this functionality. It will be great if you can also provide Code snippets or relevant links.

Thanks,
Mandeep Kaur. 
Darryn
Top achievements
Rank 1
 answered on 13 Sep 2012
1 answer
177 views
We have a gridview.ItemSource = datafilter.FilterdSource and the datafilter.Source = datatable.DefaultView. When we (manually) generate the columns they are type of GridViewColumnBase and the columns to be updated are of DataType System.String. The gridview is set to readonly and we set some values in the background depending on user actions. Generally the action is based on a context menu click and we are accessing the record as (gridview.Items[i] as DataRowView). We then set the value of the cell by the column name and it works great but sometimes it will give us an exception saying the column 'x' is readonly... can't figure our why.

Routine to update is similar to the following:
string c = "ColumnUniqueName", v = "ValueToSet";
DataRowView r = (gridview.Items[i] as DataRowView);
r[c] = v; //her we get the error

Error:
Message: Column 'ColumnUniqueName' is read only.

Source: System.Data

Trace:    at System.Data.DataRow.set_Item(DataColumn column, Object value)
   at System.Data.DataRowView.SetColumnValue(DataColumn column, Object value)
   at System.Data.DataRowView.set_Item(String property, Object value)


Guru
Top achievements
Rank 2
 answered on 13 Sep 2012
6 answers
564 views
I want to be able to disable default commands on the RadRichTextBox (for example the SaveCommand command), and have their corresponding shortcut keys bubble up the visual tree (so the SaveCommand command's Ctrl+S shortcut can be captured at the Window level).  I've tried two methods of disabling a command:

#1 - Disabling the command

rtb.Commands.SaveCommand.Enabled = false;


#2 - Handling the CommandExecuting event and cancelling the command

void RadRichTextBoxEx_CommandExecuting(object sender, CommandExecutingEventArgs e)
{
    if (e.Command is SaveCommand)
        e.Cancel = true;
}


Unfortunately these methods seem to still mark the event as handled, and the KeyDown event never gets raised up the visual tree.  It seems this is a bug - is there a workaround or fix for it?

Thanks

Chris Anderson
Itamar
Top achievements
Rank 1
 answered on 13 Sep 2012
6 answers
580 views
I have a RadGridView in which I need a column of checkboxes.  My problem?  I need a checkbox in the header that will cause all the checkboxes in the column to be selected - and I need that checkbox and its text to match the style of the other headers, regardless of what theme might be selected.

From this thread I'd thought that this would work:

<telerik:GridViewDataColumn
        IsReadOnly="True"
        >
    <telerik:GridViewDataColumn.Header>
        <CheckBox
                                        telerik:StyleManager.Theme="Metro"
                    x:Name="deleteFoo"
                    >
            Delete?
        </CheckBox>
    </telerik:GridViewDataColumn.Header>
    <telerik:GridViewDataColumn.CellTemplate>
        <DataTemplate>
            <CheckBox
                    IsChecked="{Binding Path=isFoo,Mode=TwoWay}"
                    />
        </DataTemplate>
    </telerik:GridViewDataColumn.CellTemplate>
</telerik:GridViewDataColumn>

It doesn't.  In the Metro theme, header text is drawn in grey. My Delete? header text is drawn in black.

What I don't want is to apply a specific foreground color so that it matches Metro. Because if the theme were to be changed, it'd not match.  (I also don't want to apply a hard-coded theme name, but I was hoping that I could bind to a variable that'd be set by my theme initializing code, but there's no point in worrying about that, when the literal string doesn't).

Just on the off chance, I've tried to set the theme in the code-behind:

StyleManager.SetTheme(this.deleteFoo, new MetroTheme());

And I've tried to set the theme from the parent:
StyleManager.SetThemeFromParent(this.deleteFoo, this);

None if it has worked.  The CheckBox always draws black, regardless of the theme I've tried to attach to it.
Jeff
Top achievements
Rank 1
 answered on 13 Sep 2012
0 answers
135 views
Hi,

Validation in case of heritance:

  public class Lookup : ValidationBase
    {
        [Required(ErrorMessage = "Das Feld 'Name' muss gefüllt sein.")]
        public string Name
        {
            get { return this._name; }
            set
            {
                this._name = value;
            }
        }
 
public class Child : Lookup
    {
     ...
      }

I want to disable Validation of child object in Dataform:
- Only Property Name
- All Properties

is it posible to disable Validation? why there is no ValidatesOnDataErrors="None" property like by gridview?

is it also posible to disable validation on DataField?

Thanks!
Dmitrijs
Top achievements
Rank 1
 asked on 13 Sep 2012
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
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
PasswordBox
SplashScreen
Callout
Rating
Accessibility
CollectionNavigator
Localization
AutoSuggestBox
Security
VirtualKeyboard
HighlightTextBlock
TouchManager
StepProgressBar
Badge
OfficeNavigationBar
ExpressionParser
CircularProgressBar
SvgImage
PipsPager
SlideView
AI Coding Assistant
+? more
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
yw
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
yw
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?