Telerik Forums
UI for Blazor Forum
1 answer
304 views
I'm building a TelerikDropDownButton, and I'd like to base the DropDownButtonItems on data pulled from SQL. But I don't see anything in the documentation that allows for that to happen, and I've tried in-line C# in the items node, and it cases the build to break.

Is there a way to attach a data object list to the DropDownButtonItems to generate the items dynamically?
Nadezhda Tacheva
Telerik team
 answered on 25 Mar 2024
1 answer
206 views
I have a form with an edit button and a grid. The EditMode property of the grid is set to a reference variable named @GridEditModeValue which has an initial value on page load of GridEditMode.None. When I press the Edit button of the Form, in the OnClick handler I set @GridEditModeValue=GridEditMode.Incell. This allows me to click into the cells of the grid and make changes to their values, however when i click out of the cell to another part of the form or to click the Submit button of the form, the OnUpdate event doesn't seem to fire and the changes are lost. If I click into a different cell of the grid, the event does fire and the event handler is executed correctly. Is there any way to have this event fire when the cell loses focus in this case?
Dimo
Telerik team
 answered on 21 Mar 2024
1 answer
114 views
My project's Theme Builder is set up to show an alternating color for the TelerikGrid rows.  However, if I use a compact grid through Grid Sizing by setting Size="@ThemeConstants.Grid.Size.Small", the alternating row color disappears.  How can I get the alternating rows when using the Small Grid Theme?
Dimo
Telerik team
 answered on 21 Mar 2024
1 answer
255 views

Hello I have a grid which has a "Add" button which is defined in a GridBarToolBarTemplate which opens a pop up used for adding a new record displaying in the Grid.

With Blazor .Net 8 I am using Stream rendering to show the grid.

I now want to put the add button in a different component so I can use another "Interactive" rendering mode just for adding a new record

I have tried during this but it doesnt seem to work. Is this possible? and how do Iget it to work?

Thanks

Aj

 

 

Dimo
Telerik team
 answered on 21 Mar 2024
1 answer
318 views

I'm using a "hierarchical" TelerikContextMenu (example below).  I want to detect if the SHIFT key was depressed when an item (i.e., ItemA1 or ItemB2) is clicked (detecting the difference between click and SHIFT-click).

I can detect if the shift key is depressed in the @oncontextmenu event, but that is for the click invoking the context menu.  I want a similar capability when selecting an item IN the context menu.

Any suggestions?

The context menu is structured like this:

ItemA
    ItemA1
    ItemA2
ItemB
    ItemB1
    ItemB2

 

Hristian Stefanov
Telerik team
 answered on 21 Mar 2024
1 answer
520 views

I am getting this error when hosting on our application. It does not appear to happen locally.

 

We are using the new .Net 8 autorender functionality and this seems to happen only in a virtual environment. I can give more context if needed.

image

Nansi
Telerik team
 answered on 21 Mar 2024
0 answers
239 views

I find with the latest Telerik extension enabled, I cannot type anything ( even plain text, with no html tags ) in the non-code section of a razor component ( .razor file ) due to excessive snippet activations ( they don't just list, they insert when spacing to the next word ).  I have played with the VS Options for both csharp and razor editor advanced settings and nothing seems to work.  There are several new settings related to snippets, but the Telerik extension doesn't seem to honor them.  For example, there is one that requires a double tab to select a snippet.  Instead, tab, space, etc select the first one in the list, meaning I am constantly fighting to remove the inserted snippet on literally every other word.  Snippets behave as expected if I disable the Telerik extension and restart VS. And it does it in both the latest Preview and non-Preview versions of Visual Studio ( installed side by side on same machine ).

I feel like this may be more related to recent .net 8 era razor editor changes in VS, some of which is experimental, as well as a "new" razor editor.  ( i have not tested in the legacy razor editor because i don't want to use the legacy razor editor in general ).  I've searched in various ways here and haven't found anyone reporting the same issue, so I'm not sure if it's just me, or if I'm the first to report it.  I don't have any other code helpers or extensions installed.

Thank you for your time and consideration.  I'm happy to jump on a teams call with anyone who might want to see it happening, although it should be easy to replicate on latest VS 2022.

Brian
Top achievements
Rank 1
 updated question on 20 Mar 2024
1 answer
199 views

I have a chart with two line series, one showing current values, and the other as a reference line.

On the reference line I don't want any adornment or interaction, so I have made the markers invisible.

However, the data points still appear if you hover over where they would be.

Is there a property to prevent that?

At the moment I'm just setting their size to zero to make them as least noticeable as possible

Svetoslav Dimitrov
Telerik team
 answered on 20 Mar 2024
4 answers
7.8K+ views

How do I right-align grid column values? I tried the Template with a span but it does not seem to work and it also adds another element.

 

This does not work:

                <GridColumn Field="Amount">
                    <Template>
                        <span style="text-align:right">
                            @((context as BO).Amount.ToString("C"))
                        </span>
                    </Template>
                </GridColumn>

 

Thanks.

 

Joel

 

Leland
Top achievements
Rank 2
Iron
Iron
Iron
 updated answer on 19 Mar 2024
0 answers
117 views

I implemented the AutoFitAllColumnsAsync() on the CustomGrid, but the column don't resize

Please see structure below

<CustomGrid @ref="@Grid"

OnRead="@OnGridRead" TItem="@Product" Pageable="true" Sortable="true" Resizable="true" FilterMode="GridFilterMode.FilterRow"> <GridColumns>

<CascadingValue Value="grid.GetDistinctColumnFilterValues">

<CustomGridColumn Field="@nameof(Product.Name)" Title="Product Name" /> <CustomGridColumn Field="@nameof(Product.Price)" /> <CustomGridColumn Field="@nameof(Product.ReleaseDate)" Title="Release Date" /> <CustomGridColumn Field="@nameof(Product.Active)" />

<CascadingValue>

</GridColumns>

</CustomGrid>

Glendys
Top achievements
Rank 1
Iron
 asked on 19 Mar 2024
Narrow your results
Selected tags
Tags
+? 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?