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

I have a combobox in my application that has this binding on the SelectedItem

SelectedItem="{Binding Path=Food, Mode=OneWayToSource}">

The back end property is define as follows

public Food Food
{
  get { return _food; }
  set { _food = value; }
}

My problem is that the above binding will try to get the property, this is not the expected behavior for this type of binding.
Can you suggest a work around you come up with fix ?

Thank you,
Valeri Hristov
Telerik team
 answered on 26 Jul 2010
5 answers
248 views
Do you plan on publishing something like this that you did for WinForms?  Or at least release all of the code used in the demos?  I see others are asking the same thing too.

Thanks!
Kaloyan
Telerik team
 answered on 26 Jul 2010
1 answer
99 views

Hi,

Version : 2010 Q2 - 2010.2.714.35

Hi,

I have a WPF application (.net 3.5) with MVP pattern and the Microsoft Unity container.
When i add a RadDatePicker in a view, there is a drop down problem :
the calendar doesn't appear and other controls have a similar behavior : for the original ComboBox, the drop down list don't display.
Without RadDatePicker, all controls appear correctly.
(With the version 2010.1.422.35, it work.)

I don't have this problem in a classic WPF application (without MVP neither Unity).

Otherwise, in the Visual Studio out, an error occurs many time  :

System.Windows.Data Error: 4 : Cannot find source for binding with reference 'ElementName=PART_DropDownButton'. BindingExpression:Path=IsMouseOver; DataItem=null; target element is 'ButtonChrome' (Name='ButtonChrome'); target property is 'RenderMouseOver' (type 'Boolean')

I try to catch this error with a diagnostic converter (System.Diagnostics) :
<Style TargetType="{x:Type telerik:RadDatePicker}">
 <Setter Property="???" Value="{Binding Path=???, RelativeSource={RelativeSource AncestorType={x:Type ItemsControl}}, diagnostics:PresentationTraceSources.TraceLevel=High}"/>
</Style>

But i don't found interesting property to watch in order to have more details.

Thanks in advance

Kaloyan
Telerik team
 answered on 26 Jul 2010
2 answers
158 views
Having a little problem when I try to apply a control template to the rad carousel, in that as soon as I put in the binding to the template, the carousel no longer displays any items.

Here is the code for the carousel:
<Border
    ClipToBounds="True"
    Grid.Column="1"
    Grid.RowSpan="4"
    Grid.ColumnSpan="2"
    Grid.Row="0"
    VerticalAlignment="Top"
    Margin="0,40,10,0"
    HorizontalAlignment="Right"
    x:Name="carFav"
    Height="70px"
    Width="500px"
    Visibility="Collapsed">
    <telerik:RadCarousel
            x:Name="Favorites"
            AutoGenerateDataPresenters="False"
            HorizontalScrollBarVisibility="Hidden"
            VerticalContentAlignment="Bottom"
            Template="{StaticResource FavouritesCarousel}">
        <telerik:RadCarousel.Background>
            <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                <GradientStop Color="#FF7D7D7D" Offset="0.164"/>
                <GradientStop Color="White" Offset="0.093"/>
            </LinearGradientBrush>
        </telerik:RadCarousel.Background>
        <telerik:RadCarousel.ReflectionSettings>
            <telerik:ReflectionSettings Visibility="Visible" OffsetY="3"/>
        </telerik:RadCarousel.ReflectionSettings>
    </telerik:RadCarousel>
</Border>

And the control template code:
<ControlTemplate x:Key="FavouritesCarousel" TargetType="{x:Type telerik2:RadCarousel}">
    <Grid>
        <ScrollViewer
            x:Name="CarouselContentPresenter"
            CanContentScroll="True"
            HorizontalAlignment="Stretch"
            VerticalAlignment="Stretch"
            Background="Gray"
            HorizontalScrollBarVisibility="{Binding RelativeSource={RelativeSource Mode=FindAncestor, AncestorType={x:Type telerik2:RadCarousel}}, Path=HorizontalScrollBarVisibility}"
            VerticalScrollBarVisibility="{Binding RelativeSource={RelativeSource Mode=FindAncestor, AncestorType={x:Type telerik2:RadCarousel}}, Path=VerticalScrollBarVisibility}">
            <ItemsPresenter
                x:Name="ItemsPresenter"
                HorizontalAlignment="Stretch"
                VerticalAlignment="Stretch"/>
        </ScrollViewer>
    </Grid>
</ControlTemplate>


Any suggestions? Thanks.
James Ludlow
Top achievements
Rank 1
 answered on 26 Jul 2010
8 answers
196 views
Hello,
What event occures when we expand the row in hierarchical gridview?
Jokerwolf
Top achievements
Rank 1
 answered on 26 Jul 2010
3 answers
85 views
Hi,

I had a quick look in the PITS but didn't notice if this issue is in there.

There seems to be an issue with floating panes and using the Windows 7 Windows Key shortcuts.

Using WindowsKey + Down Arrow, will minimise the the floating window to somewhere and also and subsequent attempts to make any other panes floating fail. Dragging a window out of the tabbed documents also immediatly makes the about to be floating window disappear.

Using WindowsKey + Right (with two monitors) will send the floating window to the right of the secondary monitor, and will only allow it to be dragged within half of the screen width on that monitor, ie, it is given half the screen width and that is all. To move it back out, WindowsKey + Left can be used.

Thanks,

Adam
Konstantina
Telerik team
 answered on 26 Jul 2010
1 answer
161 views
Hi,
Could any one guide me how can I edit the column footer style from Expression blend.. Actually want a single strip for agreegates, not different cells against each column. I can edit the group footer style but column footer style is note availble. For refernence, I am attaching a screen shot. THANKS
Vanya Pavlova
Telerik team
 answered on 26 Jul 2010
1 answer
158 views
Hello :)

This is my scenario:

I have a gridview with a GridViewComboBoxColumn with the property isComboBoxEditable set to true and the ItemsSource property set to a List<T> (the data of this list is populated from a data base). The SelectedValueMemberPath set to a property of the T object and the DisplayMemberPath set to an another property of T. Everything works as expected. 

I would like to know how can I do the following if possible:
The reason for the isComboBoxEditable is set to true is that I want the user to add new items to the GridViewComboBoxColumn, then I save this new item to the data base and then display the combobox with the new item. So how can I access the combobox and add the new item and then display the combobox list with the new item? I guess refreshing the combobox, refreshing the row, or refreshing the entire gridview could help because all the combobox in the rows created previously must have the new created item too.

I hope you can help me.

Best regards,
Jorge Alberto
Ahmet Özgür
Top achievements
Rank 1
 answered on 26 Jul 2010
4 answers
80 views
Hi,

I upgraded to the Q2 release for WPF and I'm now getting intermittent NullReferenceExceptions coming from the following exception below.

This seems to be due to the fact that CoverRectangle is backed by a WeakReference.

What seems to be happening is CoverRectangle is being GCed during the drag operation.  This may be due to the fact that in .NET 4 the GC is much more aggressive.

Thanks,

Kavan

Stack Trace

-----------

1) Type: NullReferenceException (System.NullReferenceException)

1) Message: Object reference not set to an instance of an object.

1) Data: YES (1 Entries Below)

1) Key: 'System.Object' Value: ''

1) ** Stack Trace:

1) at Telerik.Windows.Controls.DragDrop.RadDragAndDropManager.PositionArrow() in c:\Builds\WPF_Scrum\Release_WPF_2010_Q2\Sources\Development\Core\Controls\DragDrop\RadDragAndDropManager.cs:line 1573

1) at Telerik.Windows.Controls.DragDrop.RadDragAndDropManager.OnRealDrag(IMouseEventArgs e) in c:\Builds\WPF_Scrum\Release_WPF_2010_Q2\Sources\Development\Core\Controls\DragDrop\RadDragAndDropManager.cs:line 1318

1) at Telerik.Windows.Controls.DragDrop.RadDragAndDropManager.OnCoverRectangleMouseMove(Object sender, MouseEventArgs e) in c:\Builds\WPF_Scrum\Release_WPF_2010_Q2\Sources\Development\Core\Controls\DragDrop\RadDragAndDropManager.cs:line 856

1) at System.Windows.Input.MouseEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)

1) at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)

1) at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)

1) at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)

1) at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)

1) at System.Windows.UIElement.RaiseTrustedEvent(RoutedEventArgs args)

1) at System.Windows.UIElement.RaiseEvent(RoutedEventArgs args, Boolean trusted)

1) at System.Windows.Input.InputManager.ProcessStagingArea()

1) at System.Windows.Input.InputManager.ProcessInput(InputEventArgs input)

1) at System.Windows.Input.InputProviderSite.ReportInput(InputReport inputReport)

1) at System.Windows.Interop.HwndMouseInputProvider.ReportInput(IntPtr hwnd, InputMode mode, Int32 timestamp, RawMouseActions actions, Int32 x, Int32 y, Int32 wheel)

1) at System.Windows.Interop.HwndMouseInputProvider.FilterMessage(IntPtr hwnd, WindowMessage msg, IntPtr wParam, IntPtr lParam, Boolean& handled)

1) at System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)

1) at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)

1) at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)

1) at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)

1) at MS.Internal.Threading.ExceptionFilterHelper.TryCatchWhen(Object source, Delegate method, Object args, Int32 numArgs, Delegate catchHandler)

1) ** No Inner Exception

Shawn
Top achievements
Rank 1
 answered on 25 Jul 2010
6 answers
463 views
Hi..
When I do the following I get a stackoverflow error... What am I doing wrong? How do I set the selected item in the grid to the first row.. when 'loaded'..... thanks again



 

this.grid.IsBusy = true;

 

Load_Invoices();  // Sets ItemsSource

 

 

this.grid.IsBusy = false;

// Blows up Here!

 

 

this.grid.SelectedItem = this.grid.Items[0];

 

Jon
Top achievements
Rank 1
 answered on 25 Jul 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?