Hello Telerik,
I'm looking to reproduce one of the gauge of Yahoo finance (see objectiv.jpg) but I'm stuck with my prototype (see actual.jpg) and the following questions !
- How to change the text of labels ?
- How to customize the rendering of the needleIndicator and its label ? (In my prototype I can't put the label above the NeedleIndicator with TextOffsetIndicator because it go outside the border of the control and is not drawn)
Thank you for your support
Marco Guignard
Hello, does anybody have experience with printing gridview where one of the columns contains strings formatted with barcode font?
I have three columns in the grid and my goal is to print gridview where one column is formatted with barcode font and the rest of columns are formatted with different font. I am able to set the barcode font to all datacells. It seems that GridPrintStyle does not support such granular columns formatting.
private
void
btnPrintDispatchedContainers_Click(
object
sender, EventArgs e)
{
GridPrintStyle style =
new
GridPrintStyle();
style.FitWidthMode = PrintFitWidthMode.NoFit;
style.PrintGrouping =
true
;
style.PrintHeaderOnEachPage =
true
;
style.PrintHiddenColumns =
false
;
Font barcodeFont =
new
Font(
"Code 128"
, 20f, FontStyle.Regular);
Font groupRowFont =
new
Font(
"Segoe UI"
, 12f, FontStyle.Bold);
style.CellFont = barcodeFont;
style.GroupRowFont = groupRowFont;
rgvDispatchedContainers.PrintStyle = style;
rgvDispatchedContainers.Print();
}
Any thoughts will be appreciated.
Hi,
When I query a RadGridView column's FilterDescriptor (.ToString()) I am getting basically an SQL representation of the applied filter, for example:
([coupon] >= 0.5) AND (([analytics_model_class] LIKE '%Other%' OR [analytics_model_class] NOT LIKE '%Card%'))
However, when I have to set the FilterDescriptor programmatically, I need to use the code as described here:
https://docs.telerik.com/devtools/winforms/controls/gridview/filtering/setting-filters-programmatically-(composite-descriptors)
This is pretty hard if I load a previously created SQL-like clause and now need to parse it in order to set the FilterDescriptors for all the columns.
Seems to me that there should be a utility available for this kind of purpose already, especially since Telerik already converts FilterDescriptors to SQL-like clauses.
Is there something that can help?
Thank you
Peter
Hello,
I am currently using a Scheduler control in weekview where the range of hours that's visible is about 6 hours.
The appointments are shown in this view but the text is always aligned at the top of the AppointmentElement.
When the top of the AppointmentElement is outside the view, you see only a colored rectangle and it's not clear what appointment is shown
Is there a way to
- align the text at the top of the AppointmentElement when the start-time is within the view.
- align the text at the top of the Schedulerview when the start-time is NOT within the view. (the text will be shown somewhere in the middle of the rectange)
I have added a picture to clarify my question.
Best regards
Patrick Vossen
I'm having an issue with updates not occurring in a while scrolling ListView with SimpleListViewVisualItem children down - scrolling up works fine. Figuring it has to do with virtualization/cell reuse and the VisualItemFormatting method is incomplete and needs to update the row.
Where am I going wrong?
Thanks,
_D
using
System;
using
System.ComponentModel;
using
System.Drawing;
using
System.Windows.Forms;
using
Telerik.WinControls.Layouts;
using
Telerik.WinControls.UI;
namespace
TelerikWinFormsApp4
{
public
partial
class
RadForm1 : Telerik.WinControls.UI.RadForm
{
public
RadForm1()
{
InitializeComponent();
this
.radListView1.VisualItemCreating +=
new
ListViewVisualItemCreatingEventHandler(
this
.radListView1_VisualItemCreating);
this
.radListView1.VisualItemFormatting +=
new
ListViewVisualItemEventHandler(radListView1_VisualItemFormatting);
// Populate BullJiveTestListItem with fluff
BindingList<BullJiveTestListItem> rows =
new
BindingList<BullJiveTestListItem>();
for
(
int
alpha = 65; alpha < 85; alpha++) rows.Add(
new
BullJiveTestListItem(Convert.ToChar(alpha).ToString()));
this
.Size =
new
Size(500, 300);
radListView1.DataSource = rows;
radListView1.ItemSize =
new
Size(0, 100);
radListView1.FullRowSelect =
true
;
}
private
void
radListView1_VisualItemCreating(
object
sender, ListViewVisualItemCreatingEventArgs e)
{
if
(radListView1.ViewType == ListViewType.ListView)
{
e.VisualItem =
new
RowVisualItem();
}
}
private
void
radListView1_VisualItemFormatting(
object
sender, ListViewVisualItemEventArgs e)
{
if
(radListView1.ViewType == ListViewType.ListView)
{
//BullJiveTestListItem v = (BullJiveTestListItem)e.VisualItem.Data.Value;
//????
}
}
}
public
class
RowVisualItem : SimpleListViewVisualItem
{
private
LightVisualElement hBox0, hBox1;
private
StackLayoutPanel horizontalLayout;
private
Point newSize =
new
Point(0, 100);
protected
override
void
CreateChildElements()
{
base
.CreateChildElements();
horizontalLayout =
new
StackLayoutPanel();
horizontalLayout.Orientation = Orientation.Horizontal;
hBox0 =
new
LightVisualElement();
hBox0.MinSize =
new
Size(newSize);
horizontalLayout.Children.Add(hBox0);
hBox1 =
new
LightVisualElement();
hBox1.MinSize =
new
Size(newSize);
horizontalLayout.Children.Add(hBox1);
Children.Add(horizontalLayout);
}
protected
override
void
SynchronizeProperties()
{
base
.SynchronizeProperties();
if
(
this
.FindAncestor<RadListViewElement>() ==
null
)
return
;
this
.Text =
"<html><span style=\"color:black;font-size:14.5pt;\">Text</span>"
;
hBox0.Size =
new
Size(newSize);
hBox0.Text =
"<html><span style=\"color:green;\">(hBox0)Value0: </span><span style=\"color:DarkMagenta;\">"
+
this
.Data[
"Value0"
] +
"</span>"
+
"<br><span style=\"color:red;\">(hBox0)Value1: </span><span style=\"color:blue;\">"
+
this
.Data[
"Value1"
] +
"</span>"
;
hBox1.Size =
new
Size(newSize);
hBox1.Text =
"<html><span style=\"color:darkblue;\">(hBox1)Value2: </span><span style=\"color:purple;\">"
+
this
.Data[
"Value2"
] +
"</span>"
+
"<br><span style=\"color:orange;\">(hBox1)Value3: </span><span style=\"color:gray;\">"
+
this
.Data[
"Value3"
] +
"</span>"
;
TextAlignment = ContentAlignment.TopLeft;
}
protected
override
Type ThemeEffectiveType
{
get
{
return
typeof
(SimpleListViewVisualItem);
}
}
}
public
class
BullJiveTestListItem
{
public
BullJiveTestListItem(
string
s)
{
Value0 = s +
"0"
;
Value1 = s +
"1"
;
Value2 = s +
"2"
;
Value3 = s +
"3"
;
}
public
string
Value0 {
get
;
set
; }
public
string
Value1 {
get
;
set
; }
public
string
Value2 {
get
;
set
; }
public
string
Value3 {
get
;
set
; }
}
}
I have a CheckedListBox with 3 columns.
But, I can't figure out how to set the width of each column even though I have used the code shown below;
Private Sub BuildListBoxColumns()
Dim nameColumn As New ListViewDetailColumn("Line Item Description")
nameColumn.HeaderText = "Line Item Description"
nameColumn.MinWidth = 800
nameColumn.Width = 800
Me.lbInvoiceItems.Columns.Add(nameColumn)
Dim SKUColumn As New ListViewDetailColumn("SKU")
SKUColumn.HeaderText = "SKU"
SKUColumn.MinWidth = 120
SKUColumn.Width = 120
Me.lbInvoiceItems.Columns.Add(SKUColumn)
Dim QtyColumn As New ListViewDetailColumn("Qty")
QtyColumn.HeaderText = "Qty"
QtyColumn.MinWidth = 80
QtyColumn.Width = 100
Me.lbInvoiceItems.Columns.Add(QtyColumn)
End Sub
The MinWidth on each columns simply doesn't work.
How do I properly set the minwidth for each column?
it's probably something simple, but I cannot see why this isn't working
Good Morning.
I am trying to figure out how to programmatically (C#) add text to the editor with styles built into to the string. The codes that the editor control accepts doesn't matter to me as I can run a conversion from the string to what's acceptable by the control. I've looked through the documentation that I could find and only found things like "control.method" instead of the control actually reading the text to find out what to "Switch on and off", etc.
For a crude example, an html string might consist of "hello my <b>bold</b> string.". What would I replace <b> and </b> with so that the editor can translate them into bold and non-bold? I am only using HTML has an example, it could be anything.
Normally, I wouldn't use the editor control as it has a tons of stuff I would never use, but it seems to be the only control available for possibly support styles, colors, and inline images (emoticons).
Hi, I'm using the code sample from this page:
Handling Users Input | Toast Notification | Telerik UI for WinForms
But after clicking on button_Click() - nothing happens. E.g., the Toast Notification does not appear.
Private Sub button_Click(ByVal sender As Object, ByVal e As EventArgs)
Me.radToastNotificationManager.ShowNotification(1)
End Sub
I must be missing something?!
I'm running on Windows 10 if that makes a difference or not.
Do I need to change a setting in windows 10 somewhere for the notifications to appear?
Hi!
I managed to hide the ApplicationButton of my RibbonBar by setting its visibility to hidden.
But the space where the button was is still visible, see attached screenshot 1, I would like have the first RibbonTab start at the very left, see screenshot 2.
Is this possible? If not, is it at least possible to set the color of the space where the button was to white?
Thanks a lot!
Screenshot 1:
Screenshot 2: It should look like this:
is there a way to capture when the Search Bar Text is chaging/changed?
TIA