Telerik Forums
UI for Blazor Forum
1 answer
124 views
Our site is building our filter in the following way:


 <TelerikFilter @ref="@FilterControl" Value="@Value" ValueChanged="@OnValueChanged">
            <FilterFields >
                @foreach (SearchFieldConfiguration searchField in SearchFields)
                {                  
                      <FilterField Name="@nameof(@searchField.DisplayName)" Type="@(Type.GetType(@searchField.Type))" Label="@searchField.DisplayName" />                    
                }
            </FilterFields>

</TelerikFilter>

We want to be able to configure our Search Fields in the database and serialize the DataSourceRequest to handle searching in a separate API.
SearchField.Type is a string, examples being "System.Double", "System.String", so that System.Type.GetType(searchField.Type) returns the type we desire. 

The filter gets built correctly with the search fields in the FilterField field dropdown, but the operations are always string operations (I think the first type in this list is a string). If I select a field that is of type System.Int32 or System.Double, the string operations (contains, etc) remain. Am I missing some refresh action I have to implement?
Bill
Top achievements
Rank 1
Iron
Iron
 answered on 25 May 2023
3 answers
568 views

This is driving me nuts.

I have tried the .clear() and I have tried re-init the object. Nothing seems to clear this from the UI that the user sees.

on the razor page:

<TelerikMultiSelect @ref="DDLFil1"
                                    Class="my-multiselect"
                                    Data="@DDLFil1List"
                                    TextField="Result"
                                    TItem="DDLList"
                                    ValueField="Result"
                                        TValue="string"

                                    Placeholder="Select the items you need"  
                                    AutoClose="false"
                                    Filterable="true"
                                    ClearButton="true"
                                    >
                    <MultiSelectSettings>
                        <MultiSelectPopupSettings Height="500px" />
                    </MultiSelectSettings>  
                    <HeaderTemplate>
                        <label style="padding: 4px 8px;">
                                <TelerikCheckBox TValue="bool" Value="@DDLFil1_IsAllSelected()" ValueChanged="@( (bool v) => DDLFil1_ToggleSelectAll(v) )"></TelerikCheckBox>
                            &nbsp;Select All
                        </label>
                    </HeaderTemplate>
                </TelerikMultiSelect>

 

In the CS behind the code page:

 public TelerikMultiSelect<DDLList, string> DDLFil1 { get; set; }  // Ctrl on the webpage
        private bool blnHideDDLFil1 { get; set; } = true;
        string DDLFil1Lbl = "";
        List<DDLList> DDLFil1List = new List<DDLList>();
        string? _DDLFil1SelectedId;
        string DDLFil1SelectedId
        {
            get
            {
                return _DDLFil1SelectedId;
            }
            set
            {
                _DDLFil1SelectedId = value;
            }
        }
        List<string> DDLFil1Values { get; set; } = new List<string>();
        List<string> DDLFil1Results { get; set; } = new List<string>();

 

Clearing code:

if (DDLFil1.Value != null)
                {
                    if (DDLFil1.Value.Count() > 0)
                    {  // Items have been selected!
                        DDLFil1.Value.Clear();
                    };               

                };

How does one Clear the selected items for the user to re-use without having them to unselect each item.

You have a ClearSelectAll Button on the Control. sometimes hard for the user to see it with multiple items selected.

Would be nice if i could call that in code!!!

DDLFil1.ClearSelectedAll();

I really need this feature.

Thanks

 

Deasun
Top achievements
Rank 3
Bronze
Bronze
Bronze
 answered on 25 May 2023
1 answer
859 views

I have a DatePicker and a DateInput bound to the same nullable DateTime property (for behavior testing purposes).

<TelerikDateInput @bind-Value="@TestDate" />
<TelerikDatePicker @bind-Value="@TestDate" />

public DateTime? TestDate { get; set; } = null;

As it isn't a required field, the user can fill in the field and delete it afterwards (by selecting the full date and pressing the "Del" key). When this happens, the DateInput, in terms of layout behaves as if it has never been filled. On the other hand, the DatePicker shows a red border as if it was a required field that has yet to be filled in.

Is there any way to not show the red border when the DatePicker is cleared?

Svetoslav Dimitrov
Telerik team
 answered on 25 May 2023
1 answer
85 views

Hi, I am currently evaluating the Telerik Grid and I need to have, in my grid, a command column that stays sticked to the right of the grid no matter the width of the other elements. Note that I also allow resize of all columns (except the command column itself).

In other words, I would like for the white space in the attached picture to move from after the command column to between the rating and command columns.

Is that at all possible? Thanks.

Tsvetomir
Telerik team
 answered on 24 May 2023
1 answer
139 views

Hi,

Within the Grid I use a custom filter row as it is shown at https://demos.telerik.com/blazor-ui/grid/custom-filter-row

Is there any way to filter a numeric column for lines with or without a value given? Normally this is available for string types.

 

Best regards,

Rayko

Stamo Gochev
Telerik team
 answered on 24 May 2023
0 answers
118 views
In the TimePicker, once the control is activated, Is there a way to show leading zeros in the hour and minute dropdowns/columns?
Walter
Top achievements
Rank 1
 asked on 19 May 2023
1 answer
302 views

Hi,

I'm trying to create EditForm with child components inside it.

Child component has two drop down lists, that after selection should return single value.
You can see attached Component.razor and razor.cs with the code.

However, my EditForm throws me error regarding ValueExpression.

If I understand right, I can reference it to specific model property, but I have 2 dropdown menus and I dont hold value for any of them in my object? So how I should use it?

I'm currently trying to use it like this:

<Customs.UI.Shipments.Components.Common.LocodeComponent DateRequired="true" Title="Collection" Export="@(Shipment.Export)" @bind-CityId="Shipment.CollectionCityId" />

 

Last screenshot of it working absolutely fine outside EditForm..

 

Any help or guidance would be so much appreciated!

 

 

Svetoslav Dimitrov
Telerik team
 answered on 18 May 2023
1 answer
230 views

https://docs.telerik.com/blazor-ui/components/filemanager/events#read-event

The documentation says the event can be used "for example, to retrieve only a small number of items to improve the backend performance." This is exactly the scenario I have with many files and folders. However, the event only seems to fire one time when the control is initialized.

What is the purpose of this event, since data can be read programmatically with the OnInitializedAsync or OnModelInit events?

Is there any way to set the data to the current path's folders/files and use the read event when the user navigates (up or down) to a new folder?

Thanks

Nadezhda Tacheva
Telerik team
 answered on 18 May 2023
1 answer
141 views
Need Multi selection control functionality in combo look means i need to put arrow icon with multi select telerik control and on click of that icon will appear the list box for selection as like in combo/dropdown control
Nadezhda Tacheva
Telerik team
 answered on 18 May 2023
1 answer
189 views

I love the GridLayout-Component. I use it a lot.

I mostly set the Grid Parameter "VerticalAlign" to Center. But that is for all the Cells in the Grid.

But sometimes I want to set the Alignment of just one Cell to e.g. "Top".

How is that possible ? It would be a great feature having this Property for each GridItem...

Dimo
Telerik team
 answered on 17 May 2023
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?