Telerik Forums
UI for WinForms Forum
12 answers
745 views
Hi all,

Please help, when I set message to statusStrip element and do refresh it shows only 3character.
eg.   RSS.Items("StatusMessage").Text = "Calculate Total"
       RSS.Refresh()
then when I run, it shows "Cal..."  , I want it to show all text whatever I set to.
Here is my designer code
'RSS
'
Me.RSS.AutoSize = True
Me.RSS.BackColor = System.Drawing.Color.LightCyan
Me.RSS.Items.AddRange(New Telerik.WinControls.RadItem() {Me.ProcessDateTime, Me.RadToolStripSeparatorItem1, Me.Source, Me.RadToolStripSeparatorItem2, Me.StatusMessage, Me.RadToolStripSeparatorItem3, Me.Count, Me.RadToolStripSeparatorItem4, Me.Version})
Me.RSS.LayoutStyle = Telerik.WinControls.UI.RadStatusBarLayoutStyle.Stack
Me.RSS.Location = New System.Drawing.Point(0, 242)
Me.RSS.Name = "RSS"
Me.RSS.Size = New System.Drawing.Size(736, 33)
Me.RSS.SizingGrip = False
Me.RSS.TabIndex = 0
Me.RSS.Text = "RadStatusStrip1"
Me.RSS.ThemeName = "Aqua"
Me.RSS.UseWaitCursor = True
'
'ProcessDateTime
'
Me.ProcessDateTime.AutoSize = False
Me.ProcessDateTime.AutoSizeMode = Telerik.WinControls.RadAutoSizeMode.WrapAroundChildren
Me.ProcessDateTime.Bounds = New System.Drawing.Rectangle(0, 0, 100, 22)
Me.ProcessDateTime.Margin = New System.Windows.Forms.Padding(1)
Me.ProcessDateTime.Name = "ProcessDateTime"
Me.RSS.SetSpring(Me.ProcessDateTime, False)
Me.ProcessDateTime.Text = "time"
Me.ProcessDateTime.TextWrap = True
'
'RadToolStripSeparatorItem1
'
Me.RadToolStripSeparatorItem1.Margin = New System.Windows.Forms.Padding(1)
Me.RadToolStripSeparatorItem1.Name = "RadToolStripSeparatorItem1"
Me.RSS.SetSpring(Me.RadToolStripSeparatorItem1, False)
Me.RadToolStripSeparatorItem1.Text = "RadToolStripSeparatorItem1"
'
'Source
'
Me.Source.AutoSize = False
Me.Source.AutoSizeMode = Telerik.WinControls.RadAutoSizeMode.WrapAroundChildren
Me.Source.Bounds = New System.Drawing.Rectangle(0, 0, 69, 20)
Me.Source.Margin = New System.Windows.Forms.Padding(1)
Me.Source.Name = "Source"
Me.RSS.SetSpring(Me.Source, False)
Me.Source.Text = "source"
Me.Source.TextWrap = True
'
'RadToolStripSeparatorItem2
'
'
'StatusMessage
'
Me.StatusMessage.AutoSize = False
Me.StatusMessage.AutoSizeMode = Telerik.WinControls.RadAutoSizeMode.WrapAroundChildren
Me.StatusMessage.Bounds = New System.Drawing.Rectangle(0, 0, 384, 20)
Me.StatusMessage.Margin = New System.Windows.Forms.Padding(1)
Me.StatusMessage.Name = "StatusMessage"
Me.RSS.SetSpring(Me.StatusMessage, False)
Me.StatusMessage.Text = "status"
Me.StatusMessage.TextWrap = True
'
'RadToolStripSeparatorItem3
'
'
'Count
'
Me.Count.AutoSize = False
Me.Count.AutoSizeMode = Telerik.WinControls.RadAutoSizeMode.WrapAroundChildren
Me.Count.Bounds = New System.Drawing.Rectangle(0, 0, 80, 27)
Me.Count.Margin = New System.Windows.Forms.Padding(1)
Me.Count.Name = "Count"
Me.RSS.SetSpring(Me.Count, False)
Me.Count.Text = "count"
Me.Count.TextWrap = True
'
'RadToolStripSeparatorItem4
'
'
'Version
'
Me.Version.AutoSize = False
Me.Version.AutoSizeMode = Telerik.WinControls.RadAutoSizeMode.WrapAroundChildren
Me.Version.Bounds = New System.Drawing.Rectangle(0, 0, 79, 20)
Me.Version.Margin = New System.Windows.Forms.Padding(1)
Me.Version.Name = "Version"
Me.RSS.SetSpring(Me.Version, False)
Me.Version.Text = "version"
Me.Version.TextWrap = True

Thanks and best regards
Peter
Telerik team
 answered on 11 Feb 2011
3 answers
151 views
HI

 In my Application , a dropdown list having Binding source (master table data),on the dropdown list  selected index
a gridviews data (Detail table data) is populated..
 But same time dropdown list does not work properly (selected item does not changed)......

Please provide me any solution on that situation
....
Thank you

Richard Slade
Top achievements
Rank 2
 answered on 11 Feb 2011
2 answers
156 views
Hey,
    I am doing a lot of calculations to the grid through code and it is real slow if I don't use grid.beginupdate() & grid.endupdate(). However, when i call these I lose the edit of the selected cell. Oh well, so i store the current cell information and try to set it to edit after all the calculations have been done:


 

Me.gvRoomNights.Rows(_LastRowIndex).Cells(_LastColIndex).BeginEdit()

However this doesn't seem to work. Actually it never really loses edit, if you type it will edit. However, it doesn't look like it is in edit mode. For example, it is not white and no cursor.

Another,
    When I call, grid.beginupdate() & grid.endupdate(), the gird loses all of its cell formatting as far as backcolor.

Thanks in advance

Eric

 

Svett
Telerik team
 answered on 11 Feb 2011
4 answers
184 views
Is there a way to only have the nulltext italisized?  I do not want the entered text by the user to be italisized.  This seems like it would be a pretty popular thing so it seems like there must be a way , thanks in advance.
regina.
Richard Slade
Top achievements
Rank 2
 answered on 11 Feb 2011
6 answers
235 views
I've got a form has the following
PageView with 2 Pages (Let's call them A and B)
On Page B, I will have another PageView with n pages (Generated at run-time).

The problem that I'm having is that there is a margin inside the PageView (top [3px] and left [5px] - bottom and right have no margin) in such that I cannot get a nice flush finish. See screenshot attached. I've verified that all the properties for both Margin and Padding are set to 0.

I also noticed that in the location must be set at -5,-3 in order to line up with the edges correctly - which is the same amount that this additional margin is adding.

In fact, I wanted to change the margin to say 10 just to try going the other way (so I knew I was adjusting the correct margin property), but it only worked for the bottom margin, no others.

If someone could provide an example of what I am doing wrong, or how to nest 2 pageviews with no margin, please let me know.

Thanks



Ivan Petrov
Telerik team
 answered on 11 Feb 2011
10 answers
423 views
Hi. I have a datagrid that has a data source added programatically. I need a column to calculate an expression based on the data, but it is not working. Is it possible to combine expressions in data gridviews? Below is a snippet of my code.

Thanks.

Javier

 

 

With gvEntregaDetalle
    .MasterTemplate.AllowAddNewRow =
False
    .MasterTemplate.AutoGenerateColumns = False
    .MasterTemplate.AllowDeleteRow = False
    .TableElement.BeginUpdate()
    .Columns(
"Pendiente").Expression = "Cantidad-Surtido"
    .MasterTemplate.LoadFrom(sqlDR)
    .TableElement.EndUpdate()
End With

 

Julian Benkov
Telerik team
 answered on 11 Feb 2011
3 answers
441 views
Hello, I am using 2010 Q2

1)

I want to display amount in Indian format on grid column.
Is it possible to assign directly using inbuilt formatting?

OR

If not we are using below code for Microsoft Datagridview

NumberFormatInfo RupeeFormat = new NumberFormatInfo(); 
RupeeFormat.NumberGroupSeparator = ","
RupeeFormat.NumberGroupSizes = new int[] {3, 2};
  
//NOTE: default format for decimal type columns 
DataGridViewCellStyle DecimalStyleVal = New DataGridViewCellStyle(); 
DecimalStyleVal.FormatProvider = RupeeFormat;
DecimalStyleVal.Format = ConstantsUtils.PriceFormat; 
DecimalStyleVal.NullValue = "0.00"
DecimalStyleVal.Alignment = DataGridViewContentAlignment.MiddleRight; 

 


Now we are just using this on Form Load  as shown below(not handling any formatting event)

Form_Load
{
    gridview.Columns["Amount"].DefaultCellStyle = DecimalStyleVal ;
}

How to achive this in your grid, by assigning cellstyle only?
This is working perfectly in MS datagridview.

Display Example:
Decimal value = 12345678.95  
( required view )
Display in dgv column = 1,23,45,678.95

Or any alternative to display format as shown in example?

2) How can i apply Numberformat to your gridview column in form loading
3) If possible how to apply for Summary also.

4)
 I have a grid showing Stock price.
Which is updating every second.
I want to apply conditional formatting on that


ConditionalFormattingObject c1 = new ConditionalFormattingObject( "Grater", ConditionTypes.Greater, "5", "", true );
c1.CellBackColor = Color.LightBlue;
c1.CellForeColor = Color.Black;
  
  
ConditionalFormattingObject c2 = new ConditionalFormattingObject( "Less", ConditionTypes.Less, "5", "", true );
c2.CellBackColor = Color.IndianRed;
c2.CellForeColor = Color.Black;
  
ConditionalFormattingObject c3 = new ConditionalFormattingObject( "Equal", ConditionTypes.Equal, "5", "", true );
c3.CellBackColor = Color.White;
c3.CellForeColor = Color.Black;

 
I am using above code for generating conditions.
However, here i am having "5" as a Value1 parameter, instead of that i want to check the same cell value with the new value for same cell

Like say, A column BidPrice have value 50 (Old value backcolor = black)
New price after 1 sec is 51 (New value)

so i want to put conditionalformatting in such a way that it should check Old value and New value for setting cell colors for price change display. in this case "c1" will be applied to the cell after new value.
Display should be BidPrice 51 ( backcolor = blue )

Hope you undderstand wat i want to ask.

Thanks,

Jack
Telerik team
 answered on 11 Feb 2011
1 answer
118 views
If anyone is struggling with your template columns not resizing when your form is resized, after trying misc. things this worked for me.

It appears that the gridview redraws itself, but does not resize template columns.

private void frmMyForm_SizeChanged(object sender, EventArgs e)
        {
            gridViewTemplate1.Refresh();
            gridViewTemplate2.Refresh();
        }
Jack
Telerik team
 answered on 11 Feb 2011
5 answers
331 views
Hi All,

OK I am feeling somewhat stupid at the moment.  I have a Windows forms app with a datagrid on it.  In the menu I have an option to allow the user to resync the database with my main SQL database.  It uses merge replication and it all works fine.  The problem that I am having is stupidly simple by comparison to the task of syncing the data.  Once the syncronisation has finished, I need the datagrid to repopulate itself with any changed data.  2 minute job I thought, an hour later I still am having issues!

There are some threads discussing what I think is the same issue but people seem to be missing the stick and talking about setting the datasource to null and then reconnecting it.  Well that works but the RadGrid seems to then add in all of the hidden ID columns etc again.

Surely there is a command  like Refresh (what does that do anyway?  does it just redraw the grid?) that works on this.  On Asp.Net Refresh does as you'd expect and refreshes the data in the grid. 

All I want to do is tell the grid to reload it's data!

Any ideas anyone?

Regards,

Jon
Jon
Top achievements
Rank 1
 answered on 11 Feb 2011
6 answers
157 views
Hello

I am sorry if this is a really simple question, but I can't seem to find the answer.

How do you have a vertical scroll bar in the gridview column chooser?

Thanks

Bex
Svett
Telerik team
 answered on 10 Feb 2011
Narrow your results
Selected tags
Tags
GridView
General Discussions
Scheduler and Reminder
Treeview
Dock
RibbonBar
Themes and Visual Style Builder
ChartView
Calendar, DateTimePicker, TimePicker and Clock
DropDownList
Buttons, RadioButton, CheckBox, etc
ListView
ComboBox and ListBox (obsolete as of Q2 2010)
Chart (obsolete as of Q1 2013)
Form
PageView
MultiColumn ComboBox
TextBox
RichTextEditor
PropertyGrid
Menu
RichTextBox (obsolete as of Q3 2014 SP1)
Panelbar (obsolete as of Q2 2010)
PivotGrid and PivotFieldList
Tabstrip (obsolete as of Q2 2010)
MaskedEditBox
CommandBar
PdfViewer and PdfViewerNavigator
ListControl
Carousel
Diagram, DiagramRibbonBar, DiagramToolBox
GanttView
Panorama
New Product Suggestions
Toolstrip (obsolete as of Q3 2010)
VirtualGrid
AutoCompleteBox
Label
Spreadsheet
ContextMenu
Panel
Visual Studio Extensions
TitleBar
Documentation
SplitContainer
Map
DesktopAlert
CheckedDropDownList
ProgressBar
TrackBar
MessageBox
Rotator
SpinEditor
StatusStrip
CheckedListBox
LayoutControl
SyntaxEditor
Wizard
ShapedForm
TextBoxControl
Conversational UI, Chat
DateTimePicker
CollapsiblePanel
TabbedForm
CAB Enabling Kit
GroupBox
DataEntry
ScrollablePanel
ScrollBar
WaitingBar
ImageEditor
Tools - VSB, Control Spy, Shape Editor
BrowseEditor
DataFilter
ColorDialog
FileDialogs
Gauges (RadialGauge, LinearGauge, BulletGraph)
ApplicationMenu
RangeSelector
CardView
WebCam
BindingNavigator
PopupEditor
RibbonForm
Styling
TaskBoard
Barcode
Callout
ColorBox
PictureBox
FilterView
Accessibility
NavigationView
VirtualKeyboard
DataLayout
ToastNotificationManager
ValidationProvider
CalculatorDropDown
Localization
TimePicker
ButtonTextBox
FontDropDownList
Licensing
BarcodeView
BreadCrumb
Security
LocalizationProvider
Dictionary
Overlay
Flyout
Separator
SparkLine
TreeMap
StepProgressBar
SplashScreen
ToolbarForm
NotifyIcon
DateOnlyPicker
Rating
TimeSpanPicker
Calculator
OfficeNavigationBar
TaskbarButton
HeatMap
SlideView
PipsPager
AIPrompt
TaskDialog
TimeOnlyPicker
+? more
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?