Telerik Forums
UI for WPF Forum
3 answers
191 views
hello,

I need to dynamically mark on a map a few locations in the described way:
1. each location should be marked by a circle 
2. the center of the circle should be the location (latitude and longtitude)
3. and the radius of the circle needs to be 4KM (4000 meters) 

so when the user changes zoom level
the center of the circle should stay on the same exact location
and the radius should change according to the zoom level to reflect a 4KM at all times

i would also like the circles to be drawn dynamically, via code (not static file)  
and also fade out after, lets say, 15 seconds

is that possible?
should i use mapshape? or hotspots?
should i use information layer or dynamic layer
i am very confused with all the options
can you please make an example like that?

i need to know if radmap supports such a scenario
and can manage that

thank you very much
i realy hope this can be done..

Pavel R. Pavlov
Telerik team
 answered on 12 Feb 2015
1 answer
228 views
Dear Telerik,

I have a Master-Details window where the Master list is a ListView, and the SelectedItem of this ListView binded to a "SelectedObject" property in my ViewModel. 

The Details view should be a RadPropertyGrid, so the RadPropertyGrid's DataItem binded to this "SelectedObject" property as well.
This works fine, however it's very slow to change the selected Item. After I logged the runtime binding errors and warnings, I found that there are lots of "Cannot retrieve value using the binding and no valid fallback value exists; using default instead. BindingExpression:Path=FieldIndicatorVisibility" warnings in the logs.

It seems that the DataItem is null for some reason, however the PropertyGrid shows the properties perfectly. I'm not sure, maybe the PropertyGrid tries to get the "SelectedObject" when it's null, but it is never null, I tried many things to fix the issue, but still nothing. The SelectedObject is not a big ViewModel and the ViewModel implmenets the INotifyPropertyChange.

Let me show you high scope exampe:

View:

<!--The master list in the View (The Objects property is an ObservableCollection<MyObject>, the SelectedObject is a MyObject, both implement INotifyPropertyChanged)-->
<ListView ItemsSource="{Binding Objects}" SelectedItem="{Binding SelectedObject, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" ... />

<!-- The details PropertyGrid. The Item binded to the same SelectedObject property. The SelectedObject is never null, but the DataItem is null sometimes -->
<telerik:RadPropertyGrid Item="{Binding SelectedObject, UpdateSourceTrigger=PropertyChanged}" AutoGeneratePropertyDefinitions="False">
      <telerik:RadPropertyGrid.PropertyDefinitions>

            <!-- Most of the properties have custom EditorTemplate, mostly NumericUpDown controls but not all of them, but it does not related to my problem -->
            <telerik:PropertyDefinition Binding="{BindingMyProperty1}" DisplayName="..." Description="... >
                  <telerik:PropertyDefinition.EditorTemplate>
                        <DataTemplate DataType="view:MyObject">
                              <telerik:RadNumericUpDown Value="{Binding MyProperty1, Mode=TwoWay}" />
                        </DataTemplate>
                  </telerik:PropertyDefinition.EditorTemplate>
            </telerik:PropertyDefinition>

            <!-- Another property ans so on... There are 20 properties in the PropertyDefinitions -->
            <telerik:PropertyDefinition Binding="{BindingMyProperty2}" DisplayName="..." Description="... >
                  <telerik:PropertyDefinition.EditorTemplate>
                        <DataTemplate DataType="view:MyObject">
                              <telerik:RadNumericUpDown Value="{Binding MyProperty2, Mode=TwoWay}" />
                        </DataTemplate>
                  </telerik:PropertyDefinition.EditorTemplate>
            </telerik:PropertyDefinition>

      </telerik:RadPropertyGrid.PropertyDefinitions>
</telerik:RadPropertyGrid>


ViewModel:

public class ExampleViewModel : BaseViewModelWithNotifyPropertyChanged
{

      // The the SelectedItem of the List and Item of the PropertyGrid. Never null
      private MyObject _selectedObject;
      public MyObject SelectedObject
      {
            get { return_selectedObject; }
            set { SetProperty(ref_selectedObject, value); }
      }

      // The ItemsSource of the ListView. Always fileld with not null MyObjects
      private ObservableCollection<MyObject> _objects;
      public ObservableCollection<MyObject> Objects
      {
            get { return _objects; }
            set { SetProperty(ref _objects, value); }
      }

}

With this settings, I've got many-many errors. Most of the errors refers the FieldIndicatorVisibility property, not sure why:

- System.Windows.Data Information: 10 : Cannot retrieve value using the binding and no valid fallback value exists; using default instead. BindingExpression:Path=FieldIndicatorVisibility; DataItem=null; target element is 'Grid' (Name=''); target property is 'Visibility' (type 'Visibility')

The common problem is that the DataItem=null. As far as I can see, the DataItem should be a MyObject instace (the same as the SelectedObject property in the ViewModel). Also interesting that the view is working, so its like the PropertyGrid didn't find the DataItem and retry to get the DataItem, and at least the ProeprtyGrid founds the DataItem. It's slow.

It is mission critical to resolve this issue, would you please help me?

Thanks in advance,
Daniel
























Boris
Telerik team
 answered on 11 Feb 2015
1 answer
157 views
Hello,
Currently, the following languages are supported for the built-in localization mechanism in WPF:
English, German, Spanish, French, Italian, Dutch, Turkish

Are there any plans to support additional languages?

Regards,
Martin
Dimitrina
Telerik team
 answered on 11 Feb 2015
1 answer
199 views
Hi all,

Im using a RadGridView to display Data at 3 levels like so:

                <telerik:RadGridView>
                    <telerik:RadGridView.ChildTableDefinitions>
                        <telerik:GridViewTableDefinition />
                    </telerik:RadGridView.ChildTableDefinitions>
                    <telerik:RadGridView.HierarchyChildTemplate>
                        <DataTemplate>
                            <telerik:RadGridView>
                                <telerik:RadGridView.ChildTableDefinitions>
                                    <telerik:GridViewTableDefinition />
                                </telerik:RadGridView.ChildTableDefinitions>
                                  <telerik:RadGridView.HierarchyChildTemplate>
                                    <DataTemplate>
                                        <telerik:RadGridView>


What I need to do now, in code, is the following. I know a value for all of the 3 depth levels, which means expand at level 1, expand at level 2, select and scroll intoView on level 3. Unfortunately I don't know how to get the child grids in code, so that all I've achieved so far is scroll and expand at level 1.

TIA
Boris
Telerik team
 answered on 11 Feb 2015
2 answers
123 views
When using series.RenderOptions = new BitmapRenderOptions(); the drawn series line will ignore the StrokeThickness property and always use 1px thickness. I'm using StepLineSeries series. 



How can I set the thickness of my StepLineSeries objects when using bitmap rendering?
Martin Ivanov
Telerik team
 answered on 11 Feb 2015
1 answer
103 views
Hi There

I'm calling WPF RadMap usercontrol inside Window form usercontrol using elementHost. But while calling using UI Virtualization it gives error as shown below.The below code work fine in standalone WPF usercontrol.



Later I found that this is threading issue related to STA architecture, as it also throw the error "The calling thread must be STA,because many UI components require this". See the attachment.

Cheers.
 
Petar Mladenov
Telerik team
 answered on 11 Feb 2015
1 answer
137 views
Hi There

I'm calling WPF RadMap usercontrol inside Window form usercontrol using elementHost. But while calling using UI Virtualization it gives error as shown below.The below code works fine in standalone WPF usercontrol.

MapShapeDataVirtualizationSource map = new MapShapeDataVirtualizationSource();
               AsyncShapeFileReader reader = new AsyncShapeFileReader();
               reader.ToolTipFormat = "FieldName";
               reader.Source = new Uri(rShape["path"].ToString() + ".shp", UriKind.RelativeOrAbsolute);
               reader.DataSource = new Uri(rShape["path"].ToString() + ".dbf", UriKind.RelativeOrAbsolute);
               map.Reader = reader;
               map.ReadAsync(); // Give the error .See the attached Error screen shot.
               map.ClearCache = false;
               vLayer.VirtualizationSource = map;
               vLayer.UseBitmapCache = false;
               vLayer.RefreshVirtualSource();
               this.radMapNaveo.Items.Add(vLayer);

The below code works.
AsyncShapeFileReader reader = new AsyncShapeFileReader();
               reader.ToolTipFormat = "FieldName";
               reader.Source = new Uri(rShape["path"].ToString() + ".shp", UriKind.RelativeOrAbsolute);
               reader.DataSource = new Uri(rShape["path"].ToString() + ".dbf", UriKind.RelativeOrAbsolute);                    
               vLayer.Reader = reader;
               vLayer.UseBitmapCache = false;
               vLayer.RefreshVirtualSource();
               this.radMapNaveo.Items.Add(vLayer);

 
Later I found that this is threading issue related to STA architecture, as it also throw the error "The calling thread must be STA,because many UI components require this". See the attachment.

Cheers. 
Petar Mladenov
Telerik team
 answered on 11 Feb 2015
6 answers
210 views
Hello,

I'm currently trying to simulate a step line series by using two values for one state. Basically my first attempt looks like this: https://dl.dropboxusercontent.com/u/55589036/Pictures/Screenshots/20150108152425.png

In two states my value is exactly 0 of the item in the data source of the line series and this will result in not being shown. In my opinion as long as the values are not negative the line between them should be printed.

How can I get this done?
Martin
Top achievements
Rank 1
 answered on 11 Feb 2015
1 answer
49 views
Hello, I am using a ChartView to plot values of a list. The "Category" of my list is simply a number sequence and it can be large (0 , 1000) for example.

If i use :
         <telerik:RadCartesianChart.HorizontalAxis>
            <telerik:CategoricalAxis LabelStyle="{StaticResource axisLabelStyle}" />
         </telerik:RadCartesianChart.HorizontalAxis>

I cannot change the Step, so it is very hard to read.  What do you recommend i use, since my Category is just numbers.

thanks

Kevin


Peshito
Telerik team
 answered on 11 Feb 2015
1 answer
109 views
Hello

It it possible to skip copying header cell content for particular column? For cells content I can use CopyingCellClipboardContent event. Is there any event for header cells?

I found in example CopyPasteFunctionality case where for Copied event there are made some modifications. So for my case I can use this approach but I am looking for some simpler.
Maya
Telerik team
 answered on 11 Feb 2015
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
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?