Telerik Forums
UI for WPF Forum
3 answers
289 views

How to create a Rad Diagram canvas with fixed height and width and get only the positive quadrant (x,y) in the view port?

The issue is when I add shapes to the canvas it can be dragged to any quadrant of the canvas, which I want to restrict.

In any case the shapes should not go outside the positive x,y coordinates. I could not find any setting or implementation related to this any samples.

Dinko | Tech Support Engineer
Telerik team
 answered on 06 Apr 2020
4 answers
861 views

We currently having issues using the RadMultiColumnComboBox when we change property on the view model which we are binding to.  

1.  We have multiple items with properties and one property is connected to the ComboBox.

2. We select one item in the view and the connected property is displayed in the ComboBox correctly.

3. We select a different item with the same value in the connected property, but the ComboBox does not display any text (null text).

4. Selecting another item with different value in the connected property results in displaying text again in the ComboBox.

 

For example items could be employees with a display name (DisplayName) property. We have a list of employees populated as item source provider. 

The DisplayMemberPath in the ComboBox is set to the DisplayName property.

The SelectedItem property is set to the employee. We also have three more ComboBoxes on the same page that behave correctly (just binding to different properties) and cause no issue.

 

Any idea what could go wrong?

 

Regards, Martin

Martin
Top achievements
Rank 1
 answered on 06 Apr 2020
3 answers
121 views
I would like to always freeze the first physical row and column whenever a sheet is selected. However the Freeze Panes method always indexes into whichever rows and columns are currently in the viewport, which might be anywhere on the sheet. How can I get the viewport to scroll to first physical row and column on sheet change?
Dimitar
Telerik team
 answered on 06 Apr 2020
5 answers
139 views
Hello,

I'm using a RadScheduleView in my project, and it works fine most of the time. But I have had two cases where I get a System.ArgumentException right at the begining when I load my app, whitout being able to do anything about it.

some details :

my app opens at first on a screen containing a radScheduleView.
the radScheduleView is mannulay set to the user's preference (what views he wants, what dayStartTime / dayEndTime, FirstDayOfWeek etc...) in code behind

so what I do is I clear the ViewDefinitionsCollection and then add exactly the views I want, depending on those settings.

here is the function that adds the ViewDefinitions :

/// <summary>
/// Adds a new ViewDefinition in the Collection
/// </summary>
/// <param name="viewDefinitionId">id of the view</param>
/// <param name="viewDefinitionName">display text for the view (localized)</param>
private void AddViewDefinition(int viewDefinitionId, string viewDefinitionName)
{
    ViewDefinitionBase viewDefinition = null;
    int activeViewDefinitionIndex = ScheduleView.ActiveViewDefinitionIndex;
 
    switch (viewDefinitionId)
    {
        case 0: ScheduleView.ViewDefinitions.Add(viewDefinition = new DayViewDefinition { Title = viewDefinitionName, TimerulerMajorTickStringFormat = "{0:t}     " }); break;
        case 1: ScheduleView.ViewDefinitions.Add(viewDefinition = new WeekViewDefinition { Title = viewDefinitionName, TimerulerMajorTickStringFormat = "{0:t}     " }); break;
        case 2: ScheduleView.ViewDefinitions.Add(viewDefinition = new WeekViewDefinition
                    {
                        Title = viewDefinitionName,
                        TimerulerMajorTickStringFormat = "{0:t}     ",
                        GroupFilter = obj =>
                        {
                            if (obj is DateTime)
                            {
                                var day = ((DateTime)obj).DayOfWeek.GetRecurrenceDay();
                                return (day & WorkingDays) == day;
                            }
                            return true;
                        }
                    }); break;
        case 3: ScheduleView.ViewDefinitions.Add(viewDefinition = new MonthViewDefinition { Title = viewDefinitionName }); break;
    }
 
    if (viewDefinition == null) return;
 
    viewDefinition.SetValue(IdProperty, viewDefinitionId);
    viewDefinition.SetValue(DayViewDefinition.EnableSmallAppointmentRenderingProperty, true);
 
    ScheduleView.ActiveViewDefinitionIndex = activeViewDefinitionIndex;
}

and the Issue I have seems to lies within this function (see attached screenshot for details on the exception)

do you have any idea what is happening here? (I don't)


as far as I can tell, this code should work fine to add new ViewDefinitions to the collection, but for whatever reason I get this Exception. I could catch it and move on but then again, I'd rather know what goes wrong than try to ignore it.

thanks
Martin Ivanov
Telerik team
 answered on 03 Apr 2020
1 answer
580 views

I have tried to migrate one project in a big solution to the new csproj SDK style

But I get this error
Error    MC1000    Unknown build error, 'Cannot resolve dependency to assembly 'Telerik.OpenAccess, Version=2013.2.702.1, Culture=neutral, PublicKeyToken=7ce17eeaf1d59342' because it has not been preloaded. When using the ReflectionOnly APIs, dependent assemblies must be pre-loaded or loaded on demand through the ReflectionOnlyAssemblyResolve event.'     Reports    C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\Microsoft.WinFx.targets

To avoid having nuget packages inside our git repository we have all the telerik packages on our own private nuget server

<PackageReference Include="Seges.Dms.Telerik" Version="1.0.2" />

<PackageReference Include="Seges.Dms.Telerik.Reporting" Version="1.1.0" />

And it seems that in the old style all the telerik packages inside our Seges.Dms.Telerik package are added individually, but when I look now in "Manage nuget packages" they both have the same.

One "funny" note is that on my machine in the Repository where I changed the code it builds, but if I do a new clone and build again I get the error and so do TeamCity and a fellew programmer

Also when looking at https://www.telerik.com/forums/could-not-load-assembly-telerik-openaccess it sounds like people have installed OpenAccess SDK, but this have never been installed on our Teamcity server or my machine, so didnt find any help in this

 

Old csproj https://paste.ofcode.org/RBMWb74Mh75PNLAEkkAiE9

New csproj https://paste.ofcode.org/udNjMVcJLTQRJhGM4uSSEw

Martin Ivanov
Telerik team
 answered on 03 Apr 2020
1 answer
165 views
Is there a way to programmatically ensure columns in a worksheet have widths set for their widest cell?
Dimitar
Telerik team
 answered on 03 Apr 2020
1 answer
150 views

I was wondering how the Treeview actually extracts the icons from the icon file?  Probably me geeting too old LOL!!.  Is it using pixel positions?

 

What I was trying to do is modify the Treeview so that links to files are embedded correctly (i.e. one level in from the parent.).  It seemed easy to just make it a new level (that works!!).  But then I would need to use an alternate set of icons.  For example, replace the folder icon with a "- " graphic and then set the other two graphics to blanks.

 

But perhaps their is a better approach.  (see attached screenshot)

 

BTW … just in case I can convince my boss of really doing something using this … are you available for a small project?

 

 

 

Chris
Top achievements
Rank 1
 answered on 02 Apr 2020
2 answers
280 views
I'm using a RadGridView with xaml and vb. One of the columns in the grid is a textbox. This same grid is used for both creating data and for viewing it later. The user can easily enter text in the textbox and the vertical scrollbar works fine. If the user is later just viewing this gridview, the textbox is readonly. The textbox has a vertical scrollbar, but the scrollbar doesn't work. Is this expected behavior with the textbox is readonly?
Kathy
Top achievements
Rank 1
Veteran
 answered on 02 Apr 2020
3 answers
163 views

Hi,

I need to retrieve the recurrence pattern and set it to our custom object. I tried various methods. In all these cases, I am not able to retrieve DaysOfWeekMask which holds values like "Sunday" or "Monday|Tuesday|Wednesday" and cast it to our custom object DaysOfWeek which is also an enum.

1st Method

a) RecurrenceDays days = new RecurrenceDays();
days = days.AddDay(CurrentCreatedAppointment.RecurrenceRule.Pattern.DaysOfWeekMask);
var s = days.GetDaysOfWeek().Select(x => (DaysOfWeek)Enum.Parse(typeof(DaysOfWeek), x.ToString())).AsEnumerable();
viewModel.BackupArchiveSettings.ByDay = new ObservableCollection<DaysOfWeek>( s);
var k = s.GetEnumerator();

var k1 = k.Current;

 

2nd Method

 RecurrenceDays days = new RecurrenceDays();
days = days.AddDay(CurrentCreatedAppointment.RecurrenceRule.Pattern.DaysOfWeekMask);
var s = days.GetDaysOfWeek().Select(x => (DaysOfWeek)Enum.Parse(typeof(DaysOfWeek), x.ToString())).AsEnumerable();

newcol = new ObservableCollection<DaysOfWeek>();
foreach (var item in s.ToList())
{
 viewModel.BackupArchiveSettings.ByDay.Add(item);
}

 

Please help

 

Thanks,

Divya

Martin Ivanov
Telerik team
 answered on 01 Apr 2020
1 answer
98 views
Good day.

We have a problem with the RowEditEndedCommand event.

We have a GridView with GridViewCheckBoxColumn. Also there is a checkbox in the header of this column, which allows you to check/uncheck all checkboxes.

Usually everything works fine:
1. Edit the row.
2. Click to another control (for example, click on the button or select another tab).
3. The RowEditEndedCommand event was called.

But if we add an action with a checkbox in the header to the order of actions:
1. Edit the row.
2. Click on the checkbox in the grid header.
3. Click to another control.
4. The RowEditEndedCommand event was NOT called.

We need to always call this event, but we don’t know why it doesn’t work in this case.


I am attaching a small example. Use the button to change focus and get RowEditEnded event.
https://drive.google.com/file/d/1PlAq5s2uv905-wldi7jD1r8JZx28YUwO/view?usp=sharing
Dinko | Tech Support Engineer
Telerik team
 answered on 01 Apr 2020
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
Ambisoft
Top achievements
Rank 2
Iron
Pascal
Top achievements
Rank 2
Iron
Matthew
Top achievements
Rank 1
Sergii
Top achievements
Rank 1
Andrey
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Ambisoft
Top achievements
Rank 2
Iron
Pascal
Top achievements
Rank 2
Iron
Matthew
Top achievements
Rank 1
Sergii
Top achievements
Rank 1
Andrey
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?