Telerik Forums
UI for WinForms Forum
4 answers
504 views
Hi,

I have a telerik grid view where i am showing one table from my dataset which contains total 4 tables. Now while exporting to excel, i want to export all the tables instead of just one. How can i achieve this using telerik features.


thanks
kapil
Ivan Petrov
Telerik team
 answered on 11 May 2012
1 answer
284 views
Hi,

What's the intended/best way of setting the location for RadGridView's ColumnChooser dialog box? I want to show it at the center of the calling application (ideally) or at least within the bounds of the calling application.

I tried using ColumnChooser.StartPosition = FormStartPosition.CenterParent but it didn't work. May be because its Parent or MdiParent is set to NULL (I found this while debugging).

Thus currently I am setting the DesktopLocation property of ColumnChooser to the DesktopLocation of ParentForm offset by (50, 50).

//Since workListRadGridView.ColumnChooser's Parent or MdiParent property is not set,
//setting its StartPosition to FormStartPosition.CenterParent doesn't work.
//As a workaround, get parent form's desktop location and offset it 50 pixels from
//both X and Y co-ordinates to keep the column chooser within the bounds of the application.
//Parent form desktop location.
//DesktopLocation property is idle choice because of the following remark in its documentation on MSDN:
//"If your application is running on a multimonitor system, the coordinates of the form are the coordinates for the combined desktop."
//Telerik's documentation for ColumnChooser also has the mention for DesktopLocation property.
//(though not in the context of "setting the location")
 
if (this.ParentForm != null
    && this.ParentForm.DesktopLocation != null)
{
    Point columnChooserDesktopLocation = new Point(this.ParentForm.DesktopLocation.X, this.ParentForm.DesktopLocation.Y);
    columnChooserDesktopLocation.Offset(50, 50);
    radGridView.ColumnChooser.DesktopLocation = columnChooserDesktopLocation;
}


But I am bit apprehensive of ParentForm being NULL or this approach not working correctly for some reason. Thus needed to know if there exists a better way of specifying the location of the ColumnChooser.

Also, more importantly, I want the above code to work even if the user has more than one monitor/display unit.

Thanks,
~Abhay
Svett
Telerik team
 answered on 11 May 2012
1 answer
280 views
Hi guys,

I'm having a little trouble trying to get the RadDock working.

Here is my scenario:
I have a windows form which contains a RadPageView. Inside one of those tabs I have multiple RadSplitContainers which are giving me left, center, right and bottom panels. The left, right and bottom ones are fixed with the center expanding with the form/window. In each of these I need to house UserControls or Forms.

But how?

I've dropped a RadDock into a panel and set it to fill the parent. I've then created both a UserControl and a Form which at run time (Form1_Load) either one gets inserted into the RadDock. Something like this (ucBBMain is my UserControl):

UserControl uc = new ucBBMain();
radDock1.DockControl(uc, DockPosition.Fill);

But I get an  error:
"Invalid DockTabStrip for a DockPosition.Fill operation."

I also tried this but get the same error:
UserControl uc = new ucBBMain();
HostWindow host = new HostWindow(uc, DockType.Document);
radDock1.DockControl(host, DockPosition.Fill);

Very same happens with a Form.

So how can I put UserControls or Forms into a RadDock where their size is expanded to the RadDock they are inside?

Or in fact is a RadDock the correct control to use? Can I put a UserControl directly into the SplitContainer panels?
Julian Benkov
Telerik team
 answered on 11 May 2012
1 answer
153 views
Hi,

I'm using a ShapedForm that has a PageView in it. When I set the PageView to Dock Fill, it covers the TitleBar completely.

How can I have the PageView just fill the form but not the TitleBar?

Thanks.

Sacha
Sacha
Top achievements
Rank 1
 answered on 11 May 2012
1 answer
130 views
We are facing several problems when persisting properties changed at design time. Sometimes with no apparent reason the properties changes are not saved to disk nor showed at run time.
It happens with radtreeview, radmenu, radmaskededit.
Working with imagelist in radtreeview is a nightmare. Changing fonts in radmenu does not work anymore. ExcludePromptsandLiterals works in one machine but not in the other.
Theses problems are driving us insane, since it happens in different projects and different machines.
These machines are running windows 7 and visual studio 2010.
I just can´t believe simple things like these do not work properly. I would like to hear from you what could possibly be happening. 
Peter
Telerik team
 answered on 11 May 2012
2 answers
238 views
I am entering avalues into another text box and I want it to surrender Focus to another textbox if the value I have entered is the same as the one in the database.However what is happening is that  if the value is the same as in the database the cursor just disappears and it does not give focus to the control that I want it to give focus to. Any ideas on how I can correct this.

Private Sub txtProducedAt_TextChanged(sender As System.Object, e As System.EventArgs) Handles txtProducedAt.TextChanged
 
        Dim iSql As String = "SELECT ID,SiteName   FROM  Sites WHERE SiteName = '" & txtProducedAt.Text & "'     "
        Dim da As New OleDbDataAdapter(iSql, LoginForm1.Conn)
        Dim dTable As DataTable = New DataTable
        da.Fill(dTable)
        If dTable.Rows.Count = 0 Then
 
            Exit Sub
 
        ElseIf dTable.Rows.Count > 0 Then
 
            txtProducedAt.Text = dTable.Rows(0)("SiteName").ToString
 
            txtAccountNumber.Focus()
 
        End If
 
    End Sub
Stefan
Telerik team
 answered on 11 May 2012
2 answers
160 views
I have a client request to hide the first 7 columns of a grid if they are the same values as the columns above. I have the logic to check and match the previous row but I can't find a way to iterate through the cells in RowInfo.

I was planning on setting the ForeColor to the BackColor to hide it from the user but keep the value so I can sort correctly. Any suggestions would be greatly appreciated.

Thanks,
Tom

        void radGridView1_RowFormatting(object sender, RowFormattingEventArgs e)
        {
            GridViewRowInfo row = e.RowElement.RowInfo;

            if (row.ViewTemplate != this.gridDashboard.MasterTemplate)
            {
                return;
            }

            if (lastRow == null)
            {
                lastRow = row;
                return;
            }

            // Does the current row match the last row?
            if (lastRow != null && lastRow != row)
            {
                bool isMatch = true;
                for (int i = 0; i < 8; i++)
                {
                    if (!Object.Equals( row.Cells[i].Value,  lastRow.Cells[i].Value))
                    {
                        isMatch = false;
                    }
                }

                if (isMatch)
                {
                    for (int i = 0; i < 8; i++)
                    {
                        // Clear the duplicate cells
                        // by setting ForeColor = BackColor
                    }
                }
                else
                {
                    lastRow = row;
                }
            }
        }


Tom Uellner
Top achievements
Rank 1
 answered on 10 May 2012
2 answers
104 views
Hey, i need little help so i finished application was using metroblue and desert theme combined and i released application now when i try it on other computer it doesnt work :/ what should i doo? please tell me? :/
Stefan
Telerik team
 answered on 10 May 2012
1 answer
254 views
I have a functionality where i need to add nodes to the tree and get the name of the node form the user , in the node by using beginedit.
I have some custom validation that  i need to do , i am using the valueValidation event for doing that. once the validation is done , If the validation fails , i.e when i do e.cancel = true and validation error gets triggered , i want the new node added during the process to be removed. I tried doing it in validationerror event , but this is not allowed. please let me know how can i do this.

Regards
Harsh
Julian Benkov
Telerik team
 answered on 10 May 2012
1 answer
113 views
Hi~ I have a question.

I'm familar with is the Expression Blend. 
Can I edit control template by VSB?





Stefan
Telerik team
 answered on 09 May 2012
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)
Form
Chart (obsolete as of Q1 2013)
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
PdfViewer and PdfViewerNavigator
CommandBar
ListControl
Carousel
GanttView
Diagram, DiagramRibbonBar, DiagramToolBox
Panorama
New Product Suggestions
VirtualGrid
Toolstrip (obsolete as of Q3 2010)
Label
AutoCompleteBox
Spreadsheet
ContextMenu
Panel
Visual Studio Extensions
TitleBar
SplitContainer
Documentation
Map
DesktopAlert
CheckedDropDownList
ProgressBar
MessageBox
TrackBar
Rotator
SpinEditor
CheckedListBox
StatusStrip
Wizard
CollapsiblePanel
LayoutControl
ShapedForm
SyntaxEditor
TextBoxControl
Conversational UI, Chat
DateTimePicker
TabbedForm
CAB Enabling Kit
WaitingBar
GroupBox
DataEntry
ScrollablePanel
ScrollBar
ImageEditor
Tools - VSB, Control Spy, Shape Editor
BrowseEditor
DataFilter
FileDialogs
ColorDialog
Gauges (RadialGauge, LinearGauge, BulletGraph)
ApplicationMenu
RangeSelector
CardView
WebCam
NavigationView
BindingNavigator
RibbonForm
Styling
Barcode
PopupEditor
TaskBoard
Callout
ColorBox
PictureBox
FilterView
Accessibility
VirtualKeyboard
DataLayout
Licensing
ToastNotificationManager
ValidationProvider
CalculatorDropDown
Localization
TimePicker
BreadCrumb
ButtonTextBox
FontDropDownList
BarcodeView
Overlay
Security
LocalizationProvider
Dictionary
TreeMap
StepProgressBar
SplashScreen
Flyout
Separator
SparkLine
ToolbarForm
NotifyIcon
DateOnlyPicker
AI Coding Assistant
Rating
TimeSpanPicker
Calculator
OfficeNavigationBar
TaskbarButton
HeatMap
SlideView
PipsPager
AIPrompt
TaskDialog
TimeOnlyPicker
SpeechToTextButton
SmartPasteButton
+? more
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?