Quantcast
Channel: DevExpress Support Center (Examples)
Viewing all 7205 articles
Browse latest View live

Synchronization with MS Outlook - a demonstration example

$
0
0
This example allows you to examine the operation of AppointmentExportSynchronizer and AppointmentImportSynchronizer objects which enable you to implement your own synchronization method.
WARNING: When you run this example, you can delete all data in your MS Outlook calendar. We suggest that you backup your data prior to running the example.
Question Comments

Added By: Alexander Koshmelev at: 11/30/2015 10:19:10 PM    

Hello!
Dear devExpress team,
please provide a complete sample of Synchronization with MS Outlook!
Best Regards, Alex

Added By: George (DevExpress Support) at: 11/30/2015 11:08:06 PM    

Hello,

To process your recent post more efficiently, I created a separate ticket on your behalf: T318784: Provide a complete sample of synchronization with MS Outlook. This ticket is currently in our processing queue. Our team will address it as soon as we have any updates.


GridView - How to focus a newly added row

$
0
0

This example demonstrates how to focus a newly added row.

Question Comments

Added By: Zoltán Juhász at: 12/1/2015 3:44:05 AM    

The example does not work with DevExpress 15.1.7. After set FocusedRowIndex property value still remain -1.

Added By: Larry (DevExpress Support) at: 12/1/2015 4:55:45 AM    

Hello,

To process your recent post more efficiently, I created a separate ticket on your behalf: T319045: The E4787 example works incorrectly in version 15.1. This ticket is currently in our processing queue. Our team will address it as soon as we have any updates.

WinForms SpreadsheetControl API

$
0
0

This example demonstrates how to use the SpreadsheetControl API to programmatically manage spreadsheet documents, without the need for Microsoft Excel to be installed.

In particular, this sample introduces API properties and methods used to perform the following operations:

- Manage worksheets (activate, create, delete, rename, copy, adjust worksheet view, etc.)

- Manipulate rows and columns (insert, delete, copy rows and columns, adjust row height and column width, etc.)

- Manipulate cells and cell ranges (set cell values, add hyperlinks to cells, copy and merge cells), create, edit and copy cell comments

- Create formulas (use various functions and cell references in formulas, use names in formulas, create shared and array formulas, etc.)

- Format cells (set cell font, colors, alignment, borders, number format, etc.)

- Export the workbook to PDF

- Print the workbook

Question Comments

Added By: Rodney Stone 1 at: 12/1/2015 10:40:20 AM    

Cannot open form designer, get
The designer cannot process the code at line 32: DirectCast(Me.treeList1, System.ComponentModel.ISupportInitialize).BeginInit() The code within the method 'InitializeComponent' is generated by the designer and should not be manually modified. Please remove any changes and try opening the designer again.

Change the DirectCast to Ctype

How to provide custom images for the CheckEdit control in the GridControl (the PictureChecked and PictureUnchecked in WinForms)

$
0
0

Implement a ControlTemplate with the Image property. In the ControlTemplate, implement a DataTrigger, and change the Image Source property when cell value is True. Assign this ControlTemplate to the GridColumn.EditTemplate and GridColumn.DisplayTemplate properties.

Question Comments

Added By: SANTOSH R. BAMBRULE at: 3/23/2015 4:56:40 AM    

Hello
I got error when i use png format image source property and also i want set image on IsThreeState is true

Added By: Alexander S (DevExpress Support) at: 3/23/2015 12:16:28 PM    Hello,

To process your recent post more efficiently, I created a separate ticket on your behalf: T222793: How to use PNG images for tree-state check boxes in E2628. This ticket is currently in our processing queue. Our team will address it as soon as we have any updates.Added By: David Lemieux at: 12/1/2015 4:17:39 PM    

Is this still the way to go, with optimized mode introduced a while back and all?

Also, is the "slider" standalone checkbox required in any way for the grid to work as expected?

How to use ReportManagerBehavior and GridReportManagerService

How to sort qualitative values in a custom order

$
0
0
This example demonstrates how to implement a custom qualitative scale sort order.

How to configure resolve overlapping for axis labels

$
0
0
This example demonstrates how to configure resolve overlapping for axis labels.

Spreadsheet - How to perform a request to the server using jQuery.ajax to get cell values

$
0
0

It is necessary to update the Spreadsheet state before sending a request to the server. Data for jQuery.ajax is prepared manually, so we cannot automatically trigger editor updates.

There are two possible solutions:

1) Use Ajax.BeginForm instead of a custom $.ajax request. So, the required information will be prepared automatically before the form is posted.

2) Call our non-documented OnPost method that collects all required information for the Spreadsheet. Please note that the name or implementation of this method may be changed in the future without any notification.

 

[JScript]
function OnClick(){   var url = "Home/ValidateSpreadsheet/";    Spreadsheet.OnPost();    $.ajax({        type: "POST",        url: url,        data: $('form').serialize(),        success: function(data){            myLabel.SetText(data);       }   });}

 


How to prevent a DetailView from being shown when a User double clicks or presses the Enter key on a record in a ListView

$
0
0

Scenario

For certain data forms, a developer needs to limit end-users to editing only through the ListView, i.e. without invoking a separate DetailView.  This is usually done by activating the inline editing and MasterDetailMode = ListViewAndDetailView features as described at eXpressApp Framework > Concepts > UI Construction > Views > List View Edit Modes. More real user scenarios are described in this Support Center thread.


For more convenience and flexibility, the following Model Editor extensions are implemented in the example to control this behavior:
 - The DefaultShowDetailViewFromListView  attribute at the Views node level allows you to control this functionality globally per application via the Model Editor;
 - The ShowDetailView attribute at the Views | ListView node level allows you to customize only certain List Views via the Model Editor;




Steps to implement

1. Copy the WinWebSolution.Module\ShowDetailViewFromListViewController.xx file into the YourSolutionName.Module project and rebuild it.

Note: The process of opening a DetailView by double clicking/pressing the Enter key on a record selected in a ListView is managed by the standard DevExpress.ExpressApp.SystemModule.ListViewProcessCurrentObjectController class and its ProcessCurrentObjectAction in particular. So, we can disable this Action to accomplish our task. The approaches from the eXpressApp Framework > Concepts > Application Model > Extend and Customize the Application Model in Code,  eXpressApp Framework > Concepts > Application Model > Access the Application Model in Code and ActionBase.Enabled Property articles will be used here.

2. For testing purposes, invoke the Model Editor and set the DefaultShowDetailViewFromListView or ShowDetailView properties for the Views or Views | YourObjetType_ListView nodes to False and run the test app to see that a required ListView no longer opens a DetailView in the aforementioned scenario.

IMPORTANT NOTES
This article covers only the case when a DetailView is shown from the ListView after a User double clicks/presses the enter key on a record. Other scenarios should be handled separately by extending the code of this controller. For example, if you do not want to show a DetailView after a new object is created via the New Action, you can handle the NewObjectViewController.ObjectCreating event and set its ObjectCreatingEventArgs.ShowDetailView property to False. However, this is outside the purpose of this article.

Question Comments

Added By: John01 at: 12/2/2015 6:18:00 PM    

This is such as useful feature that it should be part of standard XAF.

ASPxReportDesigner - How to register a custom control in Report Designer's toolbox

$
0
0
This example shows how to create a custom control and register it in the Web Report Designer's Toolbox. The example illustrates the steps to expand a set of native report controls by deriving from existing ones.

How to redirect hyperlinks within an exported PDF document

$
0
0
This example demonstrates how to implement the DevExpress.XtraRichEdit.Services.IPdfLinkUpdater interface to redirect hyperlinks within an exported PDF document. In particular, this example merges two HTML files containing cross references into a single PDF document and updates external hyperlinks so that they point to bookmarks within the document.

XL Export API - Examples

$
0
0

This example demonstrates how to use the XL Export API to create spreadsheet files in XLSX, XLS and CSV formats.

This project introduces API properties and methods used to perform the following operations:
- Create a workbook, worksheets, rows, columns and particular cells
- Apply predefined, themed and custom formatting to worksheet cells
- Apply conditional formatting rules
- Enable filtering and group data
- Apply data validation rules
- Assign formulas to worksheet cells
- Specify page settings
- Specify print options
- Insert pictures
- Insert hyperlinks
- Specify document properties

Starting from v2015 vol.2:
- Insert and modify sparklines
- Apply different fonts to specific text regions within a cell
- Create image hyperlinks
- Display a worksheet from right to left

How to return values from the ASPxPopupControl's ContentUrl page and close the popup on both client and server sides

$
0
0

The example illustrates how to return values from the ASPxPopupControl's ContentUrl page. The ContentUrl page calls the “HidePopupAndShowInfo” function, which is defined on the parent page. The function is called on the client and server sides.

See Also:
How to manipulate client-side objects within a ASPxPopupControl with the specified ContentUrl
How to return values from the ASPxPopupControl's ContentCollection and close the popup on both client and server sides
PopupControl - How to pass parameter to Parent Window (from ContentUrl page) and close PopupControl
ASPxSplitter - How to return a value from a page specified via SplitterPane.ContentUrl

Question Comments

Added By: Ganesh Muthuvelu at: 11/16/2013 10:49:05 AM    

When I "Run Online" and click "Show Popup" button - the page is not displayed

Added By: Larry (DevExpress Support) at: 12/3/2015 8:27:16 AM    

Hello,

To process your recent post more efficiently, I created a separate ticket on your behalf: T320291: E3098 example - the page is not displayed. This ticket is currently in our processing queue. Our team will address it as soon as we have any updates.

DateEdit - How to remove increment and decrement year buttons in Classic mode

$
0
0

In version 15.2 of DevExpress components, this goal can be achieved by setting the ShowYearNavigationButtons property to False.

The solution below is up to date for versions 15.1 and lower



This example illustrates how to remove decrement and increment year in DateEdit when the CalendarStyle property is set to Classic
Question Comments

Added By: Michael McCulloch 2 at: 7/6/2015 6:24:11 AM    

This example seems to be missing some code.

Added By: Alisher (DevExpress Support) at: 7/6/2015 8:41:47 AM    

This example contains all sources for creating a DateEdit class descendant with the required functionality. Have you downloaded it on your local machine? 

How to show the TextEdit within a column's header to allow end-users to change the column's caption

$
0
0

This example demonstrates how to catch a double click on a column's header, and show a text editor which allows an end-user to rename the column.

Question Comments

Added By: jtrebino at: 8/8/2012 7:57:50 AM    

I fail to see where in this code example the mouse double click is captured so that the user can then perform some task or have the code actually change the column's caption.

Added By: Dave VanderWekke (Automated Wireless Environments) at: 2/24/2014 12:18:04 PM    

This works great for renaming however if you save the layout the new Caption is not saved in the layout. How can this be achieved?

Added By: Amrit Singh 1 at: 12/3/2015 10:31:57 AM    

Where is the code for MyGridColumnRenameHelper??

Added By: Andrew Ser (DevExpress Support) at: 12/3/2015 10:57:02 AM    Hi,
Find it in the combo box below comments:
Added By: Amrit Singh 1 at: 12/3/2015 4:01:08 PM    

It's awesome.. works good.. thanks much for your prompt help.


How to: Use EnumItemsSourceBehavior

$
0
0
This example demonstrates how to use the EnumItemsSourceBehavior.
Question Comments

Added By: Oliver Harrendorf at: 9/4/2015 5:53:57 AM    

Hi,

did this also works for the WPF RibbonControl? I ask because I tried it and the first initializing failed. There is no value selected in the ComboBoxEdit at first. After an item is selected everything works fine.

Best regards

Oliver

Added By: Ilya (DevExpress Support) at: 9/4/2015 10:28:27 AM    

Hi Oliver,
To process your recent post more efficiently, I created a separate ticket on your behalf: How to apply the solution from T196946 to the RibbonControl. This ticket is currently in our processing queue. Our team will address it as soon as we have any updates.

OBSOLETE - How to validate objects when navigating between records and the list view is in the ListViewAndDetailView mode

$
0
0

=================================
This example is now obsolete. Instead, set the ModificationsController.ModificationsHandlingMode property to AutoCommit.
=================================

By default, XAF objects are not immediately validated when moving between records in the list or detail view and when using the navigation buttons or selecting records in the grid. This example demonstrates how to work around this design and prompt a user once he is about to leave the edit mode and go to another record.

ASPxGridView - How to show the Next/Previous buttons on the popup EditForm

How to automatically scroll the grid during drag-and-drop

$
0
0

This example demonstrates how to scroll grid rows and columns when dragging an object near the grid's edge.

See also:
Drag&drop - Auto-scroll the grid when dragging near its edges
How to automatically scroll the LayoutView during drag-and-drop

Question Comments

Added By: Julien C. at: 8/6/2013 2:16:23 AM    

Hello,

I am sorry, I am having a hard time understanding what "gridView1" stands for in your current example. I created a gridControl, set its datasource, and have been using one view. How do i get the LayoutView from the GridView?

Thank you for your help.

Added By: Julien C. at: 8/6/2013 2:22:42 AM    

Just to be clear: i am not trying to present records as cards (layoutview) but to implement the simplest form of autoscroll when performing drag and drop on a grid. Thanks

Added By: Kosmo14 at: 8/20/2013 2:56:34 PM    

Is there a WPF (instead of winforms) solution to this also?

Added By: avian_johnson at: 12/4/2015 2:21:43 AM    

Hello,

Thanks for this auto scroll code.
It works good for right, left and bottom drag. But there is a wrong condition for top drag in AutoScrollHelper.cs.
this is the condition which not worked for me.
  fScrollInfo.GoUp = (pt.Y < rect.Top + ThresholdInner) && (pt.Y > rect.Top - ThresholdOutter);

I have corrrected it & now it is working for me.
Modified Condition :
    fScrollInfo.GoUp = (pt.Y > rect.Top - ThresholdInner) && (pt.Y < rect.Top + ThresholdOutter);

Thank You

ASPxGridView in Endless Paging Mode with the Total summary item - How to avoid refreshing the whole ASPxGridView control after editing

$
0
0

In this example, the following scenario is illustrated:
1) ASPxGridView operates in Endless paging mode.
2) ASPxGridView contains the total summary item.
3) An ASPxGridView row is updated/deleted/inserted on the N page (for example, the AllowFocusedRow property is set to true and the edit row is focused).
4) After updating, ASPxGridView needs to update the total summary item and get completely refreshed.
5) Due to refreshing ASPxGridView in Endless mode, the control loses all uploaded pages and the edit row loses focus (the current page is reset to the first page and focus is set to the first row).
This example demonstrates how to avoid this scenario. Set the Visible property of the total summary item to false - in this case, ASPxGridView isn't refreshed after the update/delete/insert operation. Then, create a footer template, and use the GetTotalSummaryValue and GetTotalFooterDisplayText methods to fill the template with a required value. 

Viewing all 7205 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>