Sunteți pe pagina 1din 342

Copyright 1987-2007 ComponentOne LLC. All rights reserved.

. Corporate Headquarters ComponentOne LLC 201 South Highland Avenue 3rd Floor Pittsburgh, PA 15206 USA Internet: info@ComponentOne.com Web site: http://www.componentone.com Sales E-mail: sales@componentone.com Telephone: 1.800.858.2739 or 1.412.681.4343 (Pittsburgh, PA USA Office) Technical Support See Technical Support in this manual for information on obtaining technical support. Trademarks ComponentOne Input for .NET and the ComponentOne Input for .NET logo are trademarks, and ComponentOne is a registered trademark of ComponentOne LLC. All other trademarks used herein are the properties of their respective owners. Warranty ComponentOne warrants that the original CD (or diskettes) are free from defects in material and workmanship, assuming normal use, for a period of 90 days from the date of purchase. If a defect occurs during this time, you may return the defective CD (or disk) to ComponentOne, along with a dated proof of purchase, and ComponentOne will replace it at no charge. After 90 days, you can obtain a replacement for a defective CD (or disk) by sending it and a check for $25 (to cover postage and handling) to ComponentOne. Except for the express warranty of the original CD (or disks) set forth here, ComponentOne makes no other warranties, express or implied. Every attempt has been made to ensure that the information contained in this manual is correct as of the time it was written. We are not responsible for any errors or omissions. ComponentOnes liability is limited to the amount you paid for the product. ComponentOne is not liable for any special, consequential, or other damages for any reason. Copying and Distribution While you are welcome to make backup copies of the software for your own use and protection, you are not permitted to make copies for the use of anyone else. We put a lot of time and effort into creating this product, and we appreciate your support in seeing that it is used by licensed users only. Please read License Agreement and Licensing sections in this manual before copying and redistributing any ComponentOne Input for .NET files.

iii

Table of Contents
Welcome to ComponentOne Input for .NET (2.0) ........................................................................ 1 What's New in Input for .NET ...............................................................................................................1 Installing Input for .NET .......................................................................................................................1 END-USER LICENSE AGREEMENT FOR COMPONENTONE SOFTWARE..................................2 Licensing FAQs.....................................................................................................................................8 Technical Support................................................................................................................................12 Redistributable Files ............................................................................................................................13 Namespaces ........................................................................................................................................13 Creating a .NET 2.0 Project .................................................................................................................15 Adding the C1Input Components to a Project.......................................................................................16 Migrating a C1Input Project to Visual Studio 2005................................................................................18 Overview...........................................................................................................................25 Differences from the .NET 1.x Version .................................................................................................25 Using the C1Input Controls ...................................................................................................27 C1Input Controls.................................................................................................................................27 Data Binding .......................................................................................................................................27 Value and Text: Displaying, Validating, and Updating Values...............................................................28 Formatting Data ..................................................................................................................................29 Parsing (Updating) Data ......................................................................................................................38 Culture (Regional) Settings ..................................................................................................................38 Edit Mask............................................................................................................................................39 Validating Data ...................................................................................................................................40 Editing Date and Time Values..............................................................................................................42 Editing Numeric Values .......................................................................................................................42 Drop-Down and Increment Buttons .....................................................................................................42 Custom Drop-Down ............................................................................................................................43 Programmatic Formatting, Parsing and Validation................................................................................43 Error Handling ....................................................................................................................................44 Handling NULL and Empty Values .....................................................................................................46 C1Input Samples .................................................................................................................47 C1Input Tutorials ................................................................................................................49 Binding C1Input Controls to a Data Source ..........................................................................................49 Masked Input ......................................................................................................................................57 Data Navigation and Actions Using C1DbNavigator ............................................................................65 Using C1TextBox for Date-Time Input.................................................................................................69 Data Validation ...................................................................................................................................73 Data Formatting and Parsing ...............................................................................................................78 Using C1DateEdit and C1NumericEdit Controls ..................................................................................84 Custom Drop-Down Form...................................................................................................................88 Editing Numbers in NumericInput Mode .............................................................................................93 C1Input Task-Based Help ......................................................................................................99 Working with a Database.....................................................................................................................99 Adding a Drop-Down Form............................................................................................................... 102 Customizing the C1DateEdit Control ................................................................................................. 107 C1.Win.C1Input.2 Assembly ............................................................................................... 109 C1.Win.C1Input Namespace................................................................................................ 109 C1.Win.C1Input Hierarchy................................................................................................................ 110

iv

ButtonImages Class ........................................................................................................................... 111 C1DateEdit Class .............................................................................................................................. 114 C1DbNavigator Class ........................................................................................................................ 118 C1DropDownControl Class ............................................................................................................... 136 C1Label Class.................................................................................................................................... 148 C1NumericEdit Class ........................................................................................................................ 163 C1PictureBox Class ........................................................................................................................... 173 C1TextBox Class ............................................................................................................................... 182 CustomPlaceholder Class................................................................................................................... 220 DateEditMonthCalendar Class........................................................................................................... 223 DropDownCalculator Class ............................................................................................................... 229 DropDownCalendar Class ................................................................................................................. 234 DropDownForm Class....................................................................................................................... 238 ErrorInfo Class .................................................................................................................................. 248 FormatInfo Class ............................................................................................................................... 253 HighlightingToolBar Class ................................................................................................................. 257 Margins Class.................................................................................................................................... 260 MaskInfo Class.................................................................................................................................. 265 NumericEditCalculator Class ............................................................................................................. 275 ParseInfo Class .................................................................................................................................. 278 PlaceholderCollection Class ............................................................................................................... 290 PostValidation Class .......................................................................................................................... 295 PreValidation Class ........................................................................................................................... 301 UIStrings Class.................................................................................................................................. 310 UIStringsItemEventArgs Class ........................................................................................................... 319 ValueInterval Class ............................................................................................................................ 322 ValueIntervalCollection Class ............................................................................................................ 325 Index .............................................................................................................................. 331

What's New in Input for .NET 1

Welcome to ComponentOne Input for .NET (2.0)


Welcome to ComponentOne Input for .NET, a set of .NET controls designed to allow developers access to a toolbar of enhanced visual components. Input for .NET (C1Input) can help developers display dynamic data in a visual format, manage dataset navigation, display or edit dates, and much more. ComponentOne has a user-friendly distribution policy. You may try C1Input for as long as you wish. C1Input is a part of ComponentOne Studio Enterprise, the largest and most complete component toolset for developing all layers of Windows, Web and Mobile applications. The only restriction is that unlicensed copies will display a ComponentOne banner every time they are loaded to remind you to license the product. If you like C1Input and find it useful, you can purchase ComponentOne Studio Enterprise for a reasonable price. For additional information on ComponentOne Studio Enterprise, please visit our Web site at http://www.componentone.com. We are confident that you'll like Input for .NET. If you have any suggestions or ideas for new features or tools that you'd like to see included in a future version please call us or write: Corporate Headquarters ComponentOne LLC 201 South Highland Avenue 3rd Floor Pittsburgh, PA 15206 USA 412.681.4343 412.681.4384 (Fax) http://www.componentone.com

What's New in Input for .NET


This documentation was last revised for 2006 v3 on July 17, 2006.

Feature Overview
There are no new features in ComponentOne Input for .NET at this time.

Installing Input for .NET


The following sections provide helpful information on installing C1Input for .NET.

Input for .NET Setup Files


The ComponentOne Studio for .NET 2.0 installation program will create the directory C:\Program Files\ComponentOne Studio.NET 2.0, which contains the following subdirectories: bin Common Contains copies of all ComponentOne binaries (DLLs, EXEs). Contains support and data files that are used by many of the demo programs.

2 Welcome to ComponentOne Input for .NET (2.0)

Help C1Input

Contains online documentation for all Studio components. Contains samples and tutorials for C1Input.

System Requirements
System requirements include the following: Operating Systems: Windows 2000 Windows 2003 Server Windows NT 4 Windows XP, SP1 or SP2 Environments: .NET Framework 2.0 C# .NET Visual Basic .NET Disc Drive: CD or DVD-ROM drive if installing from CD

Installing Demonstration Versions


If you wish to try Input for .NET and do not have a serial number, follow the steps through the installation wizard and use the default serial number. The only difference between unregistered (demonstration) and registered (purchased) versions of our products is that registered versions will stamp every application you compile so a ComponentOne banner will not appear when your users run the applications.

Uninstalling Input for .NET


To uninstall Input for .NET: 1. 2. 3. Open the Control Panel and select Add or Remove Programs. Select ComponentOne Studio for .NET 2.0 and click the Remove button. Click Yes to remove the program.

END-USER LICENSE AGREEMENT FOR COMPONENTONE SOFTWARE


IMPORTANT-READ CAREFULLY: This End User License Agreement (this "EULA") contains the terms and conditions that govern your use of the SOFTWARE (as defined below) and imposes material limitations to your rights. You should read this EULA carefully and treat it as valuable property. I. THIS EULA. 1. Software Covered by this EULA. This EULA governs your use of the ComponentOne, LLC ("C1") software product(s) enclosed or otherwise accompanied herewith (individually and collectively, the "SOFTWARE"). The term "SOFTWARE" includes, to the extent provided by C1: 1) any revisions, updates and/or upgrades thereto; 2) any data, image or executable files, databases, data engines, computer software, or similar items customarily used or distributed with computer software products; 3) anything in any form whatsoever intended to be used with or in conjunction with the SOFTWARE; and 4) any associated media, documentation (including physical, electronic and online) and printed materials (the "Documentation"). When using ComponentOne Ribbon for .NET which is provided as part of the SOFTWARE, note that THIS LICENSE GRANTS YOU NO RIGHTS TO THE MICROSOFT OFFICE 2007 UI. TO

END-USER LICENSE AGREEMENT FOR COMPONENTONE SOFTWARE 3

OBTAIN A LICENSE TO USE THE MICROSOFT OFFICE 2007 UI, PLEASE VISIT http://msdn.microsoft.com/officeui. 2. This EULA is a Legally Binding Agreement Between You and C1. If you are acting as an agent of a company or another legal person, such as an officer or other employee acting for your employer, then "you" and "your" mean your principal, the entity or other legal person for whom you are acting. However, importantly, even if you are acting as an agent for another, you may still be personally liable for violation of federal and State laws, such as copyright infringement. By signifying your acceptance of the terms of this EULA, you intend to be, and hereby are, legally bound to this EULA to the same extent as if C1 and you physically signed this EULA. By installing, copying, or otherwise using the SOFTWARE, you agree to be bound by all the terms and conditions of this EULA. If you do not agree to all of such terms and conditions, you may not install or use the SOFTWARE. If you do not agree with any of the terms herewith and, for whatever reason, installation has begun or has been completed, you should cancel installation or un-install the SOFTWARE, as the case may be. Furthermore, you should promptly return the SOFTWARE to the place of business from which you obtained it in accordance with any return policies of such place of business. Return policies may vary among resellers; therefore you must comply with the return policies of your supplier as you agreed at the point of purchase. If the place of business from which you purchased the SOFTWARE does not honor a full refund for a period of thirty (30) days from the date of purchase, you may then return the SOFTWARE directly to C1 for a refund provided that such returns is authorized within the same thirty (30) days time period. To return the product directly to C1, you must first obtain a Return Authorization Number by contacting C1, and you must forward to C1 all items purchased, including the proof of purchase. The return must be postage-prepaid, and post-marked within thirty (30) days from the proof of purchase, time being of the essence. The return option to C1 is only available to the original purchaser of an unopened factory packaged item. II. YOUR LICENSE TO DEVELOP AND TO DISTRIBUTE. As provided in more detail below, this EULA grants you two licenses: 1) a license to use the SOFTWARE to develop other software products (the "Development License"); and 2) a license to use and/or distribute the Developed Software (the "Distribution License"). These licenses (individually and collectively, the "Licenses") are explained and defined in more detail below. 1. Definitions. The following terms have the respective meanings as used in this EULA: "Network Server" means a computer with one or more computer central processing units (CPU's) that operates for the purpose of serving other computers logically or physically connected to it, including, but not limited to, other computers connected to it on an internal network, intranet or the Internet. "Web Server" means a type of Network Server that serves other computers which, are specifically connected to it through either an intranet or the Internet. "Developed Software" means those computer software products that are developed by or through the use of the SOFTWARE. "Developed Web Server Software" means those Developed Software products that reside logically or physically on at least one Web Server and are operated (meaning the computer software instruction set is carried out) by the Web Server's central processing unit(s) (CPU). "Redistributable Files" means the SOFTWARE files or other portions of the SOFTWARE that are provided by C1 and are identified as such in the Documentation for distribution by you with the Developed Software. "Developer" means a human being or any other automated device using the SOFTWARE in accordance with the terms and conditions of this EULA. "Developer Seat License" means that each Developer using or otherwise accessing the programmatic interface or the SOFTWARE must obtain the right to do so by purchasing a separate End User License. Source Code shall mean computer software code or programs in human readable format, such as a printed listing of such a program written in a high-level computer language. The term "Source Code"

4 Welcome to ComponentOne Input for .NET (2.0)

includes, but is not limited to, documents and materials in support of the development effort of the SOFTWARE, such as flow charts, pseudo code and program notes. 2. Your Development License. You are hereby granted a limited, royalty-free, non-exclusive right to use the SOFTWARE to design, develop, and test Developed Software, on the express condition that, and only for so long as, you fully comply with all terms and conditions of this EULA. The SOFTWARE is licensed to you on a Developer Seat License basis. Developer Seat License basis means that you may perform an installation of the SOFTWARE for use in designing, testing and creating Developed Software by a single Developer on one or more computers, each with a single set of input devices, so long as 1) such computer/computers is/are used only by one single Developer at any given time and not concurrently and, 2) the user is the primary User to whom the license has been granted. Conversely, you may not install or use the SOFTWARE on a computer that is a network server or a computer at which the SOFTWARE is used by more than one Developer. You may not network the SOFTWARE or any component part of it, where it is or may be used by more than one Developer unless you purchase an additional Development License for each Developer. You must purchase another separate license to the SOFTWARE in order to add additional developer seats, whether the additional developers are accessing the SOFTWARE in a stand-alone environment or on a computer network. The license rights granted under this Agreement may be limited to a specified number of days after you first install the SOFTWARE unless you supply information required to license or activate your licensed copy, as the case may be, within the time and the manner described during the SOFTWARE setup sequence and/or in the dialog boxes appearing during use of the SOFTWARE. You may need to activate the SOFTWARE through the use of the Internet, email or telephone; toll charges may apply. You may need to re-activate the SOFTWARE if you modify your computer hardware or if you have installed it on a different computer; in some cases the number of activations allowed may be limited and you will have to contact C1 for clearance. Product activation is based on the exchange of information between your computer and C1. None of this information contains personally identifiable information nor can they be used to identify any personal information about you or any information you store in your computer. YOU ACKNOWLEDGE AND UNDERSTAND THAT THERE ARE TECHNOLOGICAL MEASURES IN THE SOFTWARE THAT ARE DESIGNED TO PREVENT UNLICENSED OR ILLEGAL USE OF THE SOFTWARE. YOU AGREE THAT C1 MAY USE SUCH MEASURES AND YOU AGREE TO FOLLOW ANY REQUIREMENTS REGARDING SUCH TECHNOLOGICAL MEASURES. YOU ACKNOWLEDGE AND AGREE THAT THE SOFTWARE WILL CEASE TO FUNCTION UNLESS AND UNTIL YOU ACTIVATE THE APPLICABLE SOFTWARE SERIAL NUMBER. You agree that C1 may audit your use of the SOFTWARE for compliance with these terms at any time, upon reasonable notice. In the event that such audit reveals any use of the SOFTWARE other than in full compliance with the terms of this EULA, you shall reimburse C1 for all reasonable expenses related to such audit in addition to any other liabilities you may incur as a result of such non-compliance. In all cases, (a) you may not use C1's name, logo, or trademarks to market your Developed Software without the express written consent of C1; (b) you must include the following C1 copyright notice in your Developed Software documentation and/or in the "About Box" of your Developed Software, and wherever the copyright/rights notice is located in the Developed Software (Portions Copyright ComponentOne, LLC 1991-2006. All Rights Reserved.); (c) you agree to indemnify, hold harmless, and defend C1, its suppliers and resellers, from and against any claims or lawsuits, including attorney's fees that may arise from the use or distribution of your Developed Software; (d) you may use the SOFTWARE only to create Developed Software that is significantly different than the SOFTWARE. 3. Your Distribution License. License to Distribute Developed Software. Subject to the terms and conditions in this EULA, you are granted the license to use and to distribute Developed Software on a royalty-free basis, provided that the Developed Software incorporates the SOFTWARE as an integral part of the Developed Software in machine-language compiled format (customarily an ".exe", or ".dll", etc.). You may not distribute, bundle, wrap or subclass the SOFTWARE as Developed Software which, when used in a "designtime" development environment, exposes the programmatic interface of the SOFTWARE. You may distribute,

END-USER LICENSE AGREEMENT FOR COMPONENTONE SOFTWARE 5

on a royalty-free basis, Redistributable Files with Developed Software only. You may not add or transfer the SOFTWARE serial number to the computer where the Developed Software is installed. Users of the Developed Software may not use the SOFTWARE or the Redistributable Files, directly or indirectly, for development purposes. In particular, if you create a control (or user control) using the SOFTWARE as a constituent control, you are not licensed to distribute the control you created with the SOFTWARE to users for development purposes. 4. Specific Product Limitations. Notwithstanding anything in this EULA to the contrary, if the license you have purchased is for any of the following products, then the following additional limitations will apply: a. ComponentOne Reports for .NET Designer Edition. ComponentOne Reports for .NET Designer Edition includes at least: 1) one dynamic link library file (c1.win.c1reportdesigner.dll) known as C1ReportDesigner Component, 2) one executable file (ReportDesigner.exe) known as C1ReportDesigner Application and, 3) the Source Code of the C1ReportDesigner Application. The C1ReportDesigner Component is subject to the general terms and restrictions set forth in this EULA. The C1ReportDesigner Application is an executable file used to design and prepare reports; the C1ReportDesigner Application may be distributed, free of royalties, only in conjunction with the Developed Software. C1 hereby also grants you the right to use and to modify the C1ReportDesigner Application Source Code to create derivative works that are based on the licensed Source Code. You may distribute such derivative works, solely in object code format and exclusively in conjunction with and/or as a part of the Developed Software. You are expressly not granted the right to distribute, disclose or otherwise make available to any third party the licensed Source Code, any portion, modified version or derivative work thereof, in source code format. C1 shall retain all right, title and interest in and to the licensed Source Code, and all C1 updates, modifications or enhancements thereof. Nothing herein shall be deemed to transfer any ownership or title rights in and to the licensed Source Code from C1 to you. SOURCE CODE IS LICENSED TO YOU AS IS. C1 DOES NOT AND SHALL NOT PROVIDE YOU WITH ANY TECHNICAL SUPPORT FOR YOUR SOURCE CODE LICENSE. b. VSView Reporting Edition (ActiveX). VSView Reporting Edition includes at least one executable file listed as VSRptX.exe (where X indicates the version number i.e.7,8, etc.), known as Designer. The file "VSRptX.exe, or any upgrade or future versions of the Designer, are subject to the restrictions set forth in this EULA and may not be distributed with your Developed Software or in any other way. c. Studio Products. You may not share the component parts of the Studio Products licensed to you with other Developers, nor may you allow the use and/or installation of such components by other Developers. 5. Updates/Upgrades; Studio Subscription. Subject to the terms and conditions of this EULA, the Licenses are perpetual. Updates and upgrades to the SOFTWARE may be provided by C1 from time-to-time, and, if so provided by C1, are provided upon the terms and conditions offered at that time by C1 in its sole discretion. C1 may provide updates and upgrades to the SOFTWARE for free or for any charge, at any time or never, and through its chosen manner of access and distribution, all in C1's sole discretion. C1 licenses certain of its separately-licensed products bundled together in a product suite, called the C1 "Studio" product line (the "Studio Products"). The exact separately-licensed products that are bundled into the Studio Products may change from time-to-time in C1's sole discretion. If the SOFTWARE is identified as a C1 "Studio" product, then the SOFTWARE is one of the Studio Products. The SOFTWARE and the Studio Products are revised from time-to-time (meaning, for example, revised with updates, upgrades and, in the case of Studio products, some times changes to the mix of products included in the bundle). To receive any such revisions to the SOFTWARE or the Studio Products, as the case may be, you must have a valid SOFTWARE license or a valid Studio subscription. Together with the Licenses, the original purchaser is granted a one-year subscription from the date of purchase. Upon expiration, you must renew your license subscription to continue to be entitled to receive SOFTWARE and/or the Studio Products revisions as the case may be. 6. Serial Number. With your license, you will be issued a unique serial number (the "Serial Number") used for the activation of the SOFTWARE. The Serial Number is subject to the restrictions set forth in this

6 Welcome to ComponentOne Input for .NET (2.0)

EULA and may not be disclosed or distributed either with your Developed Software or in any other way. The disclosure or distribution of the Serial Number constitutes a breach of this EULA, the effect of which shall be the immediate termination and revocation of all the rights granted herein. 7. Evaluation Copy. If you are using an "evaluation copy", specifically designated as such by C1 on its website or elsewhere, then the Licenses are limited as follows: a) you are granted a license to use the SOFTWARE for a period of thirty (30) days counted from the day of installation (the "Evaluation Period"); b) upon completion of the Evaluation Period, you shall either i) delete the SOFTWARE from the computer containing the installation, or you may ii) obtain a paid license of the SOFTWARE from C1 or any of its resellers; and c) any Developed Software developed with the Evaluation Copy may not be distributed or used for any commercial purpose. III. INTELLECTUAL PROPERTY. 1. Copyright. You agree that all right, title, and interest in and to the SOFTWARE (including, but not limited to, any images, photographs, animations, video, audio, music, text, and applets incorporated into the SOFTWARE), and any copies of the SOFTWARE, and any copyrights and other intellectual properties therein or related thereto are owned exclusively by C1, except to the limited extent that C1 may be the rightful license holder of certain third-party technologies incorporated into the SOFTWARE. The SOFTWARE is protected by copyright laws and international treaty provisions. The SOFTWARE is licensed to you, not sold to you. C1 reserves all rights not otherwise expressly and specifically granted to you in this EULA. 2. Backups. You may make a copy of the SOFTWARE solely for backup or archival purposes. Notwithstanding the foregoing, you may not copy the printed Documentation. 3. General Limitations. You may not reverse engineer, decompile, or disassemble the SOFTWARE, except and only to the extent that applicable law expressly permits such activity notwithstanding this limitation. 4. Software Transfers. You may not rent or lease the SOFTWARE. You may permanently transfer all of your rights under the EULA, provided that you retain no copies, that you transfer all the SOFTWARE (including all component parts, the media and printed materials, any updates, upgrades, this EULA and, if applicable, the Certificate of Authenticity), and that the transferee agrees to be bound by the terms of this EULA. If the SOFTWARE is an update or upgrade, any transfer must include all prior versions of the SOFTWARE. 5. Termination. Without prejudice to any other rights it may have, C1 may terminate this EULA and the Licenses if you fail to comply with the terms and conditions contained herein. In such an event, you must destroy all copies of the SOFTWARE and all of its component parts. 6. Export Restrictions. You acknowledge that the SOFTWARE is of U.S. origin. You acknowledge that the license and distribution of the SOFTWARE is subject to the export control laws and regulations of the United States of America, and any amendments thereof, which restrict exports and re-exports of software, technical data, and direct products of technical data, including services and Developed Software. You agree that you will not export or re-export the SOFTWARE or any Developed Software, or any information, documentation and/or printed materials related thereto, directly or indirectly, without first obtaining permission to do so as required from the United States of America Department of Commerce's Bureau of Industry and Security ("BIS"), or other appropriate governmental agencies, to any countries, end-users, or for any end-uses that are restricted by U.S. export laws and regulations, and any amendments thereof, which include, but are not limited to: Restricted Countries, Restricted End-Users, and Restricted End-Uses. These restrictions change from time to time. You represent and warrant that neither the BIS nor any other United States federal agency has suspended, revoked or denied your export privileges. C1 acknowledges that it shall use reasonable efforts to supply you with all reasonably necessary information regarding the SOFTWARE and its business to enable you to fully comply with the provisions of this Section. If you have any questions regarding your obligations under United States of America export regulations, you should contact the Bureau of Industry and Security, United States Department of Commerce, Exporter Counseling Division, Washington DC. U.S.A. (202) 482-4811, http://www.bis.doc.gov.

END-USER LICENSE AGREEMENT FOR COMPONENTONE SOFTWARE 7

7. U.S. Government Restricted Rights. The SOFTWARE and documentation are provided with RESTRICTED RIGHTS. You will comply with any requirements of the Government to obtain such RESTRICTED RIGHTS protection, including without limitation, the placement of any restrictive legends on the SOFTWARE, and any license agreement used in connection with the distribution of the SOFTWARE. Manufacturer is ComponentOne, LLC, 201 South Highland Avenue , 3rd Floor, Pittsburgh, Pennsylvania 15206 USA. For solicitations issued by the Government on or after December 1, 1995 and the Department of Defense on or after September 29, 1995, the only rights provided in the software and documentation provided herein shall be those contained in this EULA. Under no circumstances shall C1 be obligated to comply with any Governmental requirements regarding the submission of or the request for exemption from submission of cost or pricing data or cost accounting requirements. For any distribution of the SOFTWARE that would require compliance by C1 with the Government's requirements relating to cost or pricing data or cost accounting requirements, you must obtain an appropriate waiver or exemption from such requirements for the benefit of C1 from the appropriate Government authority before the distribution and/or license of the SOFTWARE to the Government. IV. WARRANTIES AND REMEDIES. 1. Limited Warranty. C1 warrants that the original media, if any, are free from defects for ninety (90) days from the date of delivery of the SOFTWARE. C1 also warrants that: (i) it has the full power to enter into this Agreement and grant the license rights set forth herein; (ii) it has not granted and will not grant any rights in the Software to any third party which grant is inconsistent with the rights granted to you in this Agreement; and (iii) the Software does not and will not infringe any trade secret, copyright, trademark or other proprietary right held by any third party and does not infringe any patent held by any third party. EXCEPT AS OTHERWISE PROVIDED IN THE PRECEDING SENTENCE, AND TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW, C1 EXPRESSLY DISCLAIMS ANY WARRANTY FOR THE SOFTWARE, DOCUMENTATION AND ANYTHING ELSE PROVIDED BY C1 HEREBY AND C1 PROVIDES THE SAME IN AS IS CONDITION WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK ARISING OUT OF USE OR PERFORMANCE OF THE SOFTWARE AND DOCUMENTATION REMAINS WITH YOU. THIS LIMITED WARRANTY GIVES YOU SPECIFIC LEGAL RIGHTS. YOU MAY HAVE OTHERS WHICH VARY FROM STATE TO STATE. 2. Limited Remedy. C1 PROVIDES NO REMEDIES OR WARRANTIES, WHETHER EXPRESS OR IMPLIED, FOR ANY SAMPLE APPLICATION CODE, REDISTRIBUTABLE FILES, TRIAL VERSION AND THE NOT FOR RESALE VERSION OF THE SOFTWARE. ANY SAMPLE APPLICATION CODE, TRIAL VERSION AND THE NOT FOR RESALE VERSION OF THE SOFTWARE ARE PROVIDED AS IS. C1's entire liability and your exclusive remedy under this EULA shall be, at C1's sole option, either (a) return of the price paid for the SOFTWARE; (b) repair the SOFTWARE through updates distributed online or otherwise in C1's discretion; or (c) replace the SOFTWARE with SOFTWARE that substantially performs as described in the SOFTWARE documentation, provided that you return the SOFTWARE in the same manner as provided in Section I.2 for return of the SOFTWARE for nonacceptance of this EULA. Any media for any repaired or replacement SOFTWARE will be warranted for the remainder of the original warranty period or thirty (30) days, whichever is longer. THESE REMEDIES ARE NOT AVAILABLE OUTSIDE OF THE UNITED STATES OF AMERICA. TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW, IN NO EVENT SHALL C1 BE LIABLE FOR ANY DAMAGES WHATSOEVER (INCLUDING, WITHOUT LIMITATION, DAMAGES FOR LOSS OF BUSINESS PROFIT, BUSINESS INTERRUPTION, LOSS OF BUSINESS INFORMATION, OR ANY OTHER PECUNIARY LOSS) ARISING OUT OF THE USE OR INABILITY TO USE THE SOFTWARE, EVEN IF C1 HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. BECAUSE SOME STATES/JURISDICTIONS DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES IN CERTAIN CASES, THE ABOVE LIMITATION MAY NOT APPLY TO YOU.

8 Welcome to ComponentOne Input for .NET (2.0)

V. MISCELLANEOUS. 1. This is the Entire Agreement. This EULA (including any addendum to this EULA included with the SOFTWARE) is the final, complete and exclusive statement of the entire agreement between you and C1 relating to the SOFTWARE. This EULA supersedes any prior and contemporaneous proposals, purchase orders, advertisements, and all other communications in relation to the subject matter of this EULA, whether oral or written. No terms or conditions, other than those contained herein, and no other understanding or agreement which in any way modifies these terms and conditions, shall be binding upon the parties unless entered into in writing executed between the parties, or by other non-oral manner of agreement whereby the parties objectively and definitively act in a manner to be bound (such as by continuing with an installation of the SOFTWARE, etc.). Employees, agents and other representatives of C1 are not permitted to orally modify this EULA. 2. You Indemnify C1. You agree to indemnify, hold harmless, and defend C1 and its suppliers and resellers from and against any and all claims or lawsuits, including attorney's fees, which arise out of or result from your distribution of your Developed Software, your Developed Web Server Software or from your breach of any of the terms and conditions of this EULA. 3. Interpretation of this EULA. If for any reason a court of competent jurisdiction finds any provision of this EULA, or any portion thereof, to be unenforceable, that provision of this EULA will be enforced to the maximum extent permissible so as to effect the intent of the parties, and the remainder of this EULA will continue in full force and effect. Formatives of defined terms shall have the same meaning of the defined term. Failure by either party to enforce any provision of this EULA will not be deemed a waiver of future enforcement of that or any other provision. Except as otherwise required or superseded by law, this EULA is governed by the laws of the Commonwealth of Pennsylvania, without regard to its conflict of laws principles. The parties consent to the personal jurisdiction and venue of the Commonwealth of Pennsylvania, in the County of Allegheny, and agree that any legal proceedings arising out of this EULA shall be conducted solely in such Commonwealth. If the SOFTWARE was acquired outside the United States, then local law may apply.

Licensing FAQs
This section describes the main technical aspects of licensing. It may help the user to understand and resolve licensing problems he may experience when using ComponentOne .NET and ASP.NET products.

What is Licensing?
Licensing is a mechanism used to protect intellectual property by ensuring that users are authorized to use software products. Licensing is not only used to prevent illegal distribution of software products. Many software vendors, including ComponentOne, use licensing to allow potential users to test products before they decide to purchase them. Without licensing, this type of distribution would not be practical for the vendor or convenient for the user. Vendors would either have to distribute evaluation software with limited functionality, or shift the burden of managing software licenses to customers, who could easily forget that the software being used is an evaluation version and has not been purchased.

How does Licensing Work?


ComponentOne uses a licensing model based on the standard set by Microsoft, which works with all types of components. Note: The Compact Framework components use a slightly different mechanism for run-time licensing than the other ComponentOne components due to platform differences.

Licensing FAQs 9

When a user decides to purchase a product, he receives an installation program and a Serial Number. During the installation process, the user is prompted for the serial number that is saved on the system. (Users can also enter the serial number by clicking the License button on the About Box of any ComponentOne product, if available, or by rerunning the installation and entering the serial number in the licensing dialog.) When a licensed component is added to a form or Web page, Visual Studio obtains version and licensing information from the newly created component. When queried by Visual Studio, the component looks for licensing information stored in the system and generates a run-time license and version information, which Visual Studio saves in the following two files: An assembly resource file which contains the actual run-time license A "licenses.licx" file that contains the licensed component strong name and version information

These files are automatically added to the project. In winforms and ASP.NET 1.x applications, the run-time license is stored as an embedded resource in the assembly hosting the component or control by Visual Studio. In ASP.NET 2.x applications, the run-time license may also be stored as an embedded resource in the App_Licenses.dll assembly, which is used to store all run-time licenses for all components directly hosted by webforms in the application. Thus, the App_licenses.dll must always be deployed with the application. The licenses.licx file is a simple text file that contains strong names and version information for each of the licensed components used in the application. Whenever Visual Studio is called upon to rebuild the application resources, this file is read and used as a list of components to query for run-time licenses to be embedded in the appropriate assembly resource. Note that editing or adding an appropriate line to this file can force Visual Studio to add run-time licenses of other controls as well. Note that the licenses.licx file is usually not shown in the Solution Explorer; it appears if you press the Show All Files button in the Solution Explorer's toolbox, or from Visual Studio's main menu, select Show All Files on the Project menu. Later, when the component is created at run time, it obtains the run-time license from the appropriate assembly resource that was created at design time and can decide whether to simply accept the run-time license, to throw an exception and fail altogether, or to display some information reminding the user that the software has not been licensed. All ComponentOne products are designed to display licensing information if the product is not licensed. None will throw licensing exceptions and prevent applications from running.

Common Scenarios
The following topics describe some of the licensing scenarios you may encounter.

Creating components at design time


This is the most common scenario and also the simplest: the user adds one or more controls to the form, the licensing information is stored in the licenses.licx file, and the component works. Note that the mechanism is exactly the same for Windows Forms and Web Forms (ASP.NET) projects.

Creating components at run time


This is also a fairly common scenario. You do not need an instance of the component on the form, but would like to create one or more instances at run time. In this case, the project will not contain a licenses.licx file (or the file will not contain an appropriate run-time license for the component) and therefore licensing will fail. To fix this problem, add an instance of the component to a form in the project. This will create the licenses.licx file and things will then work as expected. (The component can be removed from the form after the licenses.licx file has been created).

10 Welcome to ComponentOne Input for .NET (2.0)

Adding an instance of the component to a form, then removing that component, is just a simple way of adding a line with the component strong name to the licenses.licx file. If desired, you can do this manually using notepad or Visual Studio itself by opening the file and adding the text. When Visual Studio recreates the application resources, the component will be queried and its run-time license added to the appropriate assembly resource.

Inheriting from licensed components


If a component that inherits from a licensed component is created, the licensing information to be stored in the form is still needed. This can be done in two ways: Add a LicenseProvider attribute to the component. This will mark the derive component class as licensed. When the component is added to a form, Visual Studio will create and manage the licenses.licx file, and the base class will handle the licensing process as usual. No additional work is needed. For example: [LicenseProvider(typeof(LicenseProvider))] class MyGrid: C1.Win.C1FlexGrid.C1FlexGrid { // ... } Add an instance of the base component to the form. This will embed the licensing information into the licenses.licx file as in the previous scenario, and the base component will find it and use it. As before, the extra instance can be deleted after the licenses.licx file has been created.

Using licensed components in console applications


When building console applications, there are no forms to add components to, and therefore Visual Studio won't create a licenses.licx file. In these cases, create a temporary Windows Forms application and add all the desired licensed components to a form. Then close the Windows Forms application and copy the licenses.licx file into the console application project. Make sure the licenses.licx file is configured as an embedded resource. To do this, right-click the licenses.licx file in the Solution Explorer window and select Properties. In the property window, set the Build Action property to Embedded Resource.

Using licensed components in Visual C++ applications


There is an issue in VC++ 2003 where the licenses.licx is ignored during the build process; therefore, the licensing information is not included in VC++ applications. To fix this problem, extra steps must be taken to compile the licensing resources and link them to the project. Note the following: 1. 2. 3. 4. Build the C++ project as usual. This should create an exe file and also a licenses.licx file with licensing information in it. Copy the licenses.licx file from the app directory to the target folder (Debug or Release). Copy the C1Lc.exe utility and the licensed dlls to the target folder. (Don't use the standard lc.exe, it has bugs.) Use C1Lc.exe to compile the licenses.licx file. The command line should look like this: c1lc /target:MyApp.exe /complist:licenses.licx /i:C1.Win.C1FlexGrid.dll

Licensing FAQs 11

5.

Link the licenses into the project. To do this, go back to Visual Studio, right-click the project, select properties, and go to the Linker/Command Line option. Enter the following: /ASSEMBLYRESOURCE:Debug\MyApp.exe.licenses Rebuild the executable to include the licensing information in the application.

6.

Troubleshooting
We try very hard to make the licensing mechanism as unobtrusive as possible, but problems may occur for a number of reasons. Below is a description of the most common problems and their solutions.

I have a licensed version of a ComponentOne product but I still get the splash screen when I run my project.
If this happens, there may be a problem with the licenses.licx file in the project. It either doesn't exist, contains wrong information, or is not configured correctly. First, try a full rebuild (Rebuild All from the Visual Studio Build menu). This will usually rebuild the correct licensing resources. If that fails follow these steps: 1. 2. 3. 4. Open the project and go to the Solution Explorer window. Click the Show All Files button on the top of the window. Find the licenses.licx file and open it. If prompted, continue to open the file. Change the version number of each component to the appropriate value. If the component does not appear in the file, obtain the appropriate data from another licenses.licx file or follow the alternate procedure following. Save the file, then close the licenses.licx tab. Rebuild the project using the Rebuild All option (not just Rebuild). Open the project and go to the Solution Explorer window. Click the Show All Files button on the top of the window. Find the licenses.licx file and delete it. Close the project and reopen it. Open the main form and add an instance of each licensed control. Check the Solution Explorer window, there should be a licenses.licx file there. Rebuild the project using the Rebuild All option (not just Rebuild). Open the project and go to the Solution Explorer window. Find the licenses.licx file and right-click it. Select the Rebuild Licenses option (this will rebuild the App_Licenses.licx file). Rebuild the project using the Rebuild All option (not just Rebuild).

5. 6. 1. 2. 3. 4. 5. 6. 7. 1. 2. 3. 4.

Alternatively, follow these steps:

For ASP.NET 2.x applications, follow these steps:

12 Welcome to ComponentOne Input for .NET (2.0)

I have a licensed version of a ComponentOne product on my Web server but the components still behave as unlicensed.
There is no need to install any licenses on machines used as servers and not used for development. The components must be licensed on the development machine, therefore the licensing information will be saved into the executable (exe or dll) when the project is built. After that, the application can be deployed on any machine, including Web servers. For ASP.NET 2.x applications, be sure that the App_Licenses.dll assembly created during development of the application is deployed to the bin application bin directory on the Web server. If your ASP.NET application uses winforms user controls with constituent licensed controls, the runtime license is embedded in the winforms user control assembly. In this case, you must be sure to rebuild and update the user control whenever the licensed embedded controls are updated.

I downloaded a new build of a component that I have purchased, and now I'm getting the splash screen when I build my projects.
Make sure that the serial number is still valid. If you licensed the component over a year ago, your subscription may have expired. In this case, you have two options: Option 1 - Renew your subscription to get a new serial number. If you choose this option, you will receive a new serial number that you can use to license the new components (from the installation utility or directly from the About Box). The new subscription will entitle you to a full year of upgrades and to download the latest maintenance builds directly from http://prerelease.componentone.com/. Option 2 Continue to use the components you have. Subscriptions expire, products do not. You can continue to use the components you received or downloaded while your subscription was valid.

Technical Support
ComponentOne Studio Enterprise is developed and supported by ComponentOne LLC, a company formed by the merger of APEX Software Corporation and VideoSoft. ComponentOne offers various support options. For a complete list and a description of each, visit the ComponentOne Web site at http://www.componentone.com/Support. Some methods for obtaining technical support include: Online Support via HelpCentral ComponentOne HelpCentral provides customers with a comprehensive set of technical resources in the form of FAQs, samples, TechTips, Version Release History, Articles, searchable Knowledge Base, searchable Online Help and more. We recommend this as the first place to look for answers to your technical questions. Online Support via our Incident Submission Form This online support service provides you with direct access to our Technical Support staff via an online incident submission form. When you submit an incident, you'll immediately receive a response via e-mail confirming that you've successfully created an incident. This email will provide you with an Issue Reference ID and will provide you with a set of possible answers to your question from our Knowledgebase. You will receive a response from one of the ComponentOne staff members via e-mail in 2 business days or less.

Redistributable Files 13

Peer-to-Peer Product Forums and Newsgroups ComponentOne peer-to-peer product forums and newsgroups are available to exchange information, tips, and techniques regarding ComponentOne products. ComponentOne sponsors these areas as a forum for users to share information. While ComponentOne does not provide direct support in the forums and newsgroups, we periodically monitor them to ensure accuracy of information and provide comments when appropriate. Please note that a ComponentOne User Account is required to participate in the ComponentOne Product Forums.

Installation Issues Registered users can obtain help with problems installing ComponentOne products. Contact technical support by using the online incident submission form or by phone (412.681.4738). Please note that this does not include issues related to distributing a product to end-users in an application.

Documentation ComponentOne documentation is available with each of our products in HTML Help, Microsoft Help 2.0 (.NET, ASP.NET and Mobile Device products only), and PDF format. All of the PDFs are also available on HelpCentral. If you have suggestions on how we can improve our documentation, please email the Documentation team. Please note that e-mail sent to the Documentation team is for documentation feedback only. Technical Support and Sales issues should be sent directly to their respective departments. Note: You must create a ComponentOne Account and register your product with a valid serial number to obtain support using some of the above methods.

Redistributable Files
ComponentOne Input for .NET is developed and published by ComponentOne LLC. You may use it to develop applications in conjunction with Microsoft Visual Studio or any other programming environment that enables the user to use and integrate the control(s). You may also distribute, free of royalties, the following Redistributable Files with any such application you develop to the extent that they are used separately on a single CPU on the client/workstation side of the network: C1.Win.C1Input.2.dll Site licenses are available for groups of multiple developers. Please contact Sales@ComponentOne.com for details.

Namespaces
Namespaces organize the objects defined in an assembly. Assemblies can contain multiple namespaces, which can in turn contain other namespaces. Namespaces prevent ambiguity and simplify references when using large groups of objects such as class libraries. The namespace for the C1Input controls: C1.Win.C1Input The following code fragment shows how to declare a C1TextBox control, for example, using the fully qualified name for this class: Visual Basic Dim textbox As C1.Win.C1Input.C1TextBox C# C1.Win.C1Input.C1TextBox textbox; Delphi textbox: C1.Win.C1Input.C1TextBox;

14 Welcome to ComponentOne Input for .NET (2.0)

Namespaces address a problem sometimes known as namespace pollution, in which the developer of a class library is hampered by the use of similar names in another library. These conflicts with existing components are sometimes called name collisions. For example, if you create a new class named FormatInfo, you can use it inside the project without qualification. However, the C1Input assembly also implements a class called FormatInfo. So, to use the FormatInfo class in the same project, a fully qualified reference must be used to make the reference unique. If the reference is not unique, Visual Studio .NET produces an error stating that the name is ambiguous. Fully qualified names are object references that are prefixed with the name of the namespace where the object is defined. Objects defined in other projects can be used if a reference to the class is created (by choosing Add Reference from the Project menu) and then the fully qualified name for the object can be used in the code. Fully qualified names prevent naming conflicts because the compiler can always determine which object is being used. However, the names themselves can get long and cumbersome. To get around this, use the Imports statement (using in C#, uses in Delphi) to define an alias an abbreviated name that can be used in place of a fully qualified name. For example, the following code snippet creates aliases for two fully qualified names, and uses these aliases to define two objects: Visual Basic Imports C1FormatInfo = C1.Win.C1Input.FormatInfo Imports MyFormatInfo = MyProject.FormatInfo Dim fi1 As C1FormatInfo Dim fi2 As MyFormatInfo C# using C1FormatInfo = C1.Win.C1Input.FormatInfo; using MyFormatInfo = MyProject.FormatInfo; C1FormatInfo fi1; MyFormatInfo fi2; Delphi uses C1.Win.C1Input, MyProject; type TC1FormatInfo = C1.Win.C1Input.FormatInfo; TMyFormatInfo = MyProject.FormatInfo; var fi1: TC1FormatInfo; fi2: TMyFormatInfo; If the Imports statement is used without an alias, all the names in that namespace can be used without qualification provided they are unique to the project. As a warning, unless specified explicitly in code, it is taken for granted that the statement has been specified. This applies only to small code samples. Tutorials and other longer samples will specify complete qualifiers. Visual Basic Imports C1.Win.C1Input C# using C1.Win.C1Input; Delphi uses C1.Win.C1Input;

Creating a .NET 2.0 Project 15

Creating a .NET 2.0 Project


To create a new .NET project, complete the following steps: 1. 2. From the File menu in Microsoft Visual Studio .NET, select New and click Project. The New Project dialog box opens. Under Project Types, choose either Visual Basic Projects or Visual C# Projects, and select Windows Application from the list of Templates in the right pane.

3.

Enter or browse for a location for your application in the Location field and click OK. A new Microsoft Visual Studio .NET project is created in the specified location. In addition, a new Form1 is displayed in the Designer view.

4.

Double-click the desired C1Input components from the Toolbox to add them to Form1. For information on adding a component to the Toolbox, see Adding the C1Input Components to a Project (page 16).

16 Welcome to ComponentOne Input for .NET (2.0)

Adding the C1Input Components to a Project


When you install ComponentOne Studio for .NET 2.0, the Create a ComponentOne Visual Studio 2005 Toolbox Tab checkbox is checked, by default, in the installation wizard. When you open Visual Studio 2005, you will notice a ComponentOne Studio for .NET 2.0 tab containing the ComponentOne controls has automatically been added to the Toolbox. If you decide to uncheck the Create a ComponentOne Visual Studio 2005 Toolbox Tab checkbox during installation, you can manually add ComponentOne controls to the Toolbox at a later time. ComponentOne Input for .NET provides the following controls: C1DateEdit C1DbNavigator C1DropDownControl C1Label C1NumericEdit C1PictureBox C1TextBox

To use C1Input, add these controls to the form or add a reference to the C1.Win.C1Input assembly to your project. Manually Adding C1Input to the Toolbox When you install C1Input, the following C1Input components will appear in the Visual Studio Toolbox customization dialog box: C1DateEdit C1DbNavigator C1DropDownControl

Adding the C1Input Components to a Project 17

1. 2.

C1Label C1NumericEdit C1PictureBox C1TextBox Open the Visual Studio IDE (Microsoft Development Environment). Make sure the Toolbox is visible (select Toolbox in the View menu, if necessary) and right-click the toolbox to open its context menu. To make C1Input component appear on its own tab in the Toolbox, select Add Tab from the context menu and type in the tab name, C1Input, for example.

To manually add the C1Input controls to the Visual Studio Toolbox:

3. 4.

Right-click the tab where the component is to appear and select Choose Items from the context menu. The Choose Toolbox Items dialog box opens. In the dialog box, select the .NET Framework Components tab. Sort the list by Namespace (click the Namespace column header) and check the check boxes for all components belonging to namespace C1.Win.C1Input. Note that there may be more than one component for each namespace.

18 Welcome to ComponentOne Input for .NET (2.0)

Adding C1Input to the Form To add C1Input to a form: 1. 2. Add it to the Visual Studio toolbox. Double-click the control or drag it onto your form.

Adding a Reference to the Assembly To add a reference to the C1Input assembly: 1. 2. 3. Select the Add Reference option from the Project menu of your project. Select the ComponentOne Input assembly from the list on the .NET tab or browse to find the C1.Win.C1Input.2.dll file and click OK. Double-click the form caption area to open the code window. At the top of the file, add the following Imports statements (using in C#; uses in Delphi): Imports C1.Win.C1Input Note: This makes the objects defined in the C1Input assembly visible to the project. See Namespaces (page 13) for more information.

Migrating a C1Input Project to Visual Studio 2005


To migrate a project using ComponentOne components to Visual Studio 2005, there are two main steps that must be performed. First, you must convert your project to Visual Studio 2005, which includes removing any references to a previous assembly and adding a reference to the new assembly. Secondly, the .licx file, or licensing file, must be updated in order for the project to run correctly.

Migrating a C1Input Project to Visual Studio 2005 19

To convert the project: 1. 2. Open Visual Studio 2005 and select File | Open | Project/Solution. Locate the .sln file for the project that you wish to convert to Visual Studio 2005. Select it and click Open. The Visual Studio Conversion Wizard appears.

3. 4.

Click Next. Select Yes, create a backup before converting to create a backup of your current project and click Next.

20 Welcome to ComponentOne Input for .NET (2.0)

5. 6.

Click Finish to convert your project to Visual Studio 2005. The Conversion Complete window appears. Click Show the conversion log when the wizard is closed if you want to view the conversion log.

Migrating a C1Input Project to Visual Studio 2005 21

7. 8.

Click Close. The project opens. Now you must remove references to any of the previous ComponentOne .dlls and add references to the new ones. Go to the Solution Explorer (View | Solution Explorer), select the project, and click the Show All Files button. Note: The Show All Files button does not appear in the Solution Explorer toolbar if the Solution project node is selected.

9.

Expand the References node, right-click C1.Common and select Remove. Also remove C1.Win.C1Input the same way.

22 Welcome to ComponentOne Input for .NET (2.0)

10. Right-click the References node and select Add Reference. 11. Locate and select C1.Win.C1Input.2.dll. Click OK to add it to the project. Add C1.Common.2 the same way. To update the .licx file: 1. In the Solution Explorer, right-click the licenses.licx file and select Delete.

2. 3. 4.

Click OK to permanently delete licenses.licx. The project must be rebuilt to create a new, updated version of the .licx file. Click the Start Debugging button to compile and run the project. The new .licx file may not be visible in the Solution Explorer. Select File | Close to close the form and then double-click the Form.vb or Form.cs file in the Solution Explorer to reopen it. The new licenses.licx file appears in the list of files.

Migrating a C1Input Project to Visual Studio 2005 23

The migration process is complete.

Differences from the .NET 1.x Version 25

Overview
C1Input is a set of .NET controls designed to allow developers access to a toolbar of enhanced visual components and help developers display dynamic data in a visual format, manage dataset navigation, display or edit dates, and much more. Using the latest technologies built into Visual Studio .NET, C1Input completely manages the underlying complexities of a visual programming component, allowing developers to concentrate on important application-specific tasks. Programmers can use C1Input to create a fully functional data bound application, which is fully user interactive. Professional developers can use the many different controls to accurately display complex sets of data and create user-friendly applications.

Differences from the .NET 1.x Version


Please note that some changes in this version are not compatible with the 1.x versions and may require (minimal) changes to the source code. C1Input 2.x does not reference or need the C1Common assembly. Flag properties, such as FormatInfo, MaskInfo, PreValidatation, and PostValidation, do not show the Inherit flags at design time since those flags are set automatically. Most complex properties can now be reset to the default value in the designer. The CopyWithLiterals property was removed from C1TextBox as it is duplicated in MaskInfo. The AllowDbNull property was removed from C1TextBox and is only available as a sub-property of the PostValidation property. C1DropDownControl now allows the option to specify custom images for its buttons via the new ButtonImages Properties (page 112).

C1Input Controls 27

Using the C1Input Controls


The following sections describe various aspects of using C1Input controls.

C1Input Controls
The current version of C1Input contains six controls: C1TextBox The main data bound control used for entering and editing information of any data type in a text form. Supports data formatting, edit mask, data validation and other features. C1TextBox also supports formatted and masked editing of all data types, including special features for date-time formats. Apart from being the main data editor control, C1TextBox also serves as the base class for specialized controls such as C1NumericEdit and C1DateEdit. C1TextBox derives from the standard System.Windows.Forms.TextBox control. Data bound control derived from C1TextBox specialized for editing numeric values. In addition to C1TextBox functionality, C1NumericEdit supports a drop-down calculator and an up-down (spin) button that can be used to increment/decrement the value. Data bound control derived from C1TextBox specialized for editing date and time values. In addition to C1TextBox functionality, C1DateEdit supports a drop-down calendar and an up-down (spin) button for changing the value. Read-only data bound control that displays formatted data. C1Label derives from the standard System.Windows.Forms.Label control. Data bound control which shows picture images stored in a data source field, derives from System.Windows.Forms.PictureBox. Data bound control which provides buttons for convenient navigation over data source rows. It enables movement to the first, last, previous and next row and common data actions such as updating the data source and refreshing data.

C1NumericEdit

C1DateEdit

C1Label C1PictureBox C1DbNavigator

Data Binding
C1Input controls can function both in unbound and in bound mode. In bound mode, a controls Value is bound to a data source field. C1Input controls support data binding to all .NET data sources. This includes ADO.NET data source objects such as DataTable, DataView and DataSet, and also ComponentOne DataObjects components such as C1ExpressTable, C1ExpressView, C1ExpressConnection, C1DataView, C1DataTableSource and C1DataSet. For details about creating ADO.NET data source objects, please refer to the .NET Framework documentation. For details about using ComponentOne DataObjects, see the C1DataObjects documentation included in the ComponentOne Studio Enterprise. ComponentOne DataObjects is a data framework, a part of ComponentOne Studio Enterprise, enhancing ADO.NET in many ways.

28 Using the C1Input Controls

To bind a C1Input control to a data source field, assign the data source object to the control's DataSource property, then assign a field of the data source object to the controls DataField property. You can set the DataSource and DataField properties in code as well as in the designer. At design time, you can select the data source object and its field from the lists of available data sources and their fields provided by the DataSource/DataField property combo boxes. After you bind the control to a data filed, the DataType property is automatically set to the data type of the field it is bound to. In most cases, this setting is what you need. However, sometimes you need different types for the control and the field. For example, you might have a string field containing dates. In such cases, you can set the DataType property after binding and use the BindingFormatting/BindingParsing events to convert data to/from the controls DataType when it is written from/saved to the data source. The DataSource/DataField properties are used to bind the Value property of the control to a data source field. The Value property is the main property of a C1Input control. It holds and returns a value with of a specific data type. In addition, you have the freedom to bind other properties of the control to other data sources and fields, as in any other WinForms control, using the DataBindings property. This functionality is not C1Input-specific; it is supported by the .NET Framework for all controls. Caution: Do not use properties other than the Value property under DataBinding to bind the controls value to a field, use the DataSource and DataField properties instead (or use Value in DataBindings). For example, although it is possible to bind the Text property to a field, the result will not be the same as binding the Value property.

Value and Text: Displaying, Validating, and Updating Values


The Value property is the main property of a C1Input control and is responsible for returning and accepting a value with a specific DataType. When the control is not in EditMode, the Text shown by the control will display its current Value (except when TextDetached property is set to True) in a properly formatted form, see Formatting Data (page 29) for details. If the control is not read-only, it automatically switches to EditMode when it receives input focus, provided that TextDetached property is set to False. Input focus refers to when the input window of the control receives focus. In edit mode, the controls text is edited by the user while the Value remains unchanged until the editing ends. When the user attempts to leave the control, (for instance, move the input focus elsewhere), the Value property is updated with the Text entered by the user. The process of updating the Value involves the following three main actions: Parsing Since the Value property is typed (according to the controls current DataType), the process starts from the action of parsing the Text string, and converting it to the correct DataType. If necessary, the entered text can be validated at this point using string-based validation techniques such as pattern matching and regular expressions, see Validating Data (page 40) for details. Validation Once a typed value is obtained, it passes the PostValidation check, where it can be matched against a list of predefined values, maximum and minimum values and intervals, or validated programmatically in the PostValidating event. After validation, the new value is assigned to the Value property, and then the Value property is updated to the data source. Updating Updating the Value normally occurs when the user tries to move the input focus out of the control or makes a mouse click outside of the control. However, it can also be triggered programmatically, by calling the UpdateValueWithCurrentText method at any time.

Formatting Data 29

Setting the TextDetached property to True (it is False by default) forces the control into a special mode. If TextDetached property is set to True, the link between Value and Text is disabled, changing Value does not update Text, and changing Text does not update Value even when the control loses input focus. The Text property becomes independent of the Value property. This mode is useful when you want full programmatic control over updating the Text and Value.

Formatting Data
C1Input controls support a rich formatting model which enables developers to customize the appearance of a controls text in almost any way imaginable. The main function of formatting is to display a string Text representation of a typed or stored Value. Formatting is controlled by the FormatType property, see Format Types (page 29) for details. Its enumerated values define data will be formatted in the control. Some of the options correspond to .NET standard format specifiers for numeric and date-time types, for example, StandardNumber and LongDate, see "Formatting Types" in the .NET Framework documentation. One FormatType option, CustomFormat, corresponds to the case of a custom format specifier as defined in the .NET Framework documentation, the specifier itself is determined by the CustomFormat property. For example, CustomFormat property is set to "##,###.###" produces numbers with at most five digits before and three digits after decimal point. See Custom format specifiers (page 31) for details. There is also a special FormatType option, UseEvent, which delegates the formatting to the Formatting event. The ability to represent NULL values (System.DBNull) is controlled by the NullText and EmptyAsNull properties. Sometimes you may find it useful to trim leading and/or trailing spaces when showing the formatted value. You can use the TrimStart and TrimEnd properties for that. It is possible to specify two different formats, one for display (when the control is read-only or is not in the edit mode), and another for edit mode, see Value and Text: Displaying, Validating, and Updating Values (page 28) to find more information about edit mode. These two formatting modes are governed by the DisplayFormat and EditFormat properties. By default, both of them inherit from the controls properties. To assign specific FormatType, CustomFormat or other formatting property (see FormatInfo class) for a specific mode, expand the DisplayFormat or EditFormat nodes, and change the (Inherit) flags and set the desired sub-property.

Format Types
By default (FormatType property is set to DefaultFormat), the Text is obtained by applying the standard ToString() method of the current DataType to the typed Value (more exactly, if the type has a type converter, TypeConverter.ToString() is used). This conversion (as all others) uses the regional settings provided by the CultureInfo property. Formatting is controlled by the FormatType property. Its enumerated values define the method of formatting values. Some of the options correspond to standard format specifiers for numeric and date-time types, for example, the StandardNumber and LongDate formats, for more information see "Formatting Types" in the .NET Framework documentation. One option, CustomFormat, corresponds to the case of a custom format specifier as defined in the .NET Framework documentation, the specifier itself is determined by the CustomFormat property. There is also an option delegating formatting to code in an event. The following table describes the list of available options:

Formatting Option DefaultFormat UseEvent

Description Conversion using TypeConverter.ConvertToString(). Conversion performed by user code in the Formatting (or Parsing) event.

30 Using the C1Input Controls

Formatting Option CustomFormat GeneralNumber Currency FixedPoint

Description Formatting uses the string assigned to the CustomFormat property. Parsing uses NumberStyle, DateTimeStyle, and CustomFormat properties. The number is converted to the most compact decimal form, using fixed point or scientific notation. The number is converted to a string that represents a currency amount. The number is converted to a string of the form "-ddd.ddd" where each 'd' indicates a digit (0-9). The string starts with a minus sign if the number is negative. The numeric precision is given by the property NumberFormatInfo.NumberDecimalDigits of the specified culture. The number is converted to a string of the form "-d,ddd,ddd.ddd", where each 'd' indicates a digit (0-9). The string starts with a minus sign if the number is negative. Thousand separators are inserted between each group of three digits to the left of the decimal point. The numeric precision is given by the property NumberFormatInfo.NumberDecimalDigits of the specified culture. The number is converted to a string that represents a percent as defined by the NumberFormatInfo.PercentNegativePattern property or the NumberFormatInfo.PercentPositivePattern property. If the number is negative, the string produced is defined by the PercentNegativePattern and starts with a minus sign. The converted number is multiplied by 100 in order to be presented as a percentage. The default numeric precision given by NumberFormatInfo is used. The number is converted to a string of the form "-d.dddE+ddd" or "d.ddde+ddd", where each 'd' indicates a digit (0-9). The string starts with a minus sign if the number is negative. One digit always precedes the decimal point. The exponent always consists of a plus or minus sign and a minimum of three digits. The exponent is padded with zeros to meet this minimum, if required. The round-trip specifier guarantees that a numeric value converted to a string will be parsed back into the same numeric value. This format is supported by floating-point types only. Displays number as a string that contains the value of the number in Decimal (base 10) format. This format is supported for integral types only. The number is converted to a string of hexadecimal digits. This format is supported for integral types only. Converts to Boolean and shows No for False, Yes for True. Converts to Boolean and shows True or False. Converts to Boolean and shows Off for False, On for True. General date/time pattern (short time). Displays a date according to specified CultureInfo's long date format. Displays a date using the medium date format ("dd-MMM-yy"). Displays a date using specified CultureInfo's short date format. Displays a time using your locale's long time format; includes hours, minutes, seconds.

StandardNumber

Percent

Scientific

RoundTrip

Integer Hexadecimal YesNo TrueFalse OnOff GeneralDate LongDate MediumDate ShortDate LongTime

Formatting Data 31

Formatting Option MediumTime ShortTime LongDateShortTime LongDateLongTime ShortDateShortTime ShortDateLongTime MonthAndDay DateAndTimeGMT DateTimeSortable GMTSortable LongDateTimeGMT YearAndMonth

Description Displays time in 12-hour format using hours and minutes and the AM/PM designator ("hh:mm tt"). Displays a time using the 24-hour format, for example, 17:45. Displays the long date and short time according to specified CultureInfo's format. Displays the long date and long time according to specified CultureInfo's format. Displays the short date and short time according to specified CultureInfo's format. Displays the short date and long time according to specified CultureInfo's format. Displays the month and the day of a date. Formats the date and time as Greenwich Mean Time (GMT). Formats the date and time as a sortable index. Formats the date and time as a GMT sortable index. Formats the date and time with the long date and long time as GMT. Formats the date as the year and month.

Custom Format Specifiers


Setting FormatType to CustomFormat corresponds to the case of a custom format specifier as defined in the .NET Framework documentation, the specifier itself is determined by the CustomFormat property. In the CustomFormat string you define the format desired using special characters for numeric and date-time types as presented in the following tables. For details, see "Custom Numeric Format Strings" and "Date and Time Format Strings" in the .NET Framework documentation.

Numeric Custom Format Specifiers


The following table describes the custom numeric format specifiers:

Format Specifier 0

Name Zero placeholder

Description If the value being formatted has a digit in the position where the '0' appears in the format string, then that digit is copied to the output string. The position of the leftmost '0' before the decimal point and the rightmost '0' after the decimal point determines the range of digits that are always present in the output string. If the value being formatted has a digit in the position where the '#' appears in the format string, then that digit is copied to the output string. Otherwise, nothing is stored in that position in the output string. Note that this specifier never displays the '0' character if it is not a significant digit, even if '0' is the only digit in the string. It will display the '0' character if it is a significant digit in the number being displayed.

Digit placeholder

32 Using the C1Input Controls

Format Specifier .

Name Decimal point

Description The first '.' character in the format string determines the location of the decimal separator in the formatted value; any additional '.' characters are ignored. The actual character used as the decimal separator is determined by the NumberDecimalSeparator property of the NumberFormatInfo object that controls formatting. The ',' character serves two purposes. First, if the format string contains a ',' character between two digit placeholders (0 or #) and to the left of the decimal point if one is present, then the output will have thousand separators inserted between each group of three digits to the left of the decimal separator. The actual character used as the decimal separator in the output string is determined by the NumberGroupSeparator property of the current NumberFormatInfo object that controls formatting. Second, if the format string contains one or more ',' characters immediately to the left of the decimal point, then the number will be divided by the number of ',' characters multiplied by 1000 before it is formatted. For example, the format string '0,,' will represent 100 million as simply 100. Use of the ',' character to indicate scaling does not include thousand separators in the formatted number. Thus, to scale a number by 1 million and insert thousand separators you would use the format string '#,##0,,'.

Thousand separator and number scaling

Percentage placeholder

The presence of a '%' character in a format string causes a number to be multiplied by 100 before it is formatted. The appropriate symbol is inserted in the number itself at the location where the '%' appears in the format string. The percent character used is dependent on the current NumberFormatInfo class. If any of the strings 'E', 'E+', 'E-', 'e', 'e+', or 'e-' are present in the format string and are followed immediately by at least one '0' character, then the number is formatted using scientific notation with an 'E' or 'e' inserted between the number and the exponent. The number of '0' characters following the scientific notation indicator determines the minimum number of digits to output for the exponent. The 'E+' and 'e+' formats indicate that a sign character (plus or minus) should always precede the exponent. The 'E', 'E-', 'e', or 'e-' formats indicate that a sign character should only precede negative exponents. Characters enclosed in single or double quotes are copied to the output string literally, and do not affect formatting. The ';' character is used to separate sections for positive, negative, and zero numbers in the format string. String representation for two Boolean values, True and False separated with |, Strings "True" and "False" can be replaced with any other strings representing the two Boolean values. All other characters are copied to the output string as literals in the position they appear.

E0 E+0 E-0 e0 e+0 e-0 'ABC' "ABC" ; True|False

Scientific notation

Literal string Section separator Boolean format

Other

All other characters

Formatting Data 33

Examples: CustomFormat ##### 00000 (###) ### - #### #.## 0.00 00.00 #,# #,, #,,, #,##0,, #0.##% 0.###E+0 0.###E+000 0.###E-000 [##-##-##] ##;(##) ##;(##) Value 123 123 1234567890 1.2 1.2 1.2 1234567890 1234567890 1234567890 1234567890 0.086 86000 86000 86000 123456 1234 -1234 Output 123 00123 (123) 456 7890 1.2 1.20 01.20 1,234,567,890 1235 1 1,235 8.6% 8.6E+4 8.6E+004 8.6E004 [12-34-56] 1234 (1234)

Date-Time Custom Format Specifiers


The following table describes the custome date-time format specifiers:

Format Specifier d

Description Displays the current day of the month, measured as a number between 1 and 31, inclusive. If the day is a single digit only (1-9), then it is displayed as a single digit. Note that if the 'd' format specifier is used alone, without other custom format strings, it is interpreted as the standard short date pattern format specifier. If the 'd' format specifier is passed with other custom format specifiers, it is interpreted as a custom format specifier.

dd

Displays the current day of the month, measured as a number between 1 and 31, inclusive. If the day is a single digit only (1-9), it is formatted with a preceding 0 (0109). Displays the abbreviated name of the day for the specified DateTime object. If a specific valid format provider (a non-null object that implements IFormatProvider with the expected property) is not supplied, then the AbbreviatedDayNames property of the DateTimeFormat object and its current culture associated with the current thread is used. Otherwise, the AbbreviatedDayNames property from the specified format provider is used.

ddd

34 Using the C1Input Controls

Format Specifier dddd (plus any number of additional "d" characters)

Description Displays the full name of the day for the specified DateTime object. If a specific valid format provider (a non-null object that implements IFormatProvider with the expected property) is not supplied, then the DayNames property of the DateTimeFormat object and its current culture associated with the current thread is used. Otherwise, the DayNames property from the specified format provider is used. Displays seconds fractions represented in one digit. Note that if the 'f' format specifier is used alone, without other custom format strings, it is interpreted as the full (long date + short time) format specifier. If the 'f' format specifier is passed with other custom format specifiers, it is interpreted as a custom format specifier.

ff fff ffff fffff ffffff fffffff g or gg (plus any number of additional "g" characters)

Displays seconds fractions represented in two digits. Displays seconds fractions represented in three digits. Displays seconds fractions represented in four digits. Displays seconds fractions represented in five digits. Displays seconds fractions represented in six digits. Displays seconds fractions represented in seven digits. Displays the era (A.D. for example) for the specified DateTime object. If a specific valid format provider (a non-null object that implements IFormatProvider with the expected property) is not supplied, then the era is determined from the calendar associated with the DateTimeFormat object and its current culture associated with the current thread. Note that if the 'g' format specifier is used alone, without other custom format strings, it is interpreted as the standard general format specifier. If the 'g' format specifier is passed with other custom format specifiers, it is interpreted as a custom format specifier.

Displays the hour for the specified DateTime object in the range 1-12. The hour represents whole hours passed since either midnight (displayed as 12) or noon (also displayed as 12). If this format is used alone, then the same hour before or after noon is indistinguishable. If the hour is a single digit (1-9), it is displayed as a single digit. No rounding occurs when displaying the hour. For example, a DateTime of 5:43 returns 5. Displays the hour for the specified DateTime object in the range 1-12. The hour represents whole hours passed since either midnight (displayed as 12) or noon (also displayed as 12). If this format is used alone, then the same hour before or after noon is indistinguishable. If the hour is a single digit (1-9), it is formatted with a preceding 0 (01-09). Displays the hour for the specified DateTime object in the range 0-23. The hour represents whole hours passed since midnight (displayed as 0). If the hour is a single digit (0-9), it is displayed as a single digit. Displays the hour for the specified DateTime object in the range 0-23. The hour represents whole hours passed since midnight (displayed as 0). If the hour is a single digit (0-9), it is formatted with a preceding 0 (01-09).

hh, hh (plus any number of additional "h" characters)

HH, HH (plus any number of additional "H" characters)

Formatting Data 35

Format Specifier m

Description Displays the minute for the specified DateTime object in the range 0-59. The minute represents whole minutes passed since the last hour. If the minute is a single digit (09), it is displayed as a single digit. Note that if the 'm' format specifier is used alone, without other custom format strings, it is interpreted as the standard month day pattern format specifier. If the 'm' format specifier is passed with other custom format specifiers, it is interpreted as a custom format specifier.

mm, mm (plus any number of additional "m" characters) M

Displays the minute for the specified DateTime object in the range 0-59. The minute represents whole minutes passed since the last hour. If the minute is a single digit (09), it is formatted with a preceding 0 (01-09). Displays the current month, measured as a number between 1 and 12, inclusive. If the month is a single digit (1-9), it is displayed as a single digit. Note that if the 'M' format specifier is used alone, without other custom format strings, it is interpreted as the standard month day pattern format specifier. If the 'M' format specifier is passed with other custom format specifiers, it is interpreted as a custom format specifier.

MM MMM

Displays the current month, measured as a number between 1 and 12, inclusive. If the month is a single digit (1-9), it is formatted with a preceding 0 (01-09). Displays the abbreviated name of the month for the specified DateTime object. If a specific valid format provider (a non-null object that implements IFormatProvider with the expected property) is not supplied, the AbbreviatedMonthNames property of the DateTimeFormat object and its current culture associated with the current thread is used. Otherwise, the AbbreviatedMonthNames property from the specified format provider is used. Displays the full name of the month for the specified DateTime object. If a specific valid format provider (a non-null object that implements IFormatProvider with the expected property) is not supplied, then the MonthNames property of the DateTimeFormat object and its current culture associated with the current thread is used. Otherwise, the MonthNames property from the specified format provider is used. Displays the seconds for the specified DateTime object in the range 0-59. The second represents whole seconds passed since the last minute. If the second is a single digit (0-9), it is displayed as a single digit only. Note that if the 's' format specifier is used alone, without other custom format strings, it is interpreted as the standard sortable date/time pattern format specifier. If the 's' format specifier is passed with other custom format specifiers, it is interpreted as a custom format specifier.

MMMM

ss, ss (plus any number of additional "s" characters)

Displays the seconds for the specified DateTime object in the range 0-59. The second represents whole seconds passed since the last minute. If the second is a single digit (0-9), it is formatted with a preceding 0 (01-09).

36 Using the C1Input Controls

Format Specifier t

Description Displays the first character of the A.M./P.M. designator for the specified DateTime object. If a specific valid format provider (a non-null object that implements IFormatProvider with the expected property) is not supplied, then the AMDesignator (or PMDesignator) property of the DateTimeFormat object and its current culture associated with the current thread is used. Otherwise, the AMDesignator (or PMDesignator) property from the specified IFormatProvider is used. If the total number of whole hours passed for the specified DateTime is less than 12, then the AMDesignator is used. Otherwise, the PMDesignator is used. Note that if the 't' format specifier is used alone, without other custom format strings, it is interpreted as the standard long time pattern format specifier. If the 't' format specifier is passed with other custom format specifiers, it is interpreted as a custom format specifier.

tt, tt (plus any number of additional "t" characters)

Displays the A.M./P.M. designator for the specified DateTime object. If a specific valid format provider (a non-null object that implements IFormatProvider with the expected property) is not supplied, then the AMDesignator (or PMDesignator) property of the DateTimeFormat object and its current culture associated with the current thread is used. Otherwise, the AMDesignator (or PMDesignator) property from the specified IFormatProvider is used. If the total number of whole hours passed for the specified DateTime is less than 12, then the AMDesignator is used. Otherwise, the PMDesignator is used. Displays the year for the specified DateTime object as a maximum two-digit number. The first two digits of the year are omitted. If the year is a single digit (1-9), it is displayed as a single digit. Displays the year for the specified DateTime object as a maximum two-digit number. The first two digits of the year are omitted. If the year is a single digit (1-9), it is formatted with a preceding 0 (01-09). Displays the year for the specified DateTime object, including the century. If the year is less than four digits in length, then preceding zeros are appended as necessary to make the displayed year four digits long. Displays the time zone offset for the system's current time zone in whole hours only. The offset is always displayed with a leading or trailing sign (zero is displayed as '+0'), indicating hours ahead of Greenwich mean time (+) or hours behind Greenwich mean time (-). The range of values is 12 to +13. If the offset is a single digit (0-9), it is displayed as a single digit with the appropriate leading sign. The setting for the time zone is specified as +X or X where X is the offset in hours from GMT. The displayed offset is affected by daylight time. Displays the time zone offset for the system's current time zone in whole hours only. The offset is always displayed with a leading or trailing sign (zero is displayed as '+00'), indicating hours ahead of Greenwich mean time (+) or hours behind Greenwich mean time (-). The range of values is 12 to +13. If the offset is a single digit (0-9), it is formatted with a preceding 0 (01-09) with the appropriate leading sign. The setting for the time zone is specified as +X or X where X is the offset in hours from GMT. The displayed offset is affected by daylight time.

yy

yyyy

zz

Formatting Data 37

Format Specifier zzz, zzz (plus any number of additional "z" characters)

Description Displays the time zone offset for the system's current time zone in hours and minutes. The offset is always displayed with a leading or trailing sign (zero is displayed as '+00:00'), indicating hours ahead of Greenwich mean time (+) or hours behind Greenwich mean time (-). The range of values is 12 to +13. If the offset is a single digit (0-9), it is formatted with a preceding 0 (01-09) with the appropriate leading sign. The setting for the time zone is specified as +X or X where X is the offset in hours from GMT. The displayed offset is affected by daylight time. Time separator. Date separator. Quoted string. Displays the literal value of any string between two quotation marks preceded by the escape character (/). Quoted string. Displays the literal value of any string between two " ' " characters. Where c is a standard format character, displays the standard format pattern associated with the format character. Where c is any character, the escape character displays the next character as a literal. The escape character cannot be used to create an escape sequence (like "\n" for new line) in this context. Section separator. Custom date-time format can contain multiple format strings separated with |, This feature allows to specify multiple input formats for datetime values. Only the first format string is used to format value, convert date-time to string. Performing the inverse conversion (parsing) from string to date-time, a string will be recognized (parsed) if it satisfies one of the allowed formats. Other characters are written directly to the output string as literals.

: / " ' %c \c

Any other character

Examples: Format specifiers d, M d, M d MMMM d MMMM dddd MMMM yy gg dddd MMMM yy gg h , m: s hh,mm:ss HH-mm-ss-tt hh:mm, G\MT z hh:mm, G\MT z hh:mm, G\MT zzz hh:mm, G\MT zzz Current culture en-US es-MX en-US es-MX en-US es-MX En-US En-US En-US En-US En-US En-US En-US Time zone GMT GMT GMT GMT GMT GMT GMT GMT GMT GMT GMT +10:00 GMT GMT 9:00 Output 12, 4 12, 4 12 April 12 Abril Thursday April 01 A.D. Jueves Abril 01 DC 6 , 13: 12 06,13:12 06-13-12-AM 05:13 GMT +0 05:13 GMT +10 05:13 GMT +00:00 05:13 GMT -09:00

38 Using the C1Input Controls

Parsing (Updating) Data


Data modified by the end user in a C1Input control is converted from a string to a typed Value. Converting data from a string representation is called parsing. It is the opposite of formatting. Parsing is controlled by the ParseInfo property. The ParseInfo property provides access to the ParseInfo Class that contains sub-properties that control different aspects of parsing. For the most part, you will probably be satisfied with the default parsing that is performed according to the format specification, as it is the inverse of formatting. By default, the same format property value is used for parsing as for formatting. However, you can change any of aspects of how the control parses, by expanding the ParseInfo property, changing the (Inherit) flags, and setting desired properties. The ParseInfo class also contains two flag properties, NumberStyle and DateTimeStyle, which enable you to fine-tune parsing by allowing or disallowing white spaces and special characters in input strings for numeric and date-time data. For more information see the ParseInfo class in the reference section. By setting the FormatType property to UseEvent, you can make your parsing entirely custom through writing code to handle the parsing action in the Parsing event. Note: Parsing is not performed in DateTimeInput and NumericInput modes. It is unnecessary, because in this case the content is already a typed value (date/time or number), so there is no need to parse a string to obtain the value.

Culture (Regional) Settings


Regional settings affect almost all aspects of C1Input functionality. Formatting, parsing, validating data and performing masked input all depend on cultural settings for string comparison, numeric and date time formats and special characters, such as decimal point character. See description of the CultureInfo class in .NET Framework documentation for details on culture-specific settings. C1Input controls use the following properties to define CultureInfo: Culture property The Culture property defines what culture is used by the control. It is an integer ID with a list of all cultures available at design time. The default is 0 Current Culture, which is the current culture used by the application containing the control. Culture name is available in a read-only property CultureName. CultureInfo property The CultureInfo property contains all the settings, the CultureInfo object corresponding to the specified culture ID. UserCultureOverride property The Boolean UserCultureOverride property allows the culture settings to be overridden by the end user regional settings. You can change any settings in the CultureInfo programmatically. To enable this, C1Input controls fire the CultureInfoSetup event at startup and whenever the Culture property is set. Handling this event you can finetune various CultureInfo settings. For example, you may want to set CultureInfo.DateTimeFormat.FirstDayOfWeek according to your application needs. Another setting affecting most of C1Input functionality is the Boolean CaseSensitive property (although it is not culture-related). Case sensitivity is used in string comparisons. C1Input controls have a CaseSensitive property that defines the default case sensitivity for all operations. You can override this setting in most classes controlling particular functionality, such as ParseInfo, PreValidation, PostValidation, and so on.

Edit Mask 39

Edit Mask
C1Input controls support masked input when you set the EditMask property to a mask string. If you define an edit mask, each character position in the control maps to either a special placeholder or a literal character. Literal characters, or literals, can give visual cues about the type of data being used. For example, the parentheses surrounding the area code of a telephone number and dashes are literals: (412)-123-4567. The edit mask prevents you from entering invalid characters into the control and provides other enhancements of the user interface. To enable masked input, set the EditMask property to a mask string composed of placeholders and literals, see the table of available placeholders below. You can also define your own placeholders, using the CustomPlaceholders collection. Although setting EditMask is enough in simple cases, there is also a MaskInfo property containing subproperties controlling various important aspects of masked input. One of them is the CustomPlaceholders collection mentioned above. Some of the others are:

Property AutoTabWhenFilled PromptChar SaveBlanks SaveLiterals ShowLiterals

Description If True, focus automatically moves to the next control when the mask is filled. Default: False. Character displayed on empty positions. Default: '_'. If True, the stored text includes blank positions as StoredEmptyChar. Default: False. If True (default), the stored text (StoredContent) includes literals. Enumeration controlling the way in which literals appear while the user types. They can appear always, or never, or as the user reaches a literal while typing. If True (default), optional mask positions are automatically skipped until the first position allowing the typed character. Character stored in empty mask positions. Default: '_'.

SkipOptional StoredEmptyChar

See the MaskInfo class for the complete list of mask-related properties. If ShowLiterals property is set to FreeFormatEntry, optional mask positions can be completely omitted, there is no need to fill them with blank characters. Mask characters (placeholders) used in C1Input are similar to those used in Microsoft Access and Microsoft ActiveX MaskedEdit control (and more placeholders can be defined using the using the CustomPlaceholders collection):

Placeholder # .

Description Digit placeholder permits a numeric character or a plus or minus sign in this position (entry optional). Decimal placeholder. The actual character used is the one specified as the decimal placeholder in your international settings. This character is treated as a literal for masking purposes. Thousands separator. The actual character used is the one specified as the thousands separator in your international settings. This character is treated as a literal for masking purposes.

40 Using the C1Input Controls

Placeholder : / \ & > < ~ ! ^ A a 0 9 C L ? \n " Literal

Description Time separator. The actual character used is the one specified as the time separator in your international settings. This character is treated as a literal for masking purposes. Date separator. The actual character used is the one specified as the date separator in your international settings. This character is treated as a literal for masking purposes. Treat the next character in the mask string as a literal. This allows you to include the #, &, A, characters in the mask. This character is treated as a literal for masking purposes. Character placeholder (entry required). Any character is permitted. Convert all the characters that follow to uppercase. Convert all the characters that follow to lowercase. Turns off the previous < or >. Causes the optional characters that follow in the edit mask to display from right to left, rather than from left to right. So, blanks appear on the left. Turns off the previous ! character. After ^, blanks appear on the right. Alphanumeric character placeholder (entry required). For example: a z, A Z, or 0 9. Alphanumeric character placeholder (entry optional). Digit placeholder (entry required). For example: 0 9. Digit placeholder (entry optional). Character or space placeholder (entry optional). Any character is permitted. Letter placeholder (entry required). For example: a z or A Z. Letter placeholder (entry optional). New line literal. It is applicable when Multiline property is set to True. All characters in a string enclosed in double quotes are considered as literals. All other symbols are displayed as literals; that is, as themselves.

Example: The telephone number mentioned above, (412) 123-4567 can be represented with a mask EditMask set to "(000) 000-0000".

Validating Data
C1Input controls support data validation both of the raw input string (PreValidation) and of the typed value entered by the user (PostValidation). See Value and Text: Displaying, Validating, and Updating Values (page 28) for explanation of the validation process.

Input String Validation (PreValidation)


Input string validation is controlled by the PreValidation property. The PreValidation class allows you to specify validation rules either as wildcard pattern strings or regular expression strings. All rules (strings) are specified in the PatternString property. Multiple rules (sub-strings) are separated by the ItemSeparator ('|' by default). The PreValidation property defines how the PatternString is interpreted.

Validating Data 41

Value ExactList PreValidatingEvent Wildcards

Description PatternString contains a list of possible values separated by ItemSeparator. The PreValidating event is being used in validation. PatternString contains a list of wildcard patterns separated by the ItemSeparator. The following characters are reserved in a pattern: ? (any single character), # (any single digit), * (zero or more characters), \ (escape). You can also define your own custom pattern characters using the PreValidation property. PatternString contains a regular expression.

RegexPattern

Using the PreValidatingEvent option, you can perform input string validation in code, in the PreValidating event. For more information, see the event description. If you use regular expressions, the RegexPattern option, there is also a RegexOptions property that is sometimes needed to set flags affecting regular expression functionality. Note: Input string validation (PreValidation) is not used in DateTimeInput and NumericInput modes. When DateTimeInput or NumericInput modes are active is Typed Value Validation (PostValidation) (page 41) is performed. Examples: Validation property set to ExactList, PatternString set to "red|green|blue": Input string must be one of the three permitted values, "red", "green" or "blue", possibly ignoring the case, if CaseSensitive is set to False. Validation property set to Wildcards, PatternString set to "(412)*": Input string must start with "(412)", possibly ignoring the case, if CaseSensitive is set to False. Validation property set to RegexPattern, PatternString set to "[0-9]*": Input string contains one or more digits.

Typed Value Validation (PostValidation)


PostValidation allows you to validate the typed Value entered by the user. You can check that the value matches one of the values in a pre-defined value list specified in the Values property. You can also test the value to see if it is below a minimum or above a maximum, that is you can test to see if the value belongs to an interval. You can even specify multiple intervals of allowed values. The intervals are defined in the Intervals property where you specify minimum and maximum values for each interval, and also whether minimum and maximum values are used or ignored, and whether or not the inequality is strict (minimum/maximum value included). You can also exclude some values using the ValuesExcluded property. Finally, you can perform validation programmatically in the PostValidating event. To distinguish between declarative and programmatic validation, use the PostValidation property with two possible values: ValuesAndIntervals and PostValidatingEvent. Note that PostValidatingEvent disables automatic validation of values and intervals. Call the ValidateValuesAndIntervals method from the event code if you want to combine event code with values and intervals validation.

42 Using the C1Input Controls

Editing Date and Time Values


C1TextBox supports a special editing mode called DateTimeInput mode that makes editing date and time values easier. This mode is enabled when DataType property is set to DateTime and DateTimeInput property is set to True (default). In the DateTimeInput mode, the currently selected date or time field, such as the year, month, date, and so on, is highlighted and edited separately. Formatted fields represented in string form, such as month or day of the week in LongDate format, can be typed as numbers on the keyboard, and their string representation is updated automatically. Arrow UP/DOWN keys or mouse wheel can be used to increment/decrement the current field. Additional properties controlling date-time input are:

Property MinShortYear

Description The minimum year that can be entered without leading zeros (when DateTimeInput is set to True). For example, if MinShortYear is set to 300 (default), entering 200 is not allowed (will be ignored), whereas 400 is interpreted as 0400 A.D. Regardless of this property value, entering 0200 will be interpreted as year 0200 A.D. This property is True by default, which means that date-time values are invariant, not adjusted to time zones. If this property is set to False, the Text shown to the user and the underlying stored Value become different. The stored Value belongs to the time zone defined by the GMTOffset property specifying the offset in hours and minutes of the base time zone from Greenwich Mean Time. The Text shown to the user belongs to the local time zone defined by the user computer settings. Displaying values and parsing values entered by the user, C1Input adjusts it to the time zone difference.

CurrentTimeZone

To make editing date-time values even more convenient to the user, you can use the specialized C1DateEdit control. In addition to C1TextBox functionality, it supports a drop-down calendar and up-down buttons (speedbuttons) incrementing/decrementing the currently selected date-time field.

Editing Numeric Values


C1TextBox supports a special editing mode called NumericInput mode that makes editing numeric values easier. This mode is enabled when the NumericInput property is set to True (default) and DataType is one of numeric data types (Byte, UInt16, UInt32, UInt64, SByte, Int16, Int32, Int64, Decimal, Single, Double). In the NumericInput mode, numbers are edited in a calculator-like fashion. It accepts only digits, +/- sign, and, if data type and format allow, decimal point and exponent. Other characters, such as letters, are ignored. There are also special functional keys recognized in NumericInput mode for values of type Single and Double: F9 (change sign), F2 (negative infinity), F3 (positive infinity), F4 (NaN, "not a number"). To make editing numbers even more convenient to the user, you can use the specialized C1NumericEdit control. In addition to C1TextBox functionality, it supports a drop-down calculator and up-down buttons (speedbuttons) incrementing/decrementing the value by the specified Increment.

Drop-Down and Increment Buttons


The specialized C1Input controls for date-time and numeric editing, C1DateEdit and C1NumericEdit controls, support drop-down and increment/decrement (up/down) buttons. Button visibility is controlled by the ShowDropDownButton and ShowUpDownButtons properties. To control drop-down alignment and distance from the control you can use the DropDownAlign and GapHeight properties. To open/close drop-down programmatically, use the OpenDropDown and CloseDropDown methods. Opening/closing drop-down triggers events DropDownOpened and DropDownClosed. You can use the DropDownOpened event to adjust drop-down properties (mostly,

Custom Drop-Down 43

calendar properties in Calendar) before the drop-down is shown to the user. You can check if the drop-down is open using the DroppedDown property.

C1DateEdit Control
C1DateEdit control supports up/down buttons and drop-down calendar. The Up/down buttons function if DateTimeInput property is set to True. They increment/decrement the currently selected field of the date-time value, see Editing Date and Time Values (page 42). The drop-down calendar has the same object model as the standard MonthCalendar control (System.Windows.Forms.MonthCalendar) and almost the same appearance with additional buttons Clear, Today and two year navigation buttons. Button visibility is controlled by the properties ShowClearButton and ShowTodayButton. These properties and all other calendar properties are available both in the designer and in code in the Calendar object. If you want to change calendar properties programmatically when the calendar is opened, before it is shown to the user, use the DropDownOpened event.

C1NumericEdit Control
C1NumericEdit control supports up/down buttons and drop-down calculator. Up/down buttons increment/decrement the Value by the amount specified in the Increment property (default: 1). The drop-down calculator follows the standard Windows calculator model, allows the user to perform calculations without leaving the control.

Custom Drop-Down
C1Input includes a powerful custom drop-down functionality that allows you to create any drop-down editor you need, in addition to the standard calendar and calculator drop-downs provided by C1Input. Drop-down editors are created visually as forms in your project. To create your own custom drop-down editor, use the C1DropDownControl. This control class derives from C1TextBox and adds custom drop-down functionality and up-down buttons. To create a drop-down editor for your control, add a form to your project derived from C1.Win.C1Input.DropDownForm (see Tutorial 8 Custom Drop-down Form) and select the form class name in the DropDownFormClassName property of your C1DropDownControl. In your DropDownForm-derived form you can set the Value property of C1DropDownControl when necessary (use the DropDownForm.OwnerControl property to get the control object), or you can do it when the form is closing, in the PostChanges event. See the DropDownForm class reference for the full description of available options for custom drop-down forms. Also see the Samples directory for common use samples of the custom drop-down functionality. If you need to create a custom control with drop-down functionality, this can be done by deriving a custom control class from C1DropDownControl and overriding its DefaultDropDownFormClassName property.

Programmatic Formatting, Parsing and Validation


If standard and custom format specifiers are not enough, you can format values in code in the Formatting event by setting the FormatType property to UseEvent, see Formatting Data (page 29). In your formatting code, you can use the standard C1Input formatting as a helper or for any other purposes, calling the Format method. Parsing can also be done in event code, in the Parsing event, by setting the FormatType property to UseEvent. You can use standard C1Input parsing routines in your code if you need them, with the following ParseInfo methods: Parse, ParseFixed, ParseFloat, ParseInteger, ParseBoolean and ParseDateTime. Some useful methods for edit mask management can be found in the MaskInfo class.

44 Using the C1Input Controls

When you need to synchronize the Value property with the text currently entered by the user, call the UpdateValueWithCurrentText method. Normally, this synchronization is done automatically when the control loses focus, but in certain situations you may find necessary to call this method and force the Value update. Updating Value involves parsing the input text, validating, and updating the Value property, see Value and Text: Displaying, Validating, and Updating Values (page 28). You can also perform the first two phases, parsing and validation without changing the Value, using the methods ParseContent and CheckValidationResult.

Error Handling
Error handling is very important in data input forms. C1Input gives developers full control over various error conditions, such as the errors listed below.

Data Errors
WinForms data sources such as ADO.NET and C1DataObjects contain provisions for detecting logical errors in data, by the data source itself or by the programmer, setting the RowError property or calling the SetColumnError method (SetFieldError in C1DataObjects). You can show logical row and column errors in C1Input using System.Windows.Form.ErrorProvider component. To show logical column errors, use the ErrorProvider component with C1Input controls as you would use it with any other controls. To show row error in C1DbNavigator control, set the ErrorProvider property to an ErrorProvider component. Then C1DbNavigator will display error icon with RowError tooltip text when there is an error in current row.

Incorrect Format in Displaying Data


It is possible, although generally avoided in applications that data fetched from the database or another data source does not match the format or edit mask defined in a C1Input control. In such cases, the control cannot show its value properly formatted. Although C1Input controls have reasonable default behavior handling this situation, you may want to inform the user of invalid data. This is done using the ErrorProvider property (ErrorProvider in C1Label control). If you set this property to an ErrorProvider component, C1Input uses that ErrorProvider component to signal errors when it displays invalid data (data that cant be formatted for display in the control). It calls the ErrorProvider.SetControl method when such error is detected. Before doing that, C1Input fires the FormatError event where you can customize the error message (ErrorProvider tooltip text) and perform other actions.

User Input Errors


When C1Input detects an error while parsing or validating input value, it fires the ValidationError event. Then, by default, it shows an error message. The default behavior can be changed and customized in different ways: C1Input controls have an ErrorInfo property containing settings (properties of the ErrorInfo class) affecting error handling:

Property BeepOnError CanLoseFocus

Description If True, the control beeps signaling an error. Default: False. If True, the control is allowed to lose focus regardless of the error. This property is False by default, meaning that the control will stay in focus until the error is corrected. Note that setting ErrorAction to SetValueOnError or ResetValue allows the user to leave the control after error by resetting its value.

Error Handling 45

Property ErrorAction

Description Enumerated value that determines what action is performed on the control value when an error occurs. ErrorAction set to None (default) means that Value is not changed, remains as it was before the unsuccessful value update. If ErrorAction is set to SetValueOnError, controls Value is set to the value specified in the ValueOnError property of the ErrorInfo class. If ErrorAction is set to ResetValue, controls Value is set to the last value the control had before it entered edit mode. Setting the ErrorAction property to ThrowException interrupts execution and throws an exception, ValidationException. Error message shown in the standard message box and/or in the exception. The text to display in the title bar of the error message box. Gets or sets an ErrorProvider object used to indicate error state of the control. If True (default), the standard error message is shown. Value used to reset the control if ErrorAction is set to SetValueOnError. Boolean property used to set ValueOnError to DBNull (only necessary at design time).

ErrorMessage ErrorMessageCaption ErrorProvider ShowErrorMessage ValueOnError ValueOnErrorIsDbNull

In addition to that, ErrorMessage can be specified for particular actions: edit mask errors (ErrorMessage), parsing (ErrorMessage), pre- and post-validation (ErrorMessage, ErrorMessage). If a specialized error message is not specified in one of these sub-objects, the controls ErrorMessage takes effect. Note that you can use ErrorProvider icon to indicate the error, instead of showing a message box, if you set ErrorProvider to an ErrorProvider component and ShowErrorMessage to False. The properties listed above, when set in the controls ErrorInfo object, affect all error handling in the control. When an error occurs, their values can be customized programmatically to handle that particular error. This is achieved by passing an ErrorInfo argument to the ValidationError event. The ErrorInfo argument passed to ValidationError is a copy of the controls ErrorInfo with all its properties. It is an independent copy, so you can change properties in the ErrorInfo event argument for the current error without affecting the overall controls ErrorInfo settings. By setting ErrorInfo properties in the ValidationError event you specify how to handle the error. For example, you can suppress the standard error message (and show your own message instead) by setting the ShowErrorMessage property to False, or you can change ValueOnError (and set ErrorAction to SetValueOnError), or change the ErrorMessage. Keep in mind that you must set the properties of the ErrorInfo argument passed to the ValidationError event, not the properties of the controls ErrorMessage. After the ValidationError event, error handling proceeds as specified in the events ErrorInfo argument. If ErrorAction is set to ThrowException, an exception is thrown (using the ErrorMessage text). If BeepOnError is True, the control beeps. If ShowErrorMessage is set to True, the standard error message box is shown (with ErrorMessage text). After that, the controls value may be changed if so specified by ErrorAction. Finally, moving focus to another control is either canceled or permitted, according to CanLoseFocus, if validation was triggered by an attempt to move focus out of the control. If ErrorProvider property is set to an ErrorProvider component, that component is used to show the error icon near the offending control, with ErrorMessage tooltip (ErrorProvider.SetError is called). If you perform parsing or validation programmatically, in event code, and exit the event with an error condition (set the events Succeeded argument to False), you can describe the error and how it must be

46 Using the C1Input Controls

handled by setting the properties of an ErrorInfo argument passed to the event. Such argument is provided for the following events: PreValidating, Parsing and PostValidating. Its initial values are taken from the controls ErrorInfo property. This ErrorInfo argument that you change in the event is then passed to the ValidationError event where it can be further changed as described above.

Handling NULL and Empty Values


NULL values (DBNull) can be difficult to handle without appropriate tools. C1Input provides flexible rules for handling nulls allowing the programmer the ability to solve this problem in practically any circumstance.

Displaying NULL and Empty Values


When a control is not in edit mode or is read-only, null values are displayed according to the NullText property (which can be overridden in DisplayFormat). If the property EmptyAsNull is set to True (default: False), empty strings are also displayed with the same NullText string. The EmptyAsNull property can also be overridden in EmptyAsNull. In edit mode, the NullText and EmptyAsNull properties of the EditFormat object take effect, instead of those of DisplayFormat. In edit mode with an active EditMask, the null value and the empty string are shown as an empty mask with literals in their places and prompt characters filling the rest. When editing a date-time value with the DateTimeInput property set to True, the null value is represented by an empty control. When the user starts editing with a keystroke or mouse click, the control immediately turns to a non-null value, namely, to the last non-null value assigned to the control or to todays date. In programmatic formatting (FormatType set to UseEvent), the Formatting event is only called for non-null values.

Entering NULL and Empty Values


Unless in edit mask mode or in date-time editing with DateTimeInput set to True, the user can enter a null value in one of the following ways: If the control text equals NullText, the resulting value is null. The effective NullText value here is determined by NullText. Comparison with NullText is case-sensitive or not depending on the CaseSensitive property. Clearing the control, entering an empty string results in null value if the C1TextBox.EmptyAsNull property is set to True (it is False by default). In programmatic parsing, DBNull value can be returned by the programmer in the Parsing event.

If the user enters a null value (either by entering an empty string or NullText, see above), input string validation and parsing are skipped, see Input string validation (PreValidation) (page 40) and Parsing (Updating) Data (page 38). However, PostValidation is performed in this case as in all others, see Typed value validation (PostValidation) (page 41).

C1Input Samples 47

C1Input Samples
Please be advised that this ComponentOne software tool is accompanied by various sample projects and/or demos which may make use of other development tools included with ComponentOne Studio Enterprise. Note: The ComponentOne Samples are also available at http://helpcentral.componentone.com/ProductResources.aspx.

Visual Basic Samples

Sample CreditCardDropDown

Description Using a custom drop-down form. This sample uses the C1DropDownControl and DropDownForm controls. Demonstrates the use of two important events of C1TextBox, C1Label, and C1PictureBox controls.This sample uses the C1DateEdit, C1DbNavigator, C1Label, and C1PictureBox controls. Implements a fully functional font editing control based onC1DropDrownControl. The user can change font properties with the texteditor or open the drop-down portion to change font properties in a more convenient way. This sample uses the C1DropDownControl, C1TextBox, and DropDownForm controls. Shows how to create a custom drop-down control with names from a lookup table. The UpDown button scrolls the names, while the ellipsis (...) button allows to enter a new name. Replaces the standard calculator in a C1NumericEdit control with the custom drop-down numpad. This sample uses the C1NumericEdit and DropDownForm controls. Demonstrates the ability to enter numbers with the mouse or other pointing device. This sample uses the C1DbNavigator, C1NumericEdit, and DropDownForm controls.

FormattingInBinding

InheritedDropDown

LookUpSample

NumPadDropDown1

NumPadDropDown2

C# Samples

Sample CreditCardDropDown

Description Using a custom drop-down form. This sample uses the C1DropDownControl and DropDownForm controls. Demonstrates the use of two important events of C1TextBox, C1Label, and C1PictureBox controls.This sample uses the C1DateEdit, C1DbNavigator, C1Label, and C1PictureBox controls.

FormattingInBinding

48 C1Input Samples

Sample

Description Implements a fully functional font editing control based onC1DropDrownControl. The user can change font properties with the texteditor or open the drop-down portion to change font properties in a more convenient way. This sample uses the C1DropDownControl, C1TextBox, and DropDownForm controls. Replaces the standard calculator in a C1NumericEdit control with the custom drop-down numpad. This sample uses the C1NumericEdit and DropDownForm controls. Demonstrates the ability to enter numbers with the mouse or other pointing device. This sample uses the C1DbNavigator, C1NumericEdit, and DropDownForm controls.

InheritedDropDown

NumPadDropDown1

NumPadDropDown2

Binding C1Input Controls to a Data Source 49

C1Input Tutorials
The tutorials assume that you are familiar with programming in Visual Basic.NET, know what a DataSet is, and generally know how to use bound controls. The tutorials provide step-by-step instructionsno prior knowledge of C1Input is needed. By following the steps outlined in this chapter, you will be able to create projects demonstrating a variety of C1Input features, and get a good sense of what C1Input can do and how to do it. The tutorials use an Access database, NWind.mdb. The database file NWind.mdb is in the Common subdirectory of the ComponentOne Studio.NET 2.0 program folder and the tutorial projects are in the Tutorial subdirectory of the C1Input installation directory. If you have the Northwind database installed in a different location, you can change the connection string, or copy the NWind.mdb file to the required location. Note: If you are running the pre-built tutorial projects included in C1Input installation, please be aware that the projects have the sample database location hard coded in the connection string: C:\Program Files\ComponentOne Studio.NET 2.0\Common\NWIND.MDB

Binding C1Input Controls to a Data Source


In this tutorial, you will see how easy it is to show database data in a form using C1Input components. Without any manual coding, you can format data, navigate data source rows, even display pictures. C1Input controls support data binding to any .NET data source objects. Among them, you can use any standard ADO.NET object, such as DataTable, DataView or DataSet as your data source. The alternative and recommended way is to use ComponentOne C1DataObjects framework, a part of ComponentOne Studio Enterprise adding many enhancements to ADO.NET. We will use C1DataObjects Express Edition (C1DataExpress) data source in all our tutorials except this first one, since it is the easiest way to bind to data in a .NET application. If you are interested in ADO.NET versions of tutorial projects, they can be found in the Tutorials\ADO.NET subdirectory. This tutorial will show how to bind both to C1DataObjects and to ADO.NET.

Binding to a C1DataExpress Data Source


1. 2. Create a new Windows Application project. For information on adding the C1Input and C1DataExpress components to the Visual Studio Toolbox, see Adding the C1Input Components to a Project (page 16). Place the following components on the form as shown in the figure: C1ExpressTable1 (C1.Data.Express.C1ExpressTable) C1Label1-2 (C1.Win.C1Input.C1Label) C1PictureBox1 (C1.Win.C1Input.C1PictureBox) C1TextBox1 (C1.Win.C1Input.C1TextBox) C1DbNavigator1 (C1.Win.C1Input.C1DbNavigator)

50 C1Input Tutorials

3.

Select the C1ExpressTable1 component, go to the Properties window, open the ConnectionString property combo box and select New Connection. It will open the standard OLE DB Data Link Properties dialog box. Select the provider, the database and other necessary connection properties in that dialog box. In these tutorials, we use the standard MS Access Northwind sample database (NWIND.MDB). Add the following to the ConnectionString property: Provider=Microsoft.Jet.OLEDB.4.0;Data Source="C:\Program Files\ComponentOne Studio.NET 2.0\Common\NWIND.MDB". For the C1ExpressTable1 component, open the DbTableName property box and select Employees from the Database Table list. Now, we will bind some C1Input controls to the data control. Suppose we want to show the first name, date of birth, notes and photo for each employee. The first name and date of birth will be displayed in C1Label controls, notes in C1TextBox, and photo in C1PictureBox. For the C1Label1 control, go to the Properties window, select C1ExpressTable1 from the drop-down list for the DataSource property, and then select FirstName from the list for the DataField property. Property C1Label1.DataSource C1Label1.DataField Setting C1ExpressTable1 FirstName

4.

5. 6.

7.

Bind the C1Label2 DataSource property to C1ExpressTable1 and the C1Label2 DataField property to BirthDate and C1TextBox1 DataSource property to C1ExpressTable1 and the C1TextBox1 DataField property to Notes. Property C1Label2.DataSource C1Label2.DataField C1TextBox1.DataSource Setting C1ExpressTable1 BirthDate C1ExpressTable1

Binding C1Input Controls to a Data Source 51

Property C1TextBox1.DataField 8.

Setting Notes

After binding the C1Label2 control, you can notice that its DataType property is set to the field type, DateTime. Now, change the format for C1Label2 so that it will not show time with the date of birth (showing time is the default). To change the format, select the FormatType property, open its combo box and select Medium Date. Bind the C1PictureBox control to the Photo field. First select C1ExpressTable in the DataSource property combo box of the C1PictureBox control, then open the DataField property combo box and select Photo from the list of available fields. Property C1PictureBox1.DataSource C1PictureBox1.DataField Setting C1ExpressTable1 Photo

9.

10. Set up the C1DbNavigator1 control allowing the user to navigate through the data set. To bind the navigator control to the data source, select C1ExpressTable1 in its DataSource property combo box. Property C1DbNavigator.DataSource Setting C1ExpressTable1

11. To dock the navigator control to the bottom of the form and separate it from the rest of the form with a three-dimensional line, set the following properties: Property C1DbNavigator1.Dock C1DbNavigator1.BorderStyle Run the program and observe the following: C1Input controls show data in Employees records. You can navigate between Employees records using the four VCR-style buttons of the navigator control. You can also go directly to a certain record by typing the record number in the navigator control record number edit field, or set the input focus to the record number field and use mouse wheel to scroll through the records. Setting Bottom Fixed3D

52 C1Input Tutorials

Binding to an ADO.NET Data Source


1. 2. Create a new Windows Application project. For information on adding the C1Input and C1DataExpress components to the Visual Studio Toolbox, see Adding the C1Input Components to a Project (page 16). Place the following components on the form as shown in the figure: C1Label1-2 (C1.Win.C1Input.C1Label) C1PictureBox1 (C1.Win.C1Input.C1PictureBox) C1TextBox1 (C1.Win.C1Input.C1TextBox) C1DbNavigator1 (C1.Win.C1Input.C1DbNavigator)

3. 4. 5.

Add a BindingSource component (located on the Data tab of the Toolbox) to the form. In the Properties window, locate the DataSource property and expand the drop-down. Select Add Project Data Source. This will open the DataSource Configuration Wizard. Select Database on the Choose a Data Source Type page, and click Next.

Binding C1Input Controls to a Data Source 53

6.

Click the New Connection button to create a new connection or choose one from the drop-down list.

54 C1Input Tutorials

Click the Browse button to specify the location of the Nwind.mdb database. Click the Test Connection button to make sure that you have successfully connected to the database or server and click OK. The new string appears in the on the Choose Your Data Connection page.

7.

Click the Next button to continue. A dialog box will appear asking if you would like to add the data file to your project and modify the connection string. Click No.

8.

Save the connection string in the application configuration file by checking the Yes, save the connection as box and entering a name. Click the Next button to continue.

Binding C1Input Controls to a Data Source 55

9.

On the Choose your database object page, select the Employees table. Click Finish to exit the wizard.

A DataSet and connection string are added to your project.

56 C1Input Tutorials

10. In the Properties window, set the DataMember property for BindingSource1 to Employees. A DataTableAdapter is added to the form and automatically adds the following code to the Form_Load event: Visual Basic Me.EmployeesTableAdapter.Fill(Me.NwindDataSet.Employees) C# this.EmployeesTableAdapter.Fill(this.NwindDataSet.Employees); Delphi Self.EmployeesTableAdapter.Fill(Self.NwindDataSet.Employees);

Bind C1Input controls to the data source Suppose we want to show the first name, date of birth, notes and photo for each employee. The first name and date of birth will be displayed in a C1Label control, notes in C1TextBox, and photo in C1PictureBox. Binding the C1Input controls to the data source involves the following operations: 1. For the C1Label1 control, go to the Properties window, select NwindDataSet from the drop-down list for the DataSource property, and then select Employees.FirstName from the list for the DataField property Property C1Label1.DataSource C1Label1.DataField Setting NwindDataSet Employees.FirstName

Note: To change the Label's Size property, you must set its AutoSize property to False. 2. As in the above step, bind the C1Label2 DataSource property to NwindDataSet and the C1Label2 DataField property to Employees.BirthDate and the C1TextBox1 DataSource property to NwindDataSet and the C1TextBox1 DataField property to Employees.Notes. Property C1Label2.DataSource C1Label2.DataField C1TextBox1.DataSource C1TextBox1.DataField Setting NwindDataSet Employees.BirthDate NwindDataSet Employees.Notes

After binding the C1Label2 control, notice that its DataType property is set to the field type, DateTime. Now, change the format for C1Label2 so that it will not show time with the date of birth (showing time is the default). To change the format, select the FormatType property, open its combo box and select Medium Date. After binding the C1TextBox control, set its Multiline property to True.

3.

Bind the C1PictureBox control to the Photo field. First select NwindDataSet in the DataSource property combo box of the C1PictureBox control, then open the DataField property combo box and select Employees.Photo from the list of available fields. Property C1PictureBox1.DataSource C1PictureBox1.DataField Setting NwindDataSet Employees.Photo

Masked Input 57

4.

Set up the C1DbNavigator1 control allowing the user to navigate through the data set. To bind the navigator control to the data source, first select dataSet11 in its DataSource property combo box, then select Employees in its DataMember property combo box. Property C1DbNavigator1.DataSource C1DbNavigator1.DataMember Setting NWindDataSet Employees

5.

To dock the navigator control to the bottom of the form and separate it from the rest of the form with a three-dimensional line, set the following properties: Property C1DbNavigator1.Dock C1DbNavigator1.BorderStyle Setting Bottom Fixed3D

Run the program and observe the following: C1Input controls show data in Employees records. You can navigate between Employees records using the four VCR-style buttons of the navigator control. You can also go directly to a certain record by typing the record number in the navigator control record number edit field, or set the input focus to the record number field and use mouse wheel to scroll through the records.

Masked Input
In this tutorial, you will learn how to use edit mask to facilitate and restrict user input. 1. Create a new Windows Application project. Place the following components on the form as shown in the figure: C1ExpressConnection1 (C1.Data.Express.C1ExpressConnection) C1ExpressTable1-3 (C1.Data.Express.C1ExpressTable)

58 C1Input Tutorials

Label1-4 (all of type System.Windows.Forms.Label): Label1.Name Label1.Text Label2.Name Label2.Text Label3.Name Label3.Text Label4.Name Label4.Text labStoredExpNumber <stored value> labStoredDateTime <stored value> labStoredPhone <stored value> labStoredMultiline <stored value>

C1TextBox1-7 (C1.Win.C1Input .C1TextBox) C1Label1-4 (C1.Win.Input.C1Label): C1Label1.Name C1Label1.Text C1Label2.Name C1Label3.Name C1Label4.Name labCompanyName labCompanyName labCustomerID labOrderDate labFreight

C1DbNavigator1 (C1.Win.C1Input .C1DbNavigator) Button1 (System.Windows.Forms.Button): Name Text btnClose Close

Masked Input 59

Note: The labels in blue are all of type System.Windows.Forms.Label. The Text property for each label is as it appears on the form. 2. Select the C1ExpressConnection1 component, go to the Properties window, open the ConnectionString property. Add the following to the ConnectionString property: Provider=Microsoft.Jet.OLEDB.4.0;Data Source="C:\Program Files\ComponentOne Studio.NET 2.0\Common\NWIND.MDB". Set the properties of C1ExpressTable1-3 as follows: Property C1ExpressTable1.ConnectionComponent C1ExpressTable1.DbTableName C1ExpressTable2.ConnectionComponent C1ExpressTable2.DbTableName C1ExpressTable3.ConnectionComponent C1ExpressTable3.DbTableName Value C1ExpressConnection1 Customers C1ExpressConnection1 Orders C1ExpressConnection1 <Composite>

3.

In the Composite Table Editor add Customers table and then Orders table related as One-to-Many. Add Customers.CustomerID Orders.CustomerID join and click OK.

60 C1Input Tutorials

4.

To bind controls to the data source, set the following properties: Property C1DbNavigator1.DataSource C1DbNavigator1.DataMember labCompanyName.DataSource labCompanyName.DataField labCustomerID.DataSource labCustomerID.DataField labOrderDate.DataSource labOrderDate.DataField labFreight.DataSource labFreight.DataField C1TextBox5.DataSource C1TextBox5.DataField C1TextBox6.DataSource C1TextBox6.DataField C1TextBox7.DataSource Value C1ExpressConnection1 CompositeTable C1ExpressConnection1 CompositeTable.CompanyName C1ExpressConnection1 CompositeTable.CustomerID C1ExpressConnection1 CompositeTable.OrderDate C1ExpressConnection1 CompositeTable.Freight C1ExpressConnection1 CompositeTable.CustomerID C1ExpressConnection1 CompositeTable.OrderDate C1ExpressConnection1

Masked Input 61

Property C1TextBox7.DataField

Value CompositeTable.Freight

Note: If all of the fields in the CompositeTable are not appearing in the DataField drop-down, select C1ExpressTable3 and open the C1ExpressTable Tasks menu by clicking the smart tag ( ). In the C1ExpressTable Tasks menu, click Retrieve Fields. You may have to set the DataSource and DataField properties again. 5. Labels labStoredXXX located to the right of C1TextBox1-4 controls display the current Value property of the corresponding C1TextBox. To synchronize them with C1TextBox1-4, create event handlers C1TextBox1(4)_ValueChanged: Visual Basic Private Sub C1TextBox1_ValueChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles C1TextBox1.ValueChanged Try labStoredExpNumber.Text = CType(Me.C1TextBox1.Value, String) Catch labStoredExpNumber.Text = "" End Try End Sub Private Sub C1TextBox2_ValueChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles C1TextBox2.ValueChanged Try labStoredDateTime.Text = CType(Me.C1TextBox2.Value, String) Catch labStoredDateTime.Text = "" End Try End Sub Private Sub C1TextBox3_ValueChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles C1TextBox3.ValueChanged Try labStoredPhone.Text = CType(Me.C1TextBox3.Value, String) Catch labStoredPhone.Text = "" End Try End Sub Private Sub C1TextBox4_ValueChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles C1TextBox4.ValueChanged Try labStoredMultiline.Text = CType(Me.C1TextBox4.Value, String) Catch labStoredMultiline.Text = "" End Try End Sub C# private void c1TextBox1_ValueChanged(object sender, System.EventArgs e) { try { labStoredExpNumber.Text = (string)this.c1TextBox1.Value; }

62 C1Input Tutorials

catch { labStoredExpNumber.Text = ""; } } private void c1TextBox2_ValueChanged(object sender, System.EventArgs e) { try { labStoredDateTime.Text = (string)this.c1TextBox1.Value; } catch { labStoredDateTime.Text = ""; } } private void c1TextBox3_ValueChanged(object sender, System.EventArgs e) { try { labStoredPhone.Text = (string)this.c1TextBox1.Value; } catch { labStoredPhone.Text = ""; } private void c1TextBox4_ValueChanged(object sender, System.EventArgs e) { try { labStoredMultiline.Text = (string)this.c1TextBox1.Value; } catch { labStoredMultiline.Text = ""; } } Delphi procedure TWinForm.C1TextBox1_ValueChanged(sender: System.Object; e: System.EventArgs); begin try labStoredExpNumber.Text := String(Self.C1TextBox1.Value); except labStoredExpNumber.Text := ''; end; end; procedure TWinForm.C1TextBox2_ValueChanged(sender: System.Object; e: System.EventArgs); begin try labStoredDateTime.Text := String(Self.C1TextBox2.Value);

Masked Input 63

except labStoredExpNumber.Text := ''; end; end; procedure TWinForm.C1TextBox3_ValueChanged(sender: System.Object; e: System.EventArgs); begin try labStoredPhone.Text := String(Self.C1TextBox3.Value); except labStoredPhone.Text := ''; end; end; procedure TWinForm.C1TextBox4_ValueChanged(sender: System.Object; e: System.EventArgs); begin try labStoredMultiline.Text := String(Self.C1TextBox4.Value); except labStoredMultiline.Text := ''; end; end; 6. C1TextBox1 allows you to enter numbers with or without fractional part and with optional exponent. It uses the WhenNextStarted mode of showing mask literals, so the decimal point appears only when necessary, when the user starts entering the decimal part. Set the EditMask property of C1TextBox1 to !###0.^999e#9. Here '#' is an optional position for a digit or sign, '9' is an optional position for a digit, '0' is a required position for a digit, '!' is a special character specifying right justification for the following text, '^' cancels right justification mode, 'e' a literal. Then expand the C1TextBox1.MaskInfo property and set ShowLiterals to WhenNextStarted. Note: C1TextBox and C1NumericEdit support a special edit mode, NumericInput mode facilitating input of any numeric data type. It is usually more convenient for numeric input than edit mask. Try NumericInput before using an edit mask for numeric data. 7. C1TextBox2 is used for entering a date/time value. Set the C1TextBox2.EditMask property to !90/90/9900 90:90 >PM. There are two new special characters used in this mask: '>' causes the next characters to be converted to upper case, 'P' is a non-standard special character (custom placeholder) allowing entering either 'A' or 'P'. To define a custom placeholder, expand the property C1TextBox2.MaskInfo and press the ellipsis button in the CustomPlaceholders property to open the Collection Editor. In the Collection Editor, add a new item. Set the properties of the newly added item: Property Placeholder LookupChars Value P AP

Thus the letter 'P' represents a position in edit mask where the user can type 'A' or 'P'. Now, we want to specify that entered date/time values are stored in the database in a compact form without literals. For example, the value "11/_8/2002 _1:42 PM" is stored as "11*82002*142P". To enable this storage format, set SaveBlanks to True and SaveLiterals to False (both properties are contained in C1TextBox2.MaskInfo). Also, change StoredEmptyChar from default '_' to '*' to store asterisk in blank

64 C1Input Tutorials

positions. If you set SaveBlanks to False, SaveLiterals to True, blank positions will not be saved in the database, the above data will be saved as "11/8/2002 1:42PM". Note: C1TextBox and C1DateEdit support a special edit mode, DateTimeInput mode facilitating input of date/time data. It is usually more convenient for date/time input than edit mask. Try DateTimeInput before using an edit mask for date/time data. 8. Set up the C1TextBox3 control for telephone number input with mask (999) 0099-00099. Here 9 is an optional digit position, 0 is a required digit position. Set the EditMask property of the C1TextBox3 control to (999) 0099-00099, then expand the MaskInfo property and set AutoTabWhenFilled to True. This will automatically move the input focus to the next control once the user fills the last mask position. The C1TextBox4 control demonstrates multiline mask input. Set its Multiline property to True, ScrollBars to Vertical and EditMask property to: "First Name: "CCCCCCCCCCCCCCC\n"Last Name: "CCCCCCCCCCCCCCCCCCCC\n"Date of Birth: "!90/90/9900^\n"Work Status: "CCCCCCCCCCCCCCC\n"Salary: $"!######0.^99 Here \n represents a line break. Now expand the MaskInfo property and set SaveBlanks to True. This ensures that all positions left blank by the user are saved as spaces. If SaveBlanks is set to False, optional positions not filled by the user will be ignored. Additionally, you can set SaveLiterals to False, which will prevent saving literal texts, so only the information typed by the user is saved. 10. All the previous controls were unbound. Let us also configure some data bound C1Label and C1TextBox controls. They are located at the bottom of the form. Their data binding properties were set on Step 4. Set their other properties as follows: Property labCustomerID.MaskInfo.EditMask C1TextBox5.EditMask labOrderDate.FormatType labOrderDate.CustomFormat labOrderDate.MaskInfo.EditMask C1TextBox6.FormatType C1TextBox6.CustomFormat C1TextBox6.MaskInfo.EditMask labFreight.FormatType labFreight.CustomFormat labFreight.MaskInfo.EditMask C1TextBox7.FormatType C1TextBox7.CustomFormat C1TextBox7.EditMask Run the program and observe the following: Mask characters appear when you move focus to a control (except c1TextBox1 that has ShowLiterals set to WhenNextStarted). In edit mode, empty mask positions are shown using PromptChar (default: _). When the control loses focus, these positions are hidden. Experiment typing in the controls and look at the stored values displayed in the labels. Value >LLLLL >LLLLL CustomFormat M/d/yyyy !90/90/0000 CustomFormat M/d/yyyy !90/90/0000 CustomFormat $ ####0.## $ !99990.^99 CustomFormat $ ####0.## $ !99990.^99

9.

Data Navigation and Actions Using C1DbNavigator 65

If you select the whole text and press DELETE, the input control is cleared. Depending on the EmptyAsNull, this is interpreted either as DBNull value or as current edit cancellation, reverting to the previous value when the control loses focus. The same effect, canceling edit, has the ESC key.

Data Navigation and Actions Using C1DbNavigator


This tutorial demonstrates the main features of the C1DbNavigator control. It is primary used to navigate through data source rows, but it can also be used to perform common actions on data such as adding rows, confirming changes, updating the data source, refreshing from the data source (canceling changes), and others. 1. 2. Create a new Windows Application project. Place the following components on the form as shown in the figure: C1ExpressConnection (C1.Data.Express.C1ExpressConnection) C1ExpressTable1-2 (C1.Data.Express.C1ExpressTable) C1Label1-3 (C1.Win.C1Input.C1Label): C1Label1.TextDetached C1Label1.Text C1Label2.TextDetached C1Label2.Text C1Label3.TextDetached C1Label3.Text True Customers: True Orders: True Update/Refresh:

DataGridView1-2 (System.Windows.Forms.DataGridView) C1DbNavigator1-3 (C1.Win.C1Input.C1DbNavigator) Button1 (System.Windows.Forms.Button): Name Text btnClose Close

66 C1Input Tutorials

3.

Select the C1ExpressConnection1 component, go to the Properties window, open the ConnectionString property. Add the following to the ConnectionString property: Provider=Microsoft.Jet.OLEDB.4.0;Data Source="C:\Program Files\ComponentOne Studio.NET 2.0\Common\NWIND.MDB". Set the properties of C1ExpressTable1-2 as follows: Property C1ExpressTable1.ConnectionComponent C1ExpressTable1.DbTableName C1ExpressTable2.ConnectionComponent C1ExpressTable2.DbTableName Value C1ExpressConnection1 Customers C1ExpressConnection1 Orders

4.

5.

Also, you need to set the AutoIncrement property of the OrderID field in C1ExpressTable2, otherwise you will not be able to update data in the database: Select C1ExpressTable2, press the ellipsis button in the Properties window for the Fields property to open the Fields dialog box, select the OrderID field and set its AutoIncrement property to ClientAndServer. This is necessary because OrderID is an autoincrement field in the database, so it must be treated accordingly by C1DataExpress. Create a master-detail relation between C1ExpressTable1 (master) and C1ExpressTable2 (detail). Press the ellipsis button in the Relations property of the C1ExpressionConnection1 control to open the Relations dialog box. In the dialog box, select Customers for Parent, Orders for Child, add a join with CustomerID for both Parent field and Child field, press OK to close the Relations dialog box.

6.

Data Navigation and Actions Using C1DbNavigator 67

7.

To bind controls to the data source, set the following properties: Property DataGridView1.DataSource DataGridView1.DataMember C1DbNavigator1.DataSource C1DbNavigator1.DataMember DataGridView2.DataSource DataGridView2.DataMember C1DbNavigator2.DataSource C1DbNavigator2.DataMember Value C1ExpressConnection1 _Customers C1ExpressConnection1 _Customers C1ExpressConnection1 _Customers.Customers Orders C1ExpressConnection1 _Customers.Customers Orders

8.

Now C1DbNavigator1 allows us to navigate the master table Customers, and the detail table Orders. However, we want some more functionality for our navigator control. We want the user to be able to perform common data action pressing navigator buttons. Using the VisibleButtons property, show the following buttons for C1DbNavigator1-2: Add, Delete, Apply, Cancel. By default, a navigator control also shows the current row number and row count. To save space, hide this information be setting the PositionVisible property to False. The third navigator control, C1DbNavigator3 is used to perform update and refresh for the whole data set (both tables Customers and Orders). To hide redundant navigator fields and buttons, set PositionVisible to False and select only two buttons, Update and Refresh in the VisibleButtons property. Update and Refresh buttons do not have built-in functionality, since their function may be different with different data sources. To make them work, you need to write code in event handlers. Create the following event handlers: Visual Basic Private Sub C1DbNavigator3_UpdateData(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles C1DbNavigator3.UpdateData Me.C1ExpressConnection1.Update() End Sub Private Sub C1DbNavigator3_RefreshData(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles C1DbNavigator3.RefreshData Me.C1ExpressConnection1.Fill() End Sub

9.

68 C1Input Tutorials

C# private void c1DbNavigator3_UpdateData(object sender, System.EventArgs e) { this.c1ExpressConnection1.Update(); } private void c1DbNavigator3_RefreshData(object sender, System.EventArgs e) { this.c1ExpressConnection1.Fill(); }

Delphi procedure TWinForm1.C1DbNavigator3_UpdateData(sender: System.Object; e: System.EventArgs); begin Self.C1ExpressConnection1.Update; end; procedure TWinForm1.C1DbNavigator3_RefreshData(sender: System.Object; e: System.EventArgs); begin Self.C1ExpressConnection1.Fill; end;

10. Navigator buttons can be monochrome, color (ColorButtons property set to True) or changing their color when hovered over (ColorWhenHover property set to True). They can also be three-dimensional (standard) or flat depending on the ButtonStyle property. Set the following properties: Property C1DbNavigator1.ButtonStyle C1DbNavigator1.ColorButtons C1DbNavigator2.ButtonStyle C1DbNavigator2.ColorButtons C1DbNavigator3.ButtonStyle C1DbNavigator3.ColorButtons Value Standard True Standard True Standard True

Using properties UIStrings and ButtonToolTips, it is also possible to change the text displayed in the navigator and to change button tooltips. For instance, we could specify the first button tooltip as Select the first customer instead of the default First record. These properties can also be used to localize your application. Run the program and observe the following: By pressing the navigator buttons, you can move through the rows. If you press the Next button and hold it for a certain time (determined by the MoveDelayFirst property), the current position will change automatically with frequency determined by the MoveDelayNext property. You can jump to any row number by typing the number in the navigator position area in C1DbNavigator1. You can also use arrow keys and mouse wheel in that area to move to next or previous rows. HOME and END keys move to the first and last row. PAGE UP and PAGE DOWN keys or mouse wheel with CTRL key pressed to page through the rowset. If you change the value in a grid cell and press Cancel, the modified value will revert to the original value. You can add new rows with the Add button and delete rows with the Delete button.

Using C1TextBox for Date-Time Input 69

You can send changes to the database with Update button and re-fetch data from the database (discarding the changes you may have made) with the Refresh button.

Using C1TextBox for Date-Time Input


When editing date-time data with the property DateTimeInput set to True, the C1TextBox and C1DateEdit controls work in a special mode. In this mode, instead of editing date-time values as regular strings, they are divided into separate fields for month, day, hour, and so on. It looks similar to the standard DateTimePicker control. However, C1TextBox and C1DateEdit support more formats than the standard DateTimePicker control and have many additional features, such as time zone adjustment, culture-dependent date formatting, and so on. 1. Create a new Windows Application project. Place the following components on the form as shown in the figure: C1ExpressTable1 (C1.Data.Express.C1ExpressTable) C1Label1-9 (C1.Win.C1Input.C1Label): C1Label1.TextDetached C1Label1.Text C1Label3.TextDetached C1Label3.Text C1Label4.TextDetached C1Label4.Text C1Label5.TextDetached C1Label5.Text C1Label6.TextDetached C1Label6.Text C1Label8.TextDetached C1Label8.Text C1Label9.TextDetached C1Label9.Text True OrderID: True Order Date: True Required Date: True Shipped Date/Time (in local time zone): True Shipped Date/Time (stored in Mountain Standard Time GMT-07:00): True Enter date using Thai Buddist calendar: True Time in custom format (HH:mm:ss:fff):

C1TextBox1-5 (C1.Win.C1Input.C1TextBox) C1DbNavigator1 (C1.Win.C1Input.C1DbNavigator) Button1 (System.Windows.Forms.Button): Name Text btnClose Close

70 C1Input Tutorials

2.

Add the following to the ConnectionString property of the C1ExpressTable1 control: Provider=Microsoft.Jet.OLEDB.4.0;Data Source="C:\Program Files\ComponentOne Studio.NET 2.0\Common\NWIND.MDB". For the C1ExpressTable1 component, open the DbTableName property combo box and select Orders from the database table list. Also, you need to set the AutoIncrement property of the OrderID field of C1ExpressTable1, otherwise you will not be able to update data in the database. Select C1ExpressTable1, click the ellipsis button in the Properties window for the Fields property to open the Fields dialog box, select the OrderID field and set its AutoIncrement property to ClientAnd Server. This is necessary because OrderID is an autoincrement field in the database, so it must be treated accordingly by C1DataExpress. Bind controls to the data source by setting the following properties: Property C1DbNavigator1.DataSource C1Label2.DataSource C1Label2.DataField C1TextBox1.DataSource C1TextBox1.DataField C1TextBox2.DataSource C1TextBox2.DataField C1TextBox3.DataSource C1TextBox3.DataField C1Label7.DataSource C1Label7.DataField Value C1ExpressTable1 C1ExpressTable1 OrderID C1ExpressTable1 OrderDate C1ExpressTable1 RequiredDate C1ExpressTable1 ShippedDate C1ExpressTable1 ShippedDate

3.

4.

Using C1TextBox for Date-Time Input 71

5.

Set up the navigator control C1DbNavigator1. Set its PositionVisible property to False and ColorButtons property to True. Expanding the VisibleButtons property, set the following flags to True: First, Previous, Next, Last, Apply, Cancel, Update, and Refresh. Create the following event handlers (see the Data Navigation and Actions Using C1DbNavigator (page 65) tutorial for details): Visual Basic Private Sub C1DbNavigator1_RefreshData(ByVal sender As Object, ByVal e As System.EventArgs) Handles C1DbNavigator1.RefreshData C1ExpressTable1.ExpressConnection.Fill() End Sub Private Sub C1DbNavigator1_UpdateData(ByVal sender As Object, ByVal e As System.EventArgs) Handles C1DbNavigator1.UpdateData C1ExpressTable1.ExpressConnection.Update() End Sub C# private void C1DbNavigator1_RefreshData(object sender, System.EventArgs e) { C1ExpressTable1.ExpressConnection.Fill(); } private void C1DbNavigator1_UpdateData(object sender, System.EventArgs e) { C1ExpressTable1.ExpressConnection.Update(); } Delphi procedure TWinForm1.C1DbNavigator1_UpdateData(sender: System.Object; e: System.EventArgs); begin C1ExpressConnection1.Update; end; procedure TWinForm1.C1DbNavigator1_RefreshData(sender: System.Object; e: System.EventArgs); begin C1ExpressConnection1.Fill; end;

6.

In C1TextBox1, we will represent the OrderDate in a full format, with full day of week, day, full month name and year. To specify that, set the FormatType property to LongDate. Property C1TextBox1.FormatType Value LongDate

Since we leave the DateTimeInput property with its default value True, we will get date-time editing with separate fields for day of week, month, day and year at run time. In the C1TextBox2 control we use the ShortDate format. Property C1TextBox2.FormatType Value ShortDate

LongDate and ShortDate are examples of standard .NET formats. Their actual representation depends on the regional settings controlled by the Culture property.

72 C1Input Tutorials

7.

The C1TextBox3 control demonstrates how you can represent a date in different formats depending on whether it is in edit or display mode (whether it has the input focus). We will make it LongDateShortTime when the control does not have input focus, and in edit mode, when it has input focus, we will use custom format with time zone. To begin with the custom format, set the following properties: Property C1TextBox3.FormatType C1TextBox3.CustomFormat Value CustomFormat MM/dd/yyyy h:mm tt zzz

This format is the controls default format (where tt is the AM/PM designator and zzz is the time zone representation). We can override it, and other format-related properties, for display and/or edit mode using properties DisplayFormat and EditFormat. Expand the DisplayFormat property, then expand its sub-property (Inherit) and select False for the FormatType flag. That will break the inheritance from control for the FormatType property and allow us to change it. Set this property, and also set the FormatType property for C1Label7 at this time to the following: Property C1TextBox3.DisplayFormat.FormatTyp e C1Label7.FormatType 8. Value LongDateShortTime LongDateShortTime

Specify how NULL values (DBNull) are displayed in C1TextBox3 and in C1Label7. Set the following properties: Property C1TextBox3.NullText C1TextBox3.EmptyAsNull C1Label7.NullText Value (not shipped yet) True (null)

By default, clearing the control (select all and pressing DELETE) reverts it to the value it had before editing once the control loses focus. We changed this behavior setting the EmptyAsNull property to True, now clearing the control sets its value to DBNull. 9. The C1TextBox3 control also demonstrates the time zone adjustment feature. It is useful in situations where information is entered into the database by operators located in different time zones. Then it is convenient to show and edit dates for each operator in his or her local time, but store the entered dates in the database adjusted to a single, unified time zone. Suppose the database server is located in Mountain Time zone (7 hours to the West from GMT, Greenwich Mean Time). To enable time zone adjustment, set the controls CurrentTimeZone property to False. This will make the GMTOffset property modifiable. Set the GMTOffset property to 07:00 (Mountain Standard Time). Now C1TextBox3 converts all values to the local time before displaying them, and vice versa, converts values entered by the user to the Mountain Time zone.

10. The next control, C1TextBox4 demonstrates how date input can be localized for any culture supported in .NET. Set the Culture property to Thai (Thailand) and FormatType to LongDate. Then date format, including month names and year number, will be defined by the Thai Buddhist calendar. 11. The last control, C1TextBox5 allows you to enter precise time with milliseconds. Set the FormatType property to CustomFormat and the CustomFormat property to HH:mm:ss.fff. Since this control is not data bound, to start editing from a non-empty value, set the Value property to some date-time value. Run the program and observe the following: Due to the setting the DateTimeInput property to True, you can edit date-time fields, such as year, month, day separately. You can type on the keyboard (months are entered numerically even if month name is shown) or use arrow keys or mouse wheel to advance a field. The AM/PM designator can be changed typing the first letter.

Data Validation 73

When the C1TextBox3 control takes focus, the date format in it changes. You can specify the time zone in which the date is entered. By default, it is your local time zone. When you enter a date in C1TextBox3 and move focus away from the control, the C1Label8 control below shows the actual value stored in the database (and in the controls Value property). It is adjusted to the Mountain Time zone.

Data Validation
The main feature of C1TextBox that distinguishes it from the standard TextBox control is that it works with typed data. When the user enters something in a C1TextBox control (or its descendant, C1DateEdit or C1NumericEdit), the input string undergoes several transition phases before it becomes a typed value of the Value property. The input string goes through the following transition phases: 1. Edit mask parsing The first phase is edit mask parsing (if an edit mask is active, see the Masked Input (page 57) tutorial), extracting the stored content string out of the masked string displayed in the control. 2. PreValidation The next phase is PreValidation of the input string. This validation is always performed over a string value, regardless of the DataType, since at this time the input string is not yet converted to a typed value (not yet parsed). 3. Parsing The next phase after pre-validation is parsing, that is, conversion to the required data type specified in the DataType property. 4. PostValidation The last phase before modifying the Value property is PostValidation that is performed over the typed value obtained by parsing. If the value satisfies the PostValidation conditions, it is assigned to the Value property. Of course, all these phases are optional, except parsing (and that is optional too, if DataType is set to String), they only occur if you specify validation conditions in corresponding properties. This tutorial demonstrates pre-validation and post-validation, that is, how you can perform validation logic before and after parsing the input string. 1. Create a new Windows Application project. Place the following components on the form as shown in the figure: C1ExpressConnection (C1.Data.Express.C1ExpressConnection) C1ExpressTable1-2 (C1.Data.Express.C1ExpressTable) C1Label1-8 (C1.Win.C1Input.C1Label): C1Label2.TextDetached C1Label2.Text C1Label3.TextDetached C1Label3.Text C1Label4.TextDetached C1Label4.Text C1Label5.TextDetached C1Label5.Text True Validation Before Parsing True Country (Canada, France, Germany, UK, or USA): True Phone Number: True Fax:

74 C1Input Tutorials

C1Label6.TextDetached C1Label6.Text C1Label7.TextDetached C1Label7.Text C1Label8.TextDetached C1Label8.Text C1TextBox1-5

True Validation After Parsing True Unit Price (from $0 to $10000, but not $12): True Reorder Level:

C1DbNavigator1-2 (C1.Win.C1Input.C1DbNavigator) Button1 (System.Windows.Forms.Button): Name Text btnClose Close

2.

Select the C1ExpressConnection1 component, go to the Properties window, open the ConnectionString property combo box. Add the following to the ConnectionString property: Provider=Microsoft.Jet.OLEDB.4.0;Data Source="C:\Program Files\ComponentOne Studio.NET 2.0\Common\NWIND.MDB".

Data Validation 75

3.

Set the properties of C1ExpressTable1-2 as follows: Property C1ExpressTable1.ConnectionComponent C1ExpressTable1.DbTableName C1ExpressTable2.ConnectionComponent C1ExpressTable2.DbTableName Value C1ExpressConnection1 Customers C1ExpressConnection1 Products

4.

To bind controls to the data source, set the following properties: Property C1DbNavigator1.DataSource C1DbNavigator2.DataSource C1Label1.DataSource C1Label1.DataField C1TextBox1.DataSource C1TextBox1.DataField C1TextBox2.DataSource C1TextBox2.DataField C1TextBox3.DataSource C1TextBox3.DataField C1TextBox4.DataSource C1TextBox4.DataField C1TextBox5.DataSource C1TextBox5.DataField Value C1ExpressTable1 C1ExpressTable2 C1ExpressTable1 CompanyName C1ExpressTable1 Country C1ExpressTable1 Phone C1ExpressTable1 Fax C1ExpressTable2 UnitPrice C1ExpressTable2 UnitsInStock

5.

Set up the navigator controls. For both C1DbNavigator1 and C1DbNavigator2 set the PositionVisible property to False. In C1DbNavigator1 show two additional buttons using the VisibleButtons property: Cancel and Apply. The top part of the form contains controls demonstrating pre-validation, the bottom part demonstrates post-validation. The first editable control, C1TextBox1 allows you to enter a country name from a list of allowed countries. Expand the PreValidation property of that control and set its PatternString sub-property to Canada, France, Germany, UK, USA. The separator string dividing the list to separate items is specified in the ItemSeparator property. Although we could use the default "|", set ItemSeparator to ", " (comma and space) for better readability. The fact that PatternString represents an exact list of values to match the input string against is indicated by the value of the PreValidation.Validation property set to ExactList. This is default, so we do not have to change it. Property PreValidation.PatternString PreValidation.ItemSeparator Value Canada, France, Germany, UK, USA ,

6.

76 C1Input Tutorials

7.

The next control, C1TextBox2 validates user input using wildcard patterns. The input string is a telephone number. Different countries have different conventional phone numbers formats. We allow input strings in any of the three formats, for US, France and Germany. In this case, the PatternString contains three items, each item a wildcard pattern. An input string satisfies the condition if it matches one of the patterns. Expand the PreValidation property and set its sub-properties to the following: Property PreValidation.Valiation PreValidation.PatternString Value Wildcards (*) ###-####|##.##.##.##|##########

8.

Wildcard pattern validation demonstrated in the previous step is often not accurate enough. For instance, you cannot enter three digits instead of four in the third pattern. This kind of validation is better performed with regular expressions. .NET regular expressions are a very powerful means of string validation. The C1TextBox3 control contains a fax number and string validation is specified with the following property settings: Property PreValidation.Valiation PreValidation.PatternString Value RegexPattern (\(\d+\) )?(\d+-\d+|(\d\d.){3}\d\d)

9.

The C1TextBox4 control validates the typed Value for the UnitPrice field (post-validation). The validation condition is that the price must be between 0 and 10,000 (0 and 10,000 included), and the price of $12.00 is not allowed. To specify such constraints, expand the PostValidation property and press the ellipsis button of the Intervals sub-property to open the ValueInterval Collection Editor dialog box. In this dialog box, you can specify one or more intervals. The input value must belong to one of them. Add an interval and set its MinValue to 0 and MaxValue to 10000.

Press OK to close the dialog box. Now specify the excluded value, 12.00. Press the ellipsis button of the ValuesExcluded property, add 12 in the Value Collection Editor that opens and press OK to close the editor.

Data Validation 77

10. The C1TextBox4 control also demonstrates another important feature unrelated to validation. Normally, we want to display a currency value in a Currency format (with dollar sign), but edit it as a simple number (no dollar sign). This is easy to do in C1Input. Just recall from theUsing C1TextBox for Date-Time Input (page 69) tutorial that you can specify different formats for display and edit mode. Set the FormatType to Currency. 11. In C1TextBox5 control validation is performed programmatically, in the PostValidating event code. Set the Validation property to PostValidatingEvent and create the following event handler for the PostValidating event: Visual Basic Private Sub C1TextBox5_PostValidating(ByVal sender As Object, ByVal e As C1.Win.C1Input.PostValidationEventArgs) Handles C1TextBox5.PostValidating If (CType(e.Value, Int16) < 0) Then e.ErrorInfo.ErrorMessage = "Value cannot be less than zero." ElseIf (CType(e.Value, Int16) > 5000) Then e.ErrorInfo.ErrorMessage = "Value cannot be greater than 5000." Else Return End If e.Succeeded = False End Sub C# private void C1TextBox5_PostValidating(object sender, C1.Win.C1Input.PostValidationEventArgs e) { if ((Int16)e.Value < 0) e.ErrorInfo.ErrorMessage = "Value cannot be less than zero."; else if ((Int16)e.Value > 5000) e.ErrorInfo.ErrorMessage = "Value cannot be greater than 5000."; else return;

78 C1Input Tutorials

e.Succeeded = false; } Delphi procedure TWinForm.C1TextBox5_PostValidating(sender: System.Object; e: C1.Win.C1Input.PostValidationEventArgs); begin if (Integer(e.Value) < 0) then e.ErrorInfo.ErrorMessage := 'Value cannot be less than zero.' else if (Integer(e.Value) > 5000) then e.ErrorInfo.ErrorMessage := 'Value cannot be greater than 5000.' else Exit; e.Succeeded := False; end;

This code verifies that the value lies between 0 and 5000. In case of an error, it sets the e.ErrorMessage property that makes the specified message text appear in the error message after the event. Setting e.Suceeded to False indicates that the code has detected a validation error. Run the program and observe the following: When any one of the validation conditions are not satisfied, an attempt to leave the control with incorrect value shows an error message box with caption C1Input Validation Error and a brief error description. In the C1TextBox5 control, the error message is one of the two specified in the code.

Data Formatting and Parsing


This tutorial demonstrates some options in formatting and parsing data. 1. Create a new Windows Application project. Place the following components on the form as shown in the figure: C1ExpressConnection (C1.Data.Express.C1ExpressConnection) C1ExpressTable1-2 (C1.Data.Express.C1ExpressTable) C1Label1-8 (C1.Win.C1Input.C1Label): C1Label1.TextDetached C1Label1.Text C1Label3.TextDetached C1Label3.Text C1Label4.TextDetached C1Label4.Text C1Label5.TextDetached C1Label5.Text C1Label6.TextDetached C1Label6.Text C1Label7.TextDetached C1Label7.Text True Date: True Discontinued: True Order Details True Unit Price: True Discount: True Quantity:

Data Formatting and Parsing 79

C1TextBox1-5 (C1.Win.C1Input.C1TextBox) C1DbNavigator1-2 (C1.Win.C1Input.C1DbNavigator) GroupBox1 (System.Windows.Forms.GroupBox) RadioButton1-5 (all of the type System.Windows.Forms.RadioButton): RadioButton1.Name RadioButton1.Text RadioButton1.Checked RadioButton2.Name RadioButton2.Text RadioButton3.Name RadioButton3.Text RadioButton4.Name RadioButton4.Text RadioButton5.Name RadioButton5.Text rbYesNo Yes/No True rbTrueFalse True/False rbOnOff On/Off rbOneZero 1/0 rbCustom Custom (Yep/Nope)

Button1 (System.Windows.Forms.Button): Name Text btnClose Close

80 C1Input Tutorials

2.

Select the C1ExpressConnection1 component, go to the Properties window, open the ConnectionString property combo box. Add the following to the ConnectionString property: Provider=Microsoft.Jet.OLEDB.4.0;Data Source="C:\Program Files\ComponentOne Studio.NET 2.0\Common\NWIND.MDB". Set the properties of C1ExpressTable1-2 as follows: Property C1ExpressTable1.ConnectionComponent C1ExpressTable1.DbTableName C1ExpressTable2.ConnectionComponent C1ExpressTable2.DbTableName Value C1ExpressConnection1 Products C1ExpressConnection1 Order Details

3.

4.

Create a master-detail relation between C1ExpressTable1 (master) and C1ExpressTable2 (detail). Click the ellipsis button in the Relations property of the C1ExpressionConnection1 control to open the Relations dialog box. In the dialog box, select Products for Parent, Order Details for Child, add a join with ProductID for both Parent field and Child field, and press OK to close the Relations dialog box.

Data Formatting and Parsing 81

5.

To bind controls to the data source, set the following properties: Property C1DbNavigator1.DataSource C1DbNavigator1.DataMember C1DbNavigator2.DataSource C1DbNavigator2.DataMember C1Label2.DataSource C1Label2.DataField C1TextBox2.DataSource C1TextBox2.DataField C1TextBox3.DataSource C1TextBox3.DataField C1TextBox4.DataSource C1TextBox4.DataField C1TextBox5.DataSource C1TextBox5.DataField C1Label8.DataSource C1Label8.DataField Value C1ExpressConnection1 _Products C1ExpressConnection1 _Products.Products - Order_Details C1ExpressConnection1 _Products.ProductName C1ExpressConnection1 _Products.Discontinued C1ExpressConnection1 _Products.Products - Order_Details.UnitPrice C1ExpressConnection1 _Products.Products - Order_Details.Discount C1ExpressConnection1 _Products.Products - Order_Details.Quantity C1ExpressConnection1 _Products.Products - Order_Details.Quantity

6.

For the C1TextBox2 control, bound to the Discontinued field, set the FormatType property to YesNo. This is a Boolean format showing Yes for True and No for False. This will be the default format of the C1TextBox2 control, but we will also make provisions for a custom format, setting the CustomFormat property of the C1TextBox2 control to Yep|Nope. This custom format will be enabled when the FormatType property is set to CustomFormat, which will be done with option buttons in the next step.

82 C1Input Tutorials

7.

To switch the Discontinued field format between various Boolean formats, use the radio buttons. Assign the following event handlers to the radio buttons Click events: Visual Basic Private Sub rbYesNo_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles rbYesNo.Click Me.C1TextBox2.FormatType = C1.Win.C1Input.FormatTypeEnum.YesNo End Sub Private Sub rbTrueFalse_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles rbTrueFalse.Click Me.C1TextBox2.FormatType = C1.Win.C1Input.FormatTypeEnum.TrueFalse End Sub Private Sub rbOnOff_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles rbOnOff.Click Me.C1TextBox2.FormatType = C1.Win.C1Input.FormatTypeEnum.OnOff End Sub Private Sub rbOneZero_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles rbOneZero.Click Me.C1TextBox2.FormatType = C1.Win.C1Input.FormatTypeEnum.Integer End Sub Private Sub rbCustom_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles rbCustom.Click Me.C1TextBox2.FormatType = C1.Win.C1Input.FormatTypeEnum.CustomFormat End Sub C# private void radioButton_Click(object sender, System.EventArgs e) { switch (((RadioButton)sender).Name) { case "rbYesNo": this.c1TextBox2.FormatType = C1.Win.C1Input.FormatTypeEnum.YesNo; break; case "rbTrueFalse": this.c1TextBox2.FormatType = C1.Win.C1Input.FormatTypeEnum.TrueFalse; break; case "rbOnOff": this.c1TextBox2.FormatType = C1.Win.C1Input.FormatTypeEnum.OnOff; break; case "rbOneZero": this.c1TextBox2.FormatType = C1.Win.C1Input.FormatTypeEnum.Integer; break; case "rbCustom": this.c1TextBox2.FormatType = C1.Win.C1Input.FormatTypeEnum.CustomFormat; break; } }

Data Formatting and Parsing 83

Delphi procedure TWinForm.RadioButton1_Click(sender: System.Object; e: System.EventArgs); begin if (sender = RadioButtonYesNo) then Self.C1TextBox2.FormatType := C1.Win.C1Input.FormatTypeEnum.YesNo else if (sender = RadioButtonTrueFalse) then Self.C1TextBox2.FormatType := C1.Win.C1Input.FormatTypeEnum.TrueFalse else if (sender = RadioButtonOnOff) then Self.C1TextBox2.FormatType := C1.Win.C1Input.FormatTypeEnum.OnOff else if (sender = RadioButtonInteger) then Self.C1TextBox2.FormatType := C1.Win.C1Input.FormatTypeEnum.Integer else if (sender = RadioButtonCustomFmt) then Self.C1TextBox2.FormatType := C1.Win.C1Input.FormatTypeEnum.CustomFormat; end;

8.

For C1TextBox3 bound to the UnitPrice field, set the FormatType to Currency. The currency format with dollar sign is used both in display and edit mode. For C1TextBox4 bound to Discount, set the FormatType to Percent (values are displayed and entered times 100 with percent sign). Also, for C1TextBox5 bound to Quantity, set the FormatType to Hexadecimal, so it will be represented in hexadecimal form (think of it as a kind of low-tech encryption; we, of course, need this rather unusual format for purely demonstrational purposes). Now, to decipher the hexadecimal Quantity, we want to convert it to the normal decimal representation and display the decimal number in C1Label8 with suffix (base 10). There is no standard or custom format for such representation, but we can define our own formatting in code, in the Formatting event. If we set the FormatType to UseEvent, our code can perform whatever formatting we need. Create the following event handler: Visual Basic Private Sub C1Label8_Formatting(ByVal sender As Object, ByVal e As C1.Win.C1Input.FormatEventArgs) Handles C1Label8.Formatting e.Text = e.Value.ToString() + " (base10)" End Sub C# private void C1Label8_Formatting(object sender, C1.Win.C1Input.FormatEventArgs e) { e.Text = e.Value.ToString() + " (base10)"; } Delphi procedure TWinForm.C1Label8_Formatting(sender: System.Object; e: C1.Win.C1Input.FormatEventArgs); begin e.Text := e.Value.ToString + ' (base10)'; end;

9.

10. In the C1TextBox1 control we will show how you can allow entering dates in multiple formats. Since this control is unbound, you need to set its DataType property manually. Set the DataType property to DateTime. Initialize its value with the current date in code, in the Form_Load event: Visual Basic Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

84 C1Input Tutorials

Me.C1TextBox1.Value = DateTime.Now End Sub C# private void Form1_Load(object sender, System.EventArgs e) { this.c1TextBox1.Value = DateTime.Now; } Delphi procedure TWinForm.TWinForm_Load(sender: System.Object; e: System.EventArgs); begin Self.C1TextBox1.Value := DateTime.Now end;

The DateTimeInput mode (see theUsing C1TextBox for Date-Time Input (page 69) tutorial) only works with a single date format, so we need to turn it off by setting the DateTimeInput property to False for the C1TextBox1 control. Set the custom format as follows: Property C1TextBox1.DateTimeInput C1TextBox1.FormatType C1TextBox1.CustomFormat Value False CustomFormat MM/dd/yyyy|d-MMMyyyy|d.M.yy

This is a list of allowed formats separated with '|'. Parsing an input string, all formats will be tried until a matching one found. Formatting values for display, we obviously need a single format, so only the first format will be used for formatting. We also want the control to display the date in LongDate format when not in focus. Expand the DisplayFormat property, and set FormatType to LongDate. Now the control shows its date value in long format when not in focus, in the first short format when in focus, and the user can type data in any of the three allowed sort formats. Run the program and observe the following: By selecting different option buttons you can see how Discontinued is shown in different formats. The currently selected format also determines how Discontinued values can be entered by the user. Note also that you can enter Boolean values in abbreviated form; just the initial letter is enough for all formats except On/Off where you need to enter the first two letters. Using the 1/0 format, entering any number except 0 results in a True value, which corresponds to the standard .NET conversion from integer to Boolean. In the UnitPrice field you can enter or omit the dollar sign. Negative numbers can be entered both with minus sign and in parentheses, according to financial conventions. The Discount field allows you to enter the optional percent sign. When you enter a value in percent, it is automatically divided by 100 when it is saved in the data source. You can enter the date in the control at the bottom in any of the three allowed formats, as it is most convenient to you. For instance June 5, 2002 can be entered as 06/05/2002, or 5-Jun-2002, or 5.6.02.

Using C1DateEdit and C1NumericEdit Controls


The C1DateEdit control provides enhanced date-time editing capabilities. It derives from C1TextBox, so it supports DateTimeInput with separate fields for year, month, date, and so on, and all options for formatting and parsing date-time values. In addition to that, it enables the user to select date in a drop-down calendar, and also to increment/decrement date fields in DateTimeInput mode with up/down buttons.

Using C1DateEdit and C1NumericEdit Controls 85

The C1NumericEdit control is specialized for numeric input. It also derives from C1TextBox, which enables it with formatting, parsing and validation functionality. In addition to that, it allows the user to increment/decrement the value by a specified amount using the up/down buttons, and to use a drop-down calculator to calculate values. 1. Create a new Windows Application project. Place the following components on the form as shown in the figure: C1ExpressConnection (C1.Data.Express.C1ExpressConnection) C1ExpressTable1-2 (C1.Data.Express.C1ExpressTable) C1Label1-10 (C1.Win.C1Input.C1Label): C1Label1.TextDetached C1Label1.Text C1Label3.TextDetached C1Label3.Text C1Label4.TextDetached C1Label4.Text C1Label5.TextDetached C1Label5.Text C1Label6.TextDetached C1Label6.Text C1Label7.TextDetached C1Label7.Text C1Label9.TextDetached C1Label9.Text C1Label10.TextDetached C1Label10.Text True Order True Order Date: True Freight: True Required Date: True Shipped Date: True Order Details True Quantity: True Unit Price:

C1DateEdit1-3 (C1.Win.C1Input.C1DateEdit) C1NumericEdit1-3 (C1.Win.C1Input.C1NumericEdit) C1DbNavigator1-2 (C1.Win.C1Input.C1DbNavigator)

86 C1Input Tutorials

2.

Select the C1ExpressConnection1 component, go to the Properties window, open the ConnectionString property combo box. Add the following to the ConnectionString property: Provider=Microsoft.Jet.OLEDB.4.0;Data Source="C:\Program Files\ComponentOne Studio.NET 2.0\Common\NWIND.MDB". Set the properties of C1ExpressTable1-2 as follows: Property C1ExpressTable1.ConnectionComponent C1ExpressTable1.DbTableName C1ExpressTable2.ConnectionComponent C1ExpressTable2.DbTableName Value C1ExpressConnection1 Orders C1ExpressConnection1 Order Details

3.

4.

Create a master-detail relation between C1ExpressTable1 (master) and C1ExpressTable2 (detail). Press the ellipsis button in the Relations property of the C1ExpressionConnection1 control to open the Relations dialog box. In the dialog box, select Orders for Parent, Order Details for Child, add a join with OrderID for both Parent field and Child field, press OK to close the Relations dialog box.

Using C1DateEdit and C1NumericEdit Controls 87

5.

To bind controls to the data source, set the following properties: Property C1DbNavigator1.DataSource C1DbNavigator1.DataMember C1DbNavigator2.DataSource C1DbNavigator1.DataMember C1Label2.DataSource C1Label2.DataField C1DateEdit1.DataSource C1DateEdit1.DataField C1DateEdit2.DataSource C1DateEdit2.DataField C1DateEdit3.DataSource C1DateEdit3.DataField C1NumericEdit1.DataSource C1NumericEdit1.DataField C1Label8.DataSource C1Label8.DataField C1NumericEdit2.DataSource C1NumericEdit2.DataField C1NumericEdit3.DataSource C1NumericEdit3.DataField Value C1ExpressConnection1 _Orders C1ExpressConnection1 _Orders.Orders - Order Details C1ExpressConnection1 _Orders.OrderID C1ExpressConnection1 _Orders.OrderDate C1ExpressConnection1 _Orders.RequiredDate C1ExpressConnection1 _Orders.ShippedDate C1ExpressConnection1 _Orders.Freight C1ExpressConnection1 _Orders.Orders - Order Details.ProductID C1ExpressConnection1 _Orders.Orders - Order Details.Quantity C1ExpressConnection1 _Orders.Orders - Order Details.UnitPrice

6.

Set up the OrderDate field (C1DateEdit1) for a simple date input with a drop-down calendar as the main means of entering a date. Turn off the DateTimeInput mode setting the DateTimeInput property to False. Make the calendar center-aligned relative to the control by setting the DropDownAlign property to Center.

88 C1Input Tutorials

7.

The next control, C1DateEdit2 (RequiredDate field) will serve as a regular date-time input control, in DateTimeInput mode, without a drop-down calendar. Set the VisibleButtons property to UpDown. To use the long date format, set the FormatType property to LongDate. The ShippedDate field (control C1DateEdit3) will contain dates in MediumDate format (set its FormatType property to MediumDate), with up/down buttons and a drop-down calendar. Since ShippedDate can be NULL (DBNull), set the EmptyAsNull property to True. Then clearing the control contents will be equivalent to entering null value. Suppose we want certain days to appear bold in the drop-down calendar. To do that, expand the Calendar property, select the calendar property MonthlyBoldedDates and add two dates to the array using the Collection Editor dialog box. Now we will set up controls for numeric input. The C1NumericEdit1 control is bound to the Freight field. Set its FormatType to Currency and hide the up/down buttons (it does not make much sense for them to be a currency value) setting VisibleButtons property to UpDown. Set the TextAlign property to Right. Also set the DropDownAlign property to Right to make the drop-down calculator right-aligned as well.

8.

9.

10. The Quantity field (C1NumericEdit2) does not need a drop-down calculator, so hide it setting the VisibleButtons property to UpDown. Since Quantity is an integer number, set the FormatType property to Integer. Set the increment for up/down buttons to a certain value you prefer, for example, to 3. You can also change the controls appearance if you feel inclined to, for example, setting the BorderStyle property to FixedSingle. 11. The last field (C1NumericEdit3) allows the user to enter a currency value UnitPrice using a drop-down calculator. Set the FormatType property to Currency. As in the previous control, set the BorderStyle property to FixedSingle, just to see that you have all the usual appearance options at your disposal. Hide the up/down buttons (unnecessary for a currency field) setting the VisibleButtons property to UpDown. To center the drop-down calendar relative to the control, set the DropDownAlign property to Center. Run the program and observe the following: The OrderDate field allows you to enter a date from the keyboard, or open the drop-down calendar and select a date there with the mouse or arrow keys. In the drop-down calendar you can see the buttons for changing the month and year. At the bottom of the calendar you see the Clear and Today button. The Clear button sets the Value to DBNull, and the Today button sets it to the todays date (that can be overridden in the Calendar.TodayDate property). Select a date field in RequiredDate and press the up/down buttons. Notice that you can enter a date without using keyboard. In the drop-down calendar in ShippedDate, you can see two bolded dates. Opening the drop-down calculator in the Freight and Quantity fields, you can see different button styles in the calculator.

Custom Drop-Down Form


C1DropDownControl is a control derived from C1TextBox, so it supports all its formatting, validation and other features. As the other two C1TextBox-derived controls, it also supports up-down and drop-down buttons. However, unlike those specialized controls, C1DropDownControl allows you to attach your own logic to the up/down buttons and your own drop-down form/editor to the drop-down button. In this tutorial we will create a form that can be used to show a list of MRU (most recently used) values. Note that although we will use this form in only one control, the same form without modification can be used in any number of controls in your projects. Note: Before opening Form1 at design time, you need to compile the tutorial project. Otherwise a class not found error will appear. This is because the drop-down form class needs to be compiled to become available in the DropDownFormClass property of a C1DropDownControl.

Custom Drop-Down Form 89

1. 2.

Create a new Windows Application project. Place a C1DropDownControl (C1DropDownControl1) on the form. Add a form derived from drop-down form to your project. To do this, from the Solution Explorer rightclick the project and select Add New Item from the Add sub-menu. In the Add New Item dialog box, select Windows Form from the list of Templates in the right pane. Then enter MRUDropDown.vb for Visual Basic (MRUDropDown.cs for C#) in the Name box.

3.

The next step is to replace the following class definition line(s) in the MRUDropDown form code. Select Code from the View menu and replace the code below: Visual Basic Public Class MRUDropDown Inherits System.Windows.Forms.Form C# public class MRUDropDown : System.Windows.Forms.Form Delphi TMRUDropDown = class(System.Windows.Forms.Form) Visual Basic Public Class MRUDropDown Inherits C1.Win.C1Input.DropDownForm C# public class MRUDropDown : C1.Win.C1Input.DropDownForm Delphi TMRUDropDown = class(C1.Win.C1Input.DropDownForm)

with:

4.

From the Properties window, expand the Options property node of the MRUDropDown form. Set Option.Focusable to False and Option.AutoResize to True. The AutoResize option will make the width of the drop-down always equal the width of the control, and Focusable option set to False is needed because we do not want the drop-down form to take input focus. Instead, we want focus to remain in the control so the user can type in the control and select from the drop-down at the same time. Place a ListBox control (ListBox1) on the drop-down form. To make the list box occupy the whole dropdown area, set the following ListBox1 properties: Property ListBox1.DockStyle ListBox1.IntegralHeight ListBox1.BorderStyle Value Fill False None

5.

6.

To make the form open automatically when the user starts typing in the control, use the OwnerControlTextChanged event, add the following event handler: Visual Basic Private Sub MRUDropDown_OwnerControlTextChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.OwnerControlTextChanged OwnerControl.OpenDropDown() ListBox1.SelectedIndex = listBox1.FindString(OwnerControl.Text) End Sub C# private void MRUDropDown_OwnerControlTextChanged(object sender, System.EventArgs e)

90 C1Input Tutorials

{ OwnerControl.OpenDropDown(); listBox1.SelectedIndex = listBox1.FindString(OwnerControl.Text); } Delphi procedure TMRUDropDown.TMRUDropDown_OwnerControlTextChanged(sender: System.Object; e: System.EventArgs); begin OwnerControl.OpenDropDown; ListBox1.SelectedIndex := ListBox1.FindString(OwnerControl.Text); end;

The second line selects the list box item corresponding to the current control text, if such item already exists. 7. To enable visual feedback while the user moves the mouse inside the list box, add the following event handler: Visual Basic Private Sub ListBox1_MouseMove(ByVal sender As Object,ByVal e As System.Windows.Forms.MouseEventArgs) Handles ListBox1.MouseMove ListBox1.SelectedIndex = ListBox1.IndexFromPoint(e.X, e.Y) End Sub C# private void listBox1_MouseMove(object sender, System.Windows.Forms.MouseEventArgs e) { listBox1.SelectedIndex = listBox1.IndexFromPoint(e.X, e.Y); } Delphi procedure TMRUDropDown.ListBox1_MouseMove(sender: System.Object; e: System.Windows.Forms.MouseEventArgs); begin ListBox1.SelectedIndex := ListBox1.IndexFromPoint(e.X, e.Y); end;

8.

To enable the user to navigate the drop-down list box with UP and DOWN keys and delete items with CTRL+DEL key, add the following event handler: Visual Basic Private Sub MRUDropDown_KeyDown(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles MyBase.KeyDown If e.Modifiers = Keys.None And e.KeyCode = Keys.Up Then If ListBox1.SelectedIndex > 0 Then ListBox1.SelectedIndex = listBox1.SelectedIndex - 1 OwnerControl.Text = listBox1.Text OwnerControl.SelectAll() End If e.Handled = True End If If e.Modifiers = Keys.None And e.KeyCode = Keys.Down Then If ListBox1.SelectedIndex < listBox1.Items.Count - 1 Then ListBox1.SelectedIndex = listBox1.SelectedIndex + 1 OwnerControl.Text = listBox1.Text OwnerControl.SelectAll() End If e.Handled = True

Custom Drop-Down Form 91

End If If e.Modifiers = Keys.Control And e.KeyCode = Keys.Delete And ListBox1.SelectedIndex >= 0 Then ListBox1.Items.RemoveAt(listBox1.SelectedIndex) e.Handled = True End If End Sub C# private void MRUDropDown_KeyDown(object sender, System.Windows.Forms.KeyEventArgs e) { if (e.Modifiers == Keys.None && e.KeyCode == Keys.Up) { if (listBox1.SelectedIndex > 0) { listBox1.SelectedIndex--; OwnerControl.Text = listBox1.Text; OwnerControl.SelectAll(); } e.Handled = true; } if (e.Modifiers == Keys.None && e.KeyCode == Keys.Down) { if (listBox1.SelectedIndex < listBox1.Items.Count - 1) { listBox1.SelectedIndex++; OwnerControl.Text = listBox1.Text; OwnerControl.SelectAll(); } e.Handled = true; } if (e.Modifiers == Keys.Control && e.KeyCode == Keys.Delete && listBox1.SelectedIndex >= 0) { listBox1.Items.RemoveAt(listBox1.SelectedIndex); e.Handled = true; } } Delphi procedure TMRUDropDown.MRUDropDown_KeyDown(sender: System.Object; e: System.Windows.Forms.KeyEventArgs); begin if ((e.Modifiers = Keys.None) And (e.KeyCode = Keys.Up)) then begin if (ListBox1.SelectedIndex > 0) then begin ListBox1.SelectedIndex := ListBox1.SelectedIndex - 1; OwnerControl.Text := listBox1.Text; OwnerControl.SelectAll; end; e.Handled := true; end; if ((e.Modifiers = Keys.None) And (e.KeyCode = Keys.Down)) then begin if (ListBox1.SelectedIndex < listBox1.Items.Count - 1) then begin

92 C1Input Tutorials

listBox1.SelectedIndex := listBox1.SelectedIndex + 1; OwnerControl.Text := ListBox1.Text; OwnerControl.SelectAll; end; e.Handled := true; end; if ((e.Modifiers = Keys.Control) And (e.KeyCode = Keys.Delete) And (ListBox1.SelectedIndex >= 0)) then begin ListBox1.Items.RemoveAt(ListBox1.SelectedIndex); e.Handled := true; end; end; 9. To select an item and close the drop-down form when the user clicks a list box item, add the following event handler: Visual Basic Private Sub ListBox1_MouseDown(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles ListBox1.MouseDown ListBox1.SelectedIndex = listBox1.IndexFromPoint(e.X, e.Y) CloseDropDown(True) End Sub C# private void listBox1_MouseDown(object sender, System.Windows.Forms.MouseEventArgs e) { listBox1.SelectedIndex = listBox1.IndexFromPoint(e.X, e.Y); CloseDropDown(true); } Delphi procedure TMRUDropDown.ListBox1_MouseDown(sender: System.Object; e: System.Windows. Forms.MouseEventArgs); begin ListBox1.SelectedIndex := ListBox1.IndexFromPoint(e.X, e.Y); CloseDropDown(true); end;

10. To make the drop-down form actually change the control text when it is closed after the user clicks an item, add the following event handler for the PostChanges event: Visual Basic Private Sub MRUDropDown_PostChanges(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.PostChanges If ListBox1.SelectedIndex >= 0 Then OwnerControl.Value = listBox1.Text ElseIf ListBox1.FindStringExact(OwnerControl.Text) < 0 Then ListBox1.Items.Add(OwnerControl.Text) End If End Sub C# private void MRUDropDown_PostChanges(object sender, System.EventArgs e) { if (listBox1.SelectedIndex >= 0) OwnerControl.Value = listBox1.Text; else if (listBox1.FindStringExact(OwnerControl.Text) < 0)

Editing Numbers in NumericInput Mode 93

listBox1.Items.Add(OwnerControl.Text); } Delphi procedure MRUDropDown_PostChanges(sender: System.Object; e: System.EventArgs); begin if listBox1.SelectedIndex >= 0 then OwnerControl.Value := listBox1.Text else if listBox1.FindStringExact(OwnerControl.Text < 0 then listBox1.Items.Add(OwnerControl.Text); end;

11. Now the drop-down form is ready and we can use it in the C1DropDownControl1 in Form1. Open Form1, select C1DropDownContro1, go to the Properties window and select the DropDownFormClassName property. This property allows you to select a dropdown form-derived form from your project. Select <Project Name>.MRUDropDown from the combo box. This is all you need to attach the drop-down form to a control. If needed, you can attach this form to any number of controls the same way. Run the program and observe the following: When you start typing, it automatically opens the drop-down list. The drop-down can also be opened with the drop-down button. After you type something in the control and press ENTER, the next time you open the drop-down you see the typed item in the list. You can navigate the list with the mouse and with UP/DOWN keys, although the list drop-down does not have input focus, the focus remains in the control input area. Clicking a drop-down item with the mouse changes the control text.

Editing Numbers in NumericInput Mode


In this tutorial, you will learn how to use NumericInput mode for editing numeric data. C1TextBox and C1NumericEdit controls have a NumericInput property that is True by default. If the NumericInput property is set to True and DataType is a numeric type, the control functions in numeric mode facilitating typing of digits, decimal point and other numeric characters. 1. Create a new Windows Application project. Place the following components on the form as shown in the figure: C1ExpressTable1 (C1.Data.Express.C1ExpressTable) Label1-7 (System.Windows.Forms.Label): Label1.Text Label2.Text Label3.Text Label4.Text Label5.Text Label6.Text Label7.Text Quantity: Discount: Unit Price: Scientific Number: Hexidecimal Number: CultureInfoSetup Event: Format:

94 C1Input Tutorials

C1DbNavigator1 (C1.Win.C1Input.C1DbNavigator): C1DbNavigator1.Dock Top

C1TextBox1-5 (C1.Win.C1Input.C1TextBox) C1Label1-2 (C1.Win.Input.C1Label) C1NumericEdit1-2 (C1.Win.C1Input.C1NumericEdit)

2.

Select the C1ExpressTable1 component, go to the Properties window, open the ConnectionString property. Add the following to the ConnectionString property: Provider=Microsoft.Jet.OLEDB.4.0;Data Source="C:\Program Files\ComponentOne Studio.NET 2.0\Common\NWIND.MDB". For the C1ExpressTable1 component, open the DbTableName property combo box and select Order Details from the database table list. To bind controls to the data source, set the following properties: Property C1DbNavigator1.DataSource C1TextBox1.DataSource C1TextBox1.DataField C1NumericEdit1.DataSource C1NumericEdit1.DataField C1TextBox2.DataSource Value C1ExpressTable1 C1ExpressTable1 Quantity C1ExpressTable1 Discount C1ExpressTable1

3. 4.

Editing Numbers in NumericInput Mode 95

Property C1TextBox2.DataField 5.

Value UnitPrice

Adjust some appearance properties of the controls: Set BorderStyle to FixedSingle for the controls: C1Label1-2, C1TextBox1-5, C1NumericEdit1-2. Expand the VisibleButtons property of C1DbNavigator1 and make two additional buttons visible: Apply and Cancel. Expand the UIStrings property of C1DbNavigator1 and change Row: to Order Item:. In C1NumericEdit1, set the VisibleButtons property to UpDown (this control will have only up/down buttons, no drop-down). And vice versa, in C1NumericEdit2 we want to have only dropdown calculator, no up/down buttons, so we set its VisibleButtons property to DropDown.

6. 7.

C1TextBox1 represents an integer Quantity field. As an integer, it contains only digits, without decimal point and exponent. To specify integer format, set the C1TextBox1.FormatType to Integer. C1NumericEdit1 is used for editing a Discount field that is represented as a percentage value. This is specified by setting C1NumericEdit1.FormatType to Percent. Also, specify the increment to be used to increase/decrease the value by a fixed amount using the up/down buttons: C1NumericEdit1.Increment to 0.0005. That will make the controls up/down button increment/decrement the value by 0.05%. C1TextBox2 is used to display and edit a UnitPrice field of Decimal type. To show it in currency format, with dollar sign, set C1TextBox2.FormatType to Currency. In this case, the currency sign shown in the value is defined by the current culture setting controlled by C1TextBox2.Culture property. If C1TextBox2.Culture is set to (Current Culture), current system regional settings are used. There are several unbound, not bound to a data source controls in the bottom part of the form. C1NumericEdit2 edits numbers in scientific format, with decimal point and exponent. This control also includes a drop-down calculator. Set C1NumericEdit2.DataType to Decimal (the default) and C1NumericEdit2.FormatType to Scientific. By default, a number in scientific format contains six digits after decimal point and three digits in the exponent. If you need a non-default format, it can be defined in the CustomFormat property.

8.

9.

10. The C1TextBox3 control edits numbers in hexadecimal format. Set C1TextBox3.DataType to Int16 (16bit integer number), C1TextBox3.FormatType to Hexadecimal. In this mode, the user will be able to type only digits 0-9, letters A-F, and minus sign (or change the sign of the number pressing F9). The C1Label control C1Label1 adjacent to C1TextBox3 shows the entered number in the usual decimal format. To connect it to the number, set C1Label1.DataType to Int16 and add an event handler for the ValueChanged event of the C1TextBox3 control: Visual Basic Private Sub C1TextBox3_ValueChanged( ByVal sender As Object, ByVal e As System.EventArgs) Handles C1TextBox3.ValueChanged Try C1Label1.Value = C1TextBox3.Value Catch End Try End Sub C# private void c1TextBox3_ValueChanged(object sender, System.EventArgs e) { try { c1Label1.Value = c1TextBox3.Value; }

96 C1Input Tutorials

catch { } } Delphi procedure TWinForm.C1TextBox3_ValueChanged(sender: System.Object; e: System.EventArgs); begin try C1Label1.Value := C1TextBox3.Value; except end; end;

11. The C1TextBox4 control demonstrates how you can change number format by changing culture settings used in formatting. Set C1TextBox4.DataType to Int32 and C1TextBox4.FormatType to StandardNumber. A number in this format has a sign, thousands separators and decimal point. Settings used for this formatting, such as the sign, thousand separator and decimal point characters, are defined by the current culture settings controlled by the Culture property. You can specify non-default culture settings handling the event C1TextBox4.CultureInfoSetup. For example, we can show negative numbers with the word minus instead of the usual -. We will also suppress the fractional part of the number, and use | as thousands separator. We will also change the group sizes (so they are no longer thousands), make the first (rightmost) group contain one digit, second two digits, third three digits, and all the rest (higher) digits make a single group. This is done by the following event handler: Visual Basic Private Sub C1TextBox4_CultureInfoSetup(ByVal sender As Object, ByVal e As C1.Win.C1Input.CultureInfoSetupEventArgs) Handles C1TextBox4.CultureInfoSetup Dim ci As System.Globalization.CultureInfo = e.CultureInfo ci.NumberFormat.NegativeSign = " minus " ci.NumberFormat.NumberGroupSeparator = "|" ci.NumberFormat.NumberGroupSizes = New Integer() {1, 2, 3, 0} ci.NumberFormat.NumberDecimalDigits = 0 End Sub C# private void c1TextBox4_CultureInfoSetup(object sender, C1.Win.C1Input.CultureInfoSetupEventArgs e) { System.Globalization.CultureInfo ci = e.CultureInfo; ci.NumberFormat.NegativeSign = " minus "; ci.NumberFormat.NumberGroupSeparator = "|"; ci.NumberFormat.NumberGroupSizes = new int[] {1, 2, 3, 0}; ci.NumberFormat.NumberDecimalDigits = 0; } Delphi procedure TWinForm.C1TextBox4_CultureInfoSetup(sender: System.Object; e: C1.Win.C1Input.CultureInfoSetupEventArgs); var ci: System.Globalization.CultureInfo; r: Array of Integer; begin SetLength(r, 4); r[0] := 1; r[1] := 2;

Editing Numbers in NumericInput Mode 97

r[2] := 3; r[3] := 0; ci := e.CultureInfo; ci.NumberFormat.NegativeSign := ' minus '; ci.NumberFormat.NumberGroupSeparator := '|'; ci.NumberFormat.NumberGroupSizes := r; ci.NumberFormat.NumberDecimalDigits := 0; end; 12. C1TextBox5 shows how to specify a custom, non-standard number format. Set DataType to Decimal, FormatType to CustomFormat and CustomFormat to "#,##0,;(###0,);zero". In this format, three colonseparated parts define three different formats used, correspondingly, for positive, negative numbers and zero. Character 0 denotes a required digit, character # specifies an optional digit, and , is the thousands separator. Thousands separator on the right means the number is stored as times 1000 the entered number (per separator). To see the number that is stored when we enter a number in C1TextBox5, we use a C1Label control C1Label2 adjacent to C1TextBox5, set C1Label2.DataType to Decimal and add an event handler for the ValueChanged event of the C1TextBox5 control: Visual Basic Private Sub C1TextBox5_ValueChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles C1TextBox5.ValueChanged C1Label2.Value = C1TextBox5.Value End Sub C# private void c1TextBox5_ValueChanged(object sender, System.EventArgs e) { c1Label2.Value = c1TextBox5.Value; } Delphi procedure TWinForm.C1TextBox5_ValueChanged(sender: System.Object; e: System.EventArgs); begin C1Label2.Value := C1TextBox5.Value; end;

Run the program and observe the following: The user cannot enter arbitrary text in NumericInput mode. For example, if you type a letter, it is ignored. Only characters allowed by the specified format are permitted. Using properties FormatType and CustomFormat, you can specify any standard or custom format supported in .NET (for details see Numeric Format Strings in the .NET documentation). All these formats are used both for display and editing of numeric values. Changing culture settings, you can control literal characters used in formatting and various other format settings.

Working with a Database 99

C1Input Task-Based Help


The task-based help section assumes that you are familiar with programming in the Visual Studio .NET environment, and know how to use C1Input controls in general. If you are a novice to the C1Input for .NET product, please see the C1Input Tutorials (page 49) first. Each topic provides a solution for specific tasks using the C1Input for .NET product. By following the steps outlined in each topic, you will be able to create projects using a variety of C1Input features. Each task-based help topic also assumes that you have created a new .NET project. For additional information on this topic, see Creating a .NET 2.0 Project (page 15).

Working with a Database


The following topics demonstrate how to connect to a database and utilize C1Input features once connected to a database.

Creating a New Connection


1. To create a new connection, select the C1ExpressConnection1.ConnectionString property from the Properties window and select New Connection from the drop-down box. The standard OLE DB Data Link Properties dialog box appears:

100 C1Input Task-Based Help

2. 3.

Select the provider, the database and other necessary connection properties in the dialog box. In these tutorials, we use the standard MS Access Northwind sample database (NWIND.MDB). Select Microsoft Jet 4.0 OLE DB Provider in the Provider tab. Once you have chosen the data you can select the Next button.

4.

In the Connection tab, click on the ellipsis button to add the Nwind.mdb database to the ConnectionString. The Select Access Database dialog box will appear. Enter the path, C:\Program Files\ComponentOne Studio.NET 2.0\Common\NWIND.MDB (or the location of your database) for the Nwind.mdb database. Press OK That will close the Data Link Properties dialog box and put the connection string in the ConnectionString property.

Updating /Refreshing Data from the Database


This topic demonstrates how you can use the Update/Refresh button to send changes and re-fetch data from the database. 1. 2. Add a C1DbNavigator control to your form and select the control to view its Properties window. Expand the VisibleButtons property node and set Update and Refresh to True. Set the default navigation buttons (Next, Previous, First, Last) to False.

Working with a Database 101

3.

Set the PositionVisible property to False. As an option, you can set its ColorButtons property to True for the buttons to have color bitmaps:

4.

To make the Update and Refresh buttons functional, add a Click event handler to the C1DbNavigator component. Enter the following code: Visual Basic Private Sub c1DbNavigator1_UpdateData(sender As Object, e As System.EventArgs) c1ExpressConnection1.Update() End Sub Private Sub c1DbNavigator1_RefreshData(sender As Object, e As System.EventArgs) c1ExpressConnection1.Fill() End Sub C# private void c1DbNavigator1_UpdateData(object sender, System.EventArgs e) { c1ExpressConnection1.Update(); } private void c1DbNavigator1_RefreshData(object sender, System.EventArgs e) { c1ExpressConnection1.Fill(); } Delphi procedure TWinForm1.C1DbNavigator1_UpdateData(sender: System.Object; e: System.EventArgs); begin C1ExpressConnection1.Update; end; procedure TWinForm1.C1DbNavigator1_RefreshData(sender: System.Object; e: System.EventArgs); begin C1ExpressConnection1.Fill; end;

Creating a Master-Detail Relation


This topic shows how to create a master-detail relation between tables, C1ExpressTable1 (master) and C1ExpressTable2 (detail). 1. Select the C1ExpressionConnection1 component to view the Properties window. Press the ellipsis button in the Relations property of the C1ExpressionConnection1 control to open the Relations dialog box.

102 C1Input Task-Based Help

2.

In the dialog box, select Products for Parent, Order Details for Child, and select the Add join button to open the Add new join dialog box:

Add a join with ProductID for both Parent field and Child field. Press OK to close the dialog box. The join should appear as below:

3.

Press OK to close the Relations dialog box.

Adding a Drop-Down Form


1. To add a drop-down form to your project, right-click your project (located in the Solution Explorer) and select Add New Item from the Add sub-menu.

Adding a Drop-Down Form 103

2.

In the Add New Item dialog box, select Windows Form from the list of Templates in the right pane. Then enter DropDownForm1.cs in the Name textbox.

104 C1Input Task-Based Help

3.

The next step is to replace the following class definition line(s) in the DropDownForm code: Visual Basic Public Class DropDownForm1 Inherits System.Windows.Forms.Form C# public class DropDownForm1 : System.Windows.Forms.Form Delphi DropDownForm1 = class(System.Windows.Forms.Form) Visual Basic Public Class DropDownForm1 Inherits C1.Win.C1Input.DropDownForm C# public class DropDownForm1 : C1.Win.C1Input.DropDownForm Delphi DropDown = class(C1.Win.C1Input.DropDownForm)

with:

The form should look like the image below before editing:

Customizing the Drop-Down Editor


The drop-down form below includes option buttons and button controls for the user to make a selection from the C1DropDownControl.

Adding a Drop-Down Form 105

The drop-down form appearance properties have been edited so that the form appears as below:

Select the form class name (for this example, WindowsApplication1.DropDownForm1) in the DropDownFormClassName property of your C1DropDownControl. Notice that when you run the project and select the drop-down arrow, the drop-down form now appears. Set the AcceptButton and CancelButton properties of your DropDownForm1 to button1 and button2, respectively. Select the OK button and set its DialogResult property to OK. Similarly, select the Cancel button and set its DialogResult property to Cancel. To make the drop-down form change the control text when it is closed after the user clicks an item, add the following event handler for the PostChanges event: Visual Basic Private Sub DropDownForm1_PostChanges(sender As Object, e As System.EventArgs) If (MyBase.DialogResult = DialogResult.OK) Then Dim control1 As Control For Each control1 In MyBase.Controls If (TypeOf control1 is RadioButton AndAlso CType(control1, RadioButton).Checked) Then MyBase.OwnerControl.Value = CType(control1, RadioButton).Text End If Next End If End Sub C# private void DropDownForm1_PostChanges(object sender, System.EventArgs e) { if (DialogResult == DialogResult.OK) { foreach (Control control1 in Controls) { if (control1 as RadioButton != null && ((RadioButton)control1).Checked) { OwnerControl.Value = ((RadioButton)control1).Text; } } } }

Enable the button controls on the drop-down form 1. 2. 3.

106 C1Input Task-Based Help

Delphi procedure DropDownForm1_PostChanges(sender: Tobject; e: EventArgs); var control1: Control; begin if (inherited DialogResult = DialogResult.OK) then for control1 in inherited Controls do begin if ((control1 is RadioButton) and (control1 as RadioButton).Checked) then inherited OwnerControl.Value := (control1 as RadioButton).Text end; end;

4.

At design time, select DropDownForm1 to view its properties in the Properties window, and then select the Events button from the Properties toolbar.

Set the DropDownForm1.PostChanges event to DropDownForm1_PostChanges.

5. 6.

To make the OK button (button1) receive focus when the form opens, set the DropDownForm1.FocusControl property to button1. To have a check in the Standard option button, in design time select radiobutton1 and set its Checked property to True.

Customizing the C1DateEdit Control 107

This topic illustrates the following: Your form should appear similar to the form below:

Customizing the C1DropDownControl


This topic shows how you can customize the C1Input.C1DropDownControl. To make only the drop-down button visible, expand the VisibleButtons property node and set UpDown to False. Note that the DropDown default is set to True. The control should now look like the image below:

To make the width of the drop-down form equal to the width of the control, select the drop-down form and set Options.AutoResize to True.

Customizing the C1DateEdit Control


This topic demonstrates how to customize the drop-down of a C1DateEdit control. By default, the drop-down appears like the image below:

Button Visibility You can hide the Clear and Today buttons by performing the following tasks: 1. 2. Select the C1DateEdit control. In the Properties window, expand the Calendar property node. Set the ShowClearButton and ShowTodayButton properties to False.

108 C1Input Task-Based Help

Format Display The FormatType property allows you to edit the date displayed in the box. By default, the date and time are displayed in the box. To only show the date, perform the following task: Select the C1DateEdit control. In the Properties window, set the FormatType property to ShortDate.

C1.Win.C1Input.2 Assembly 109

C1.Win.C1Input.2 Assembly
Namespaces
C1.Win.C1Input

C1.Win.C1Input Namespace
C1.Win.C1Input Hierarchy

Classes
Class ButtonImages C1DateEdit C1DbNavigator Description Images for C1DropDownControl buttons. Displays and edits date and/or time values. Includes a drop-down calendar for easy input of datetime values. Data bound control providing buttons for convenient navigation over data source rows, moving to the first, last, previous and next row and performing common data actions such as updating the data source and refreshing data. Base class for C1DateEdit and C1NumericEdit controls. Includes support for drop-down and up/down buttons. Read-only data bound control displaying formatted data. C1Label supports all formatting features of the C1TextBox control. Displays and edits numeric values. Includes a dropdown calculator for easy input of numeric values. In addition to the standard PictureBox functionality, C1PictureBox supports data binding to data source fields containing image data. The main data bound control used for entering and editing information in a text form. Supports data formatting for all data types, including special features for date-time formats. Also supports edit mask, data validation and other features. Custom user-defined characters (placeholders) used in edit mask and in wildcard patterns in pre-validation. The calendar used as a drop-down in the C1DateEdit control. Represents the class of drop-down calculator form. The drop-down calendar form. Base class for custom drop-down forms. Settings affecting error handling.

C1DropDownControl

C1Label

C1NumericEdit C1PictureBox

C1TextBox

CustomPlaceholder DateEditMonthCalendar DropDownCalculator DropDownCalendar DropDownForm ErrorInfo

110 C1.Win.C1Input Namespace

Class FormatInfo HighlightingToolBar Margins MaskInfo NumericEditCalculator ParseInfo PlaceholderCollection PostValidation PreValidation UIStrings UIStringsItemEventArgs ValueInterval ValueIntervalCollection

Description Settings for data formatting, converting data to string. This class is for internal use only. Represents the four margins around a control's content. Contains edit mask settings. The calculator used as a drop-down in the C1NumericEdit control. Contains settings affecting parsing, that is, converting a string to the required data type. A collection of CustomPlaceholder objects. Validating the typed value after parsing, after the input string has been converted to the DataType. Validating the input string entered by the user, before parsing.

An interval in a collection of intervals of possible values used in post-validation. A collection of ValueInterval objects used by a PostValidation object. The collection is used if the Validation = PostValidationTypeEnum.ValuesAndIntervals or if the user calls the ValidateValuesAndIntervals method.

See Also C1.Win.C1Input.2 Assembly

C1.Win.C1Input Hierarchy
System.Object C1.Win.C1Input.ButtonImages System.MarshalByRefObject C1.Win.C1Input.FormatInfo ---- System.IDisposable C1.Win.C1Input.MaskInfo ---- System.ComponentModel.ICustomTypeDescriptor, System.IDisposable, System.ComponentModel.ISupportInitialize C1.Win.C1Input.ParseInfo ---- System.ComponentModel.ICustomTypeDescriptor, System.IDisposable C1.Win.C1Input.PostValidation ---- System.IDisposable C1.Win.C1Input.PreValidation ---- System.IDisposable System.ComponentModel.Component System.Windows.Forms.Control C1.Win.C1Input.NumericEditCalculator System.Windows.Forms.Label

ButtonImages Class 111

C1.Win.C1Input.C1Label ---- System.ComponentModel.ICustomTypeDescriptor, System.ComponentModel.ISupportInitialize System.Windows.Forms.MonthCalendar C1.Win.C1Input.DateEditMonthCalendar System.Windows.Forms.PictureBox C1.Win.C1Input.C1PictureBox ---- System.ComponentModel.ICustomTypeDescriptor System.Windows.Forms.ScrollableControl System.Windows.Forms.ContainerControl System.Windows.Forms.Form C1.Win.C1Input.DropDownForm ---- System.Windows.Forms.IMessageFilter C1.Win.C1Input.DropDownCalculator C1.Win.C1Input.DropDownCalendar System.Windows.Forms.UserControl C1.Win.C1Input.C1DbNavigator ---- System.ComponentModel.ISupportInitialize System.Windows.Forms.TextBoxBase System.Windows.Forms.TextBox C1.Win.C1Input.C1TextBox ---- [as], a1, System.ComponentModel.ICustomTypeDescriptor, System.ComponentModel.ISupportInitialize, q C1.Win.C1Input.C1DropDownControl C1.Win.C1Input.C1DateEdit C1.Win.C1Input.C1NumericEdit System.Windows.Forms.ToolBar C1.Win.C1Input.HighlightingToolBar System.EventArgs C1.Win.C1Input.UIStringsItemEventArgs C1.Win.C1Input.CustomPlaceholder ---- System.ICloneable, System.Runtime.Serialization.ISerializable C1.Win.C1Input.ErrorInfo C1.Win.C1Input.Margins ---- System.ICloneable System.Collections.CollectionBase C1.Win.C1Input.PlaceholderCollection C1.Win.C1Input.ValueIntervalCollection C1.Win.C1Input.UIStrings C1.Win.C1Input.ValueInterval ---- System.ICloneable, System.Runtime.Serialization.ISerializable See Also C1.Win.C1Input Namespace

ButtonImages Class
Images for C1DropDownControl buttons.

112 C1.Win.C1Input Namespace

For a list of all members of this type, see ButtonImages Members. System.Object C1.Win.C1Input.ButtonImages [Visual Basic] Public Class ButtonImages [C#] public class ButtonImages [Delphi] type ButtonImages = class; Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also ButtonImages Members | C1.Win.C1Input Namespace

ButtonImages Members
ButtonImages overview Public Properties DownImage DropImage ModalImage UpImage See Also ButtonImages Class | C1.Win.C1Input Namespace Image for Down button. Image for Drop-Down button. Image for Modal button. Image for Up button.

ButtonImages Properties
The properties of the ButtonImages class are listed here. For a complete list of ButtonImages class members, see the ButtonImages Members topic. Public Properties DownImage DropImage ModalImage UpImage See Also ButtonImages Class | C1.Win.C1Input Namespace Image for Down button. Image for Drop-Down button. Image for Modal button. Image for Up button.

ButtonImages.DownImage Property
Image for Down button.

ButtonImages.DropImage Property 113

[Visual Basic] Public Property DownImage As Image [C#] public Image DownImage {get;set;} [Delphi] public property DownImage: Image read get_DownImage write set_DownImage; See Also ButtonImages Class | ButtonImages Members | C1.Win.C1Input Namespace

ButtonImages.DropImage Property
Image for Drop-Down button. [Visual Basic] Public Property DropImage As Image [C#] public Image DropImage {get;set;} [Delphi] public property DropImage: Image read get_DropImage write set_DropImage; See Also ButtonImages Class | ButtonImages Members | C1.Win.C1Input Namespace

ButtonImages.ModalImage Property
Image for Modal button. [Visual Basic] Public Property ModalImage As Image [C#] public Image ModalImage {get;set;} [Delphi] public property ModalImage: Image read get_ModalImage write set_ModalImage; See Also ButtonImages Class | ButtonImages Members | C1.Win.C1Input Namespace

ButtonImages.UpImage Property
Image for Up button. [Visual Basic] Public Property UpImage As Image [C#] public Image UpImage {get;set;}

114 C1.Win.C1Input Namespace

[Delphi] public property UpImage: Image read get_UpImage write set_UpImage; See Also ButtonImages Class | ButtonImages Members | C1.Win.C1Input Namespace

C1DateEdit Class
Displays and edits date and/or time values. Includes a drop-down calendar for easy input of datetime values. For a list of all members of this type, see C1DateEdit Members. System.Object System.MarshalByRefObject System.ComponentModel.Component System.Windows.Forms.Control System.Windows.Forms.TextBoxBase System.Windows.Forms.TextBox C1.Win.C1Input.C1TextBox C1.Win.C1Input.C1DropDownControl C1.Win.C1Input.C1DateEdit [Visual Basic] Public Class C1DateEdit Inherits C1DropDownControl [C#] public class C1DateEdit : C1DropDownControl [Delphi] type C1DateEdit = class (C1DropDownControl);(C1DropDownControl); Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also C1DateEdit Members | C1.Win.C1Input Namespace

C1DateEdit Members
C1DateEdit overview Public Properties AutoCompleteCustomSource (inherited from TextBox) AutoCompleteMode (inherited from TextBox) AutoCompleteSource (inherited from TextBox) The StringCollection to use when the AutoCompleteSource property is set to CustomSource. Indicates the text completion behavior of the text box. The autocomplete source, which can be one of the values from AutoCompleteSource enumeration.

C1DateEdit Members 115

Calendar CanUndo (inherited from TextBoxBase) CharacterCasing (inherited from TextBox) FormatType

The drop-down calendar object. Indicates if the edit control can undo the previous action. Indicates if all characters should be left alone or converted to uppercase or lowercase. Enumeration value determining the formatting method, including standard .NET format specifiers, custom and programmatic formatting. Indicates that the selection should be hidden when the edit control loses focus. Specifies the maximum number of characters that can be entered into the edit control. Indicates the character to display for password input for single-line edit controls. Controls whether the text in the edit control can be changed or not. The currently selected text. The length of the currently selected text. The beginning of the currently selected text. Indicates whether shortcuts defined for the control are enabled. Indicates how the text should be aligned for edit controls. Indicates if the text in the edit control should appear as the default password character. Occurs when the value of the AcceptsTab property changes. Occurs when the value of the BorderStyle property changes. Occurs when the value of the HideSelection property changes. Occurs when the value of the Modified property changes. Occurs when the value of the ReadOnly property changes. Occurs when the value of the TextAlign property changes.

HideSelection (inherited from TextBoxBase) MaxLength (inherited from TextBoxBase) PasswordChar (inherited from TextBox) ReadOnly (inherited from TextBoxBase) SelectedText (inherited from C1TextBox) SelectionLength (inherited from TextBoxBase) SelectionStart (inherited from TextBoxBase) ShortcutsEnabled (inherited from TextBoxBase) TextAlign (inherited from TextBox) UseSystemPasswordChar (inherited from TextBox) Public Events AcceptsTabChanged (inherited from TextBoxBase) BorderStyleChanged (inherited from TextBoxBase) HideSelectionChanged (inherited from TextBoxBase) ModifiedChanged (inherited from TextBoxBase) ReadOnlyChanged (inherited from TextBoxBase) TextAlignChanged (inherited from TextBox) See Also C1DateEdit Class | C1.Win.C1Input Namespace

116 C1.Win.C1Input Namespace

C1DateEdit Properties
The properties of the C1DateEdit class are listed here. For a complete list of C1DateEdit class members, see the C1DateEdit Members topic. Public Properties AutoCompleteCustomSource (inherited from TextBox) AutoCompleteMode (inherited from TextBox) AutoCompleteSource (inherited from TextBox) Calendar CanUndo (inherited from TextBoxBase) CharacterCasing (inherited from TextBox) FormatType The StringCollection to use when the AutoCompleteSource property is set to CustomSource. Indicates the text completion behavior of the text box. The autocomplete source, which can be one of the values from AutoCompleteSource enumeration. The drop-down calendar object. Indicates if the edit control can undo the previous action. Indicates if all characters should be left alone or converted to uppercase or lowercase. Enumeration value determining the formatting method, including standard .NET format specifiers, custom and programmatic formatting. Indicates that the selection should be hidden when the edit control loses focus. Specifies the maximum number of characters that can be entered into the edit control. Indicates the character to display for password input for single-line edit controls. Controls whether the text in the edit control can be changed or not. The currently selected text. The length of the currently selected text. The beginning of the currently selected text. Indicates whether shortcuts defined for the control are enabled. Indicates how the text should be aligned for edit controls. Indicates if the text in the edit control should appear as the default password character.

HideSelection (inherited from TextBoxBase) MaxLength (inherited from TextBoxBase) PasswordChar (inherited from TextBox) ReadOnly (inherited from TextBoxBase) SelectedText (inherited from C1TextBox) SelectionLength (inherited from TextBoxBase) SelectionStart (inherited from TextBoxBase) ShortcutsEnabled (inherited from TextBoxBase) TextAlign (inherited from TextBox) UseSystemPasswordChar (inherited from TextBox) See Also C1DateEdit Class | C1.Win.C1Input Namespace

C1DateEdit.Calendar Property
The drop-down calendar object. [Visual Basic] Public ReadOnly Property Calendar As DateEditMonthCalendar

C1DateEdit.FormatType Property 117

[C#] public DateEditMonthCalendar Calendar {get;} [Delphi] public property Calendar: DateEditMonthCalendar read get_Calendar; See Also C1DateEdit Class | C1DateEdit Members | C1.Win.C1Input Namespace

C1DateEdit.FormatType Property
Enumeration value determining the formatting method, including standard .NET format specifiers, custom and programmatic formatting. [Visual Basic] Public Property FormatType As FormatTypeEnum [C#] new public FormatTypeEnum FormatType {get;set;} [Delphi] public property FormatType: FormatTypeEnum read get_FormatType write set_FormatType; See Also C1DateEdit Class | C1DateEdit Members | C1.Win.C1Input Namespace

C1DateEdit Events
The events of the C1DateEdit class are listed here. For a complete list of C1DateEdit class members, see the C1DateEdit Members topic. Public Events AcceptsTabChanged (inherited from TextBoxBase) BorderStyleChanged (inherited from TextBoxBase) HideSelectionChanged (inherited from TextBoxBase) ModifiedChanged (inherited from TextBoxBase) ReadOnlyChanged (inherited from TextBoxBase) TextAlignChanged (inherited from TextBox) See Also C1DateEdit Class | C1.Win.C1Input Namespace Occurs when the value of the AcceptsTab property changes. Occurs when the value of the BorderStyle property changes. Occurs when the value of the HideSelection property changes. Occurs when the value of the Modified property changes. Occurs when the value of the ReadOnly property changes. Occurs when the value of the TextAlign property changes

118 C1.Win.C1Input Namespace

C1DbNavigator Class
Data bound control providing buttons for convenient navigation over data source rows, moving to the first, last, previous and next row and performing common data actions such as updating the data source and refreshing data. For a list of all members of this type, see C1DbNavigator Members. System.Object System.MarshalByRefObject System.ComponentModel.Component System.Windows.Forms.Control System.Windows.Forms.ScrollableControl System.Windows.Forms.ContainerControl System.Windows.Forms.UserControl C1.Win.C1Input.C1DbNavigator [Visual Basic] Public Class C1DbNavigator InheritsUserControlUserControl ImplementsISupportInitializeISupportInitialize [C#] public class C1DbNavigator :UserControlUserControl ,ISupportInitializeISupportInitialize [Delphi] type C1DbNavigator = class (UserControlUserControl,(UserControlUserControl,ISupportInitializeISupport Initialize); Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator Members
C1DbNavigator overview Public Properties BorderStyle ButtonCursor ButtonSize ButtonStyle ButtonTextAlign Navigator border style. The cursor that is displayed when the mouse is over the navigator buttons. The size of navigator buttons. Navigator button style. Controls how the text is positioned relative to the image in navigator buttons.

C1DbNavigator Members 119

ButtonTexts ButtonToolTips CausesFormValidation ColorButtons ColorWhenHover ConfirmDelete CurrencyManager DataMember DataSource EnabledButtons ErrorProvider HorizontalIndent ImageList ImageListHighlight MoveDelayFirst

Gets or sets the texts displayed on the buttons. The string collection defining navigator button tooltips. Whether the control in focus should be validated before a button click is handled by the navigator. Specifies if navigator buttons have color bitmaps. If True, navigator buttons show color bitmaps when the mouse hovers over them. Whether a confirmation dialog is shown before deleting a record. Gets or sets the CurrencyManager object navigated by the control. For multi-table data sources, specifies a specific table to which the control is bound. The data source object to which the control is bound. Flags enumeration specifying which buttons are enabled. Gets or sets an ErrorProvider object used to indicate error state of the current data row. Horizontal margin between the border and the buttons. Gets or sets the ImageList to use when displaying button images without highlighting. Gets or sets the ImageList to use when displaying button images in highlighted state. Time delay in milliseconds after pressing Next/Previous button before automatic scrolling begins. Time delay in milliseconds between row moves in automatic scrolling. Number of rows to skip when the user presses PAGE UP/DOWN. Specifies whether the editable row position field and row captions are visible in the navigator. Indicates whether tooltips are shown for the buttons. Gets the collection of user interface strings. Vertical alignment of navigator buttons. Vertical margin between the border and the buttons. Flags enumeration specifying which buttons are visible. Performs the action associated with a navigator button. Sets the DataSource and DataMember properties at run time.

MoveDelayNext PageSize PositionVisible ShowToolTips UIStrings VerticalAlign VerticalIndent VisibleButtons Public Methods ClickButton SetDataBinding

120 C1.Win.C1Input Namespace

Public Events Adding BeforeAction ButtonClick ButtonCursorChanged Deleting Editing Error ItemChanged PositionChanged RefreshData UpdateData See Also C1DbNavigator Class | C1.Win.C1Input Namespace Occurs when Add button is pressed. Occurs when a button is clicked, before the action is executed. Occurs when a navigator button has been pressed, after the button action is performed. Event fired when the value of ButtonCursor property is changed. Occurs when Delete button is pressed. Occurs when Edit button is pressed. Occurs when an exceptions is thrown performing an action on button click. Occurs when the current row has been modified, some of its fields changed. Occurs when the Position has changed. Occurs when Refresh button is pressed. Occurs when Update button is pressed.

C1DbNavigator Properties
The properties of the C1DbNavigator class are listed here. For a complete list of C1DbNavigator class members, see the C1DbNavigator Members topic. Public Properties BorderStyle ButtonCursor ButtonSize ButtonStyle ButtonTextAlign ButtonTexts ButtonToolTips CausesFormValidation ColorButtons ColorWhenHover ConfirmDelete Navigator border style. The cursor that is displayed when the mouse is over the navigator buttons. The size of navigator buttons. Navigator button style. Controls how the text is positioned relative to the image in navigator buttons. Gets or sets the texts displayed on the buttons. The string collection defining navigator button tooltips. Whether the control in focus should be validated before a button click is handled by the navigator. Specifies if navigator buttons have color bitmaps. If True, navigator buttons show color bitmaps when the mouse hovers over them. Whether a confirmation dialog is shown before deleting a record.

C1DbNavigator.BorderStyle Property 121

CurrencyManager DataMember DataSource EnabledButtons ErrorProvider HorizontalIndent ImageList ImageListHighlight MoveDelayFirst

Gets or sets the CurrencyManager object navigated by the control. For multi-table data sources, specifies a specific table to which the control is bound. The data source object to which the control is bound. Flags enumeration specifying which buttons are enabled. Gets or sets an ErrorProvider object used to indicate error state of the current data row. Horizontal margin between the border and the buttons. Gets or sets the ImageList to use when displaying button images without highlighting. Gets or sets the ImageList to use when displaying button images in highlighted state. Time delay in milliseconds after pressing Next/Previous button before automatic scrolling begins. Time delay in milliseconds between row moves in automatic scrolling. Number of rows to skip when the user presses PAGE UP/DOWN. Specifies whether the editable row position field and row captions are visible in the navigator. Indicates whether tooltips are shown for the buttons. Gets the collection of user interface strings. Vertical alignment of navigator buttons. Vertical margin between the border and the buttons. Flags enumeration specifying which buttons are visible.

MoveDelayNext PageSize PositionVisible ShowToolTips UIStrings VerticalAlign VerticalIndent VisibleButtons See Also C1DbNavigator Class | C1.Win.C1Input Namespace

C1DbNavigator.BorderStyle Property
Navigator border style. [Visual Basic] Public Property BorderStyle As BorderStyle [C#] new public BorderStyle BorderStyle {get;set;} [Delphi] public property BorderStyle: BorderStyle read get_BorderStyle write set_BorderStyle;

122 C1.Win.C1Input Namespace

See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.ButtonCursor Property
The cursor that is displayed when the mouse is over the navigator buttons. [Visual Basic] Public Property ButtonCursor As Cursor [C#] public Cursor ButtonCursor {get;set;} [Delphi] public property ButtonCursor: Cursor read get_ButtonCursor write set_ButtonCursor; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.ButtonSize Property
The size of navigator buttons. [Visual Basic] Public Property ButtonSize As Size [C#] public Size ButtonSize {get;set;} [Delphi] public property ButtonSize: Size read get_ButtonSize write set_ButtonSize; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.ButtonStyle Property
Navigator button style. [Visual Basic] Public Property ButtonStyle As NavigatorButtonStyleEnum [C#] public NavigatorButtonStyleEnum ButtonStyle {get;set;} [Delphi] public property ButtonStyle: NavigatorButtonStyleEnum read get_ButtonStyle write set_ButtonStyle; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.ButtonTextAlign Property 123

C1DbNavigator.ButtonTextAlign Property
Controls how the text is positioned relative to the image in navigator buttons. [Visual Basic] Public Property ButtonTextAlign As NavigatorButtonTextAlignEnum [C#] public NavigatorButtonTextAlignEnum ButtonTextAlign {get;set;} [Delphi] public property ButtonTextAlign: NavigatorButtonTextAlignEnum read get_ButtonTextAlign write set_ButtonTextAlign; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.ButtonTexts Property
Gets or sets the texts displayed on the buttons. [Visual Basic] Public ReadOnly Property ButtonTexts As UIStrings [C#] public UIStrings ButtonTexts {get;} [Delphi] public property ButtonTexts: UIStrings read get_ButtonTexts; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.ButtonToolTips Property
The string collection defining navigator button tooltips. [Visual Basic] Public ReadOnly Property ButtonToolTips As UIStrings [C#] public UIStrings ButtonToolTips {get;} [Delphi] public property ButtonToolTips: UIStrings read get_ButtonToolTips; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.CausesFormValidation Property
Whether the control in focus should be validated before a button click is handled by the navigator.

124 C1.Win.C1Input Namespace

[Visual Basic] Public Property CausesFormValidation As Boolean [C#] public bool CausesFormValidation {get;set;} [Delphi] public property CausesFormValidation: Boolean read get_CausesFormValidation write set_CausesFormValidation; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.ColorButtons Property
Specifies if navigator buttons have color bitmaps. [Visual Basic] Public Property ColorButtons As Boolean [C#] public bool ColorButtons {get;set;} [Delphi] public property ColorButtons: Boolean read get_ColorButtons write set_ColorButtons; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.ColorWhenHover Property
If True, navigator buttons show color bitmaps when the mouse hovers over them. [Visual Basic] Public Property ColorWhenHover As Boolean [C#] public bool ColorWhenHover {get;set;} [Delphi] public property ColorWhenHover: Boolean read get_ColorWhenHover write set_ColorWhenHover; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.ConfirmDelete Property
Whether a confirmation dialog is shown before deleting a record. [Visual Basic] Public Property ConfirmDelete As Boolean

C1DbNavigator.CurrencyManager Property 125

[C#] public bool ConfirmDelete {get;set;} [Delphi] public property ConfirmDelete: Boolean read get_ConfirmDelete write set_ConfirmDelete; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.CurrencyManager Property
Gets or sets the CurrencyManager object navigated by the control. [Visual Basic] Public Property CurrencyManager As CurrencyManager [C#] public CurrencyManager CurrencyManager {get;set;} [Delphi] public property CurrencyManager: CurrencyManager read get_CurrencyManager write set_CurrencyManager; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.DataMember Property
For multi-table data sources, specifies a specific table to which the control is bound. [Visual Basic] Public Property DataMember As String [C#] public string DataMember {get;set;} [Delphi] public property DataMember: String read get_DataMember write set_DataMember; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.DataSource Property
The data source object to which the control is bound. [Visual Basic] Public Property DataSource As Object [C#] public object DataSource {get;set;}

126 C1.Win.C1Input Namespace

[Delphi] public property DataSource: Object read get_DataSource write set_DataSource; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.EnabledButtons Property
Flags enumeration specifying which buttons are enabled. [Visual Basic] Public Property EnabledButtons As NavigatorButtonFlags [C#] public NavigatorButtonFlags EnabledButtons {get;set;} [Delphi] public property EnabledButtons: NavigatorButtonFlags read get_EnabledButtons write set_EnabledButtons; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.ErrorProvider Property
Gets or sets an ErrorProvider object used to indicate error state of the current data row. [Visual Basic] Public Property ErrorProvider As ErrorProvider [C#] public ErrorProvider ErrorProvider {get;set;} [Delphi] public property ErrorProvider: ErrorProvider read get_ErrorProvider write set_ErrorProvider; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.HorizontalIndent Property
Horizontal margin between the border and the buttons. [Visual Basic] Public Property HorizontalIndent As Integer [C#] public int HorizontalIndent {get;set;} [Delphi] public property HorizontalIndent: Int32 read get_HorizontalIndent write set_HorizontalIndent;

C1DbNavigator.ImageList Property 127

See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.ImageList Property
Gets or sets the ImageList to use when displaying button images without highlighting. [Visual Basic] Public Property ImageList As ImageList [C#] public ImageList ImageList {get;set;} [Delphi] public property ImageList: ImageList read get_ImageList write set_ImageList; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.ImageListHighlight Property
Gets or sets the ImageList to use when displaying button images in highlighted state. [Visual Basic] Public Property ImageListHighlight As ImageList [C#] public ImageList ImageListHighlight {get;set;} [Delphi] public property ImageListHighlight: ImageList read get_ImageListHighlight write set_ImageListHighlight; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.MoveDelayFirst Property
Time delay in milliseconds after pressing Next/Previous button before automatic scrolling begins. [Visual Basic] Public Property MoveDelayFirst As Integer [C#] public int MoveDelayFirst {get;set;} [Delphi] public property MoveDelayFirst: Int32 read get_MoveDelayFirst write set_MoveDelayFirst; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

128 C1.Win.C1Input Namespace

C1DbNavigator.MoveDelayNext Property
Time delay in milliseconds between row moves in automatic scrolling. [Visual Basic] Public Property MoveDelayNext As Integer [C#] public int MoveDelayNext {get;set;} [Delphi] public property MoveDelayNext: Int32 read get_MoveDelayNext write set_MoveDelayNext; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.PageSize Property
Number of rows to skip when the user presses PAGE UP/DOWN. [Visual Basic] Public Property PageSize As Integer [C#] public int PageSize {get;set;} [Delphi] public property PageSize: Int32 read get_PageSize write set_PageSize; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.PositionVisible Property
Specifies whether the editable row position field and row captions are visible in the navigator. [Visual Basic] Public Property PositionVisible As Boolean [C#] public bool PositionVisible {get;set;} [Delphi] public property PositionVisible: Boolean read get_PositionVisible write set_PositionVisible; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.ShowToolTips Property
Indicates whether tooltips are shown for the buttons.

C1DbNavigator.UIStrings Property 129

[Visual Basic] Public Property ShowToolTips As Boolean [C#] public bool ShowToolTips {get;set;} [Delphi] public property ShowToolTips: Boolean read get_ShowToolTips write set_ShowToolTips; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.UIStrings Property
Gets the collection of user interface strings. [Visual Basic] Public ReadOnly Property UIStrings As UIStrings [C#] public UIStrings UIStrings {get;} [Delphi] public property UIStrings: UIStrings read get_UIStrings; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.VerticalAlign Property
Vertical alignment of navigator buttons. [Visual Basic] Public Property VerticalAlign As NavigatorVerticalAlignEnum [C#] public NavigatorVerticalAlignEnum VerticalAlign {get;set;} [Delphi] public property VerticalAlign: NavigatorVerticalAlignEnum read get_VerticalAlign write set_VerticalAlign; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.VerticalIndent Property
Vertical margin between the border and the buttons. [Visual Basic] Public Property VerticalIndent As Integer

130 C1.Win.C1Input Namespace

[C#] public int VerticalIndent {get;set;} [Delphi] public property VerticalIndent: Int32 read get_VerticalIndent write set_VerticalIndent; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.VisibleButtons Property
Flags enumeration specifying which buttons are visible. [Visual Basic] Public Property VisibleButtons As NavigatorButtonFlags [C#] public NavigatorButtonFlags VisibleButtons {get;set;} [Delphi] public property VisibleButtons: NavigatorButtonFlags read get_VisibleButtons write set_VisibleButtons; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator Methods
The methods of the C1DbNavigator class are listed here. For a complete list of C1DbNavigator class members, see the C1DbNavigator Members topic. Public Methods ClickButton SetDataBinding See Also C1DbNavigator Class | C1.Win.C1Input Namespace Performs the action associated with a navigator button. Sets the DataSource and DataMember properties at run time.

C1DbNavigator.ClickButton Method
Performs the action associated with a navigator button. [Visual Basic] Public Sub ClickButton( _ ByVal button As NavigatorButtonEnum _ ) [C#] public void ClickButton( NavigatorButtonEnum button );

C1DbNavigator.SetDataBinding Method 131

[Delphi] public procedure ClickButton( button: NavigatorButtonEnum ); Parameters button The button whose action is performed. See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.SetDataBinding Method
Sets the DataSource and DataMember properties at run time. [Visual Basic] Public Sub SetDataBinding( _ ByVal dataSource As Object, _ ByVal dataMember As String _ ) [C#] public void SetDataBinding( object dataSource, string dataMember ); [Delphi] public procedure SetDataBinding( dataSource: Object; dataMember: String ); Parameters dataSource The data source object to which the control is bound. dataMember For multi-table data sources, specifies a specific table to which the control is bound. See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator Events
The events of the C1DbNavigator class are listed here. For a complete list of C1DbNavigator class members, see the C1DbNavigator Members topic. Public Events Adding BeforeAction Occurs when Add button is pressed. Occurs when a button is clicked, before the action is executed.

132 C1.Win.C1Input Namespace

ButtonClick ButtonCursorChanged Deleting Editing Error ItemChanged PositionChanged RefreshData UpdateData See Also C1DbNavigator Class | C1.Win.C1Input Namespace

Occurs when a navigator button has been pressed, after the button action is performed. Event fired when the value of ButtonCursor property is changed. Occurs when Delete button is pressed. Occurs when Edit button is pressed. Occurs when an exceptions is thrown performing an action on button click. Occurs when the current row has been modified, some of its fields changed. Occurs when the Position has changed. Occurs when Refresh button is pressed. Occurs when Update button is pressed.

C1DbNavigator.Adding Event
Occurs when Add button is pressed. [Visual Basic] Public Event Adding AsNavigatorAddingEventHandlerNavigatorAddingEventHandler [C#] public eventNavigatorAddingEventHandlerNavigatorAddingEventHandler Adding [Delphi] public property Adding: NavigatorAddingEventHandler read remove_Adding write add_Adding; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.BeforeAction Event
Occurs when a button is clicked, before the action is executed. [Visual Basic] Public Event BeforeAction AsNavigatorBeforeActionEventHandlerNavigatorBeforeActionEventHandler [C#] public eventNavigatorBeforeActionEventHandlerNavigatorBeforeActionEventHandler BeforeAction

C1DbNavigator.ButtonClick Event 133

[Delphi] public property BeforeAction: NavigatorBeforeActionEventHandler read remove_BeforeAction write add_BeforeAction; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.ButtonClick Event
Occurs when a navigator button has been pressed, after the button action is performed. [Visual Basic] Public Event ButtonClick AsNavigatorButtonClickEventHandlerNavigatorButtonClickEventHandler [C#] public eventNavigatorButtonClickEventHandlerNavigatorButtonClickEventHandler ButtonClick [Delphi] public property ButtonClick: NavigatorButtonClickEventHandler read remove_ButtonClick write add_ButtonClick; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.ButtonCursorChanged Event
Event fired when the value of ButtonCursor property is changed. [Visual Basic] Public Event ButtonCursorChanged AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler ButtonCursorChanged [Delphi] public property ButtonCursorChanged: EventHandler read remove_ButtonCursorChanged write add_ButtonCursorChanged; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.Deleting Event
Occurs when Delete button is pressed. [Visual Basic] Public Event Deleting AsNavigatorDeletingEventHandlerNavigatorDeletingEventHandler [C#] public eventNavigatorDeletingEventHandlerNavigatorDeletingEventHandler Deleting

134 C1.Win.C1Input Namespace

[Delphi] public property Deleting: NavigatorDeletingEventHandler read remove_Deleting write add_Deleting; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.Editing Event
Occurs when Edit button is pressed. [Visual Basic] Public Event Editing AsNavigatorEditingEventHandlerNavigatorEditingEventHandler [C#] public eventNavigatorEditingEventHandlerNavigatorEditingEventHandler Editing [Delphi] public property Editing: NavigatorEditingEventHandler read remove_Editing write add_Editing; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.Error Event
Occurs when an exceptions is thrown performing an action on button click. [Visual Basic] Public Event Error AsNavigatorErrorEventHandlerNavigatorErrorEventHandler [C#] public eventNavigatorErrorEventHandlerNavigatorErrorEventHandler Error [Delphi] public property Error: NavigatorErrorEventHandler read remove_Error write add_Error; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.ItemChanged Event
Occurs when the current row has been modified, some of its fields changed. [Visual Basic] Public Event ItemChanged AsItemChangedEventHandlerItemChangedEventHandler [C#] public eventItemChangedEventHandlerItemChangedEventHandler ItemChanged

C1DbNavigator.PositionChanged Event 135

[Delphi] public property ItemChanged: ItemChangedEventHandler read remove_ItemChanged write add_ItemChanged; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.PositionChanged Event
Occurs when the Position has changed. [Visual Basic] Public Event PositionChanged AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler PositionChanged [Delphi] public property PositionChanged: EventHandler read remove_PositionChanged write add_PositionChanged; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.RefreshData Event
Occurs when Refresh button is pressed. [Visual Basic] Public Event RefreshData AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler RefreshData [Delphi] public property RefreshData: EventHandler read remove_RefreshData write add_RefreshData; Example The following code refreshes data when the Refresh button is pressed, and fills the dataset: Visual Basic Private Sub C1DbNavigator1_RefreshData(sender As Object, e As System.EventArgs) Me.OleDbDataAdapter1.Fill(DataSet11) End Sub C# private void c1DbNavigator1_RefreshData(object sender, System.EventArgs e) { this.oleDbDataAdapter1.Fill(dataSet11); } Delphi procedure C1DbNavigator1_RefreshData(sender: object; e: System.EventArgs); begin

136 C1.Win.C1Input Namespace

Self.OleDbDataAdapter1.Fill(DataSet11); end; See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DbNavigator.UpdateData Event
Occurs when Update button is pressed. [Visual Basic] Public Event UpdateData AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler UpdateData [Delphi] public property UpdateData: EventHandler read remove_UpdateData write add_UpdateData; Example The following code updates the dataset when the Update button is pressed: Visual Basic Private Sub C1DbNavigator1_UpdateData(sender As Object, e As System.EventArgs) Me.OleDbDataAdapter1.Update(DataSet11) End Sub C# private void c1DbNavigator1_UpdateData(object sender, System.EventArgs e) { this.oleDbDataAdapter1.Update(dataSet11); } Delphi procedure C1DbNavigator1_UpdateData(sender: object; e: System.EventArgs); begin Self.OleDbDataAdapter1.Update(DataSet11); end;

See Also C1DbNavigator Class | C1DbNavigator Members | C1.Win.C1Input Namespace

C1DropDownControl Class
Base class for C1DateEdit and C1NumericEdit controls. Includes support for drop-down and up/down buttons. For a list of all members of this type, see C1DropDownControl Members. System.Object System.MarshalByRefObject System.ComponentModel.Component System.Windows.Forms.Control

C1DropDownControl Members 137

System.Windows.Forms.TextBoxBase System.Windows.Forms.TextBox C1.Win.C1Input.C1TextBox C1.Win.C1Input.C1DropDownControl C1.Win.C1Input.C1DateEdit C1.Win.C1Input.C1NumericEdit [Visual Basic] Public Class C1DropDownControl Inherits C1TextBox [C#] public class C1DropDownControl : C1TextBox [Delphi] type C1DropDownControl = class (C1TextBox);(C1TextBox); Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also C1DropDownControl Members | C1.Win.C1Input Namespace

C1DropDownControl Members
C1DropDownControl overview Public Properties AutoCompleteCustomSource (inherited from TextBox) AutoCompleteMode (inherited from TextBox) AutoCompleteSource (inherited from TextBox) ButtonCursor ButtonWidth CanUndo (inherited from TextBoxBase) CharacterCasing (inherited from TextBox) DropDownForm DropDownFormAlign DropDownFormClassName The StringCollection to use when the AutoCompleteSource property is set to CustomSource. Indicates the text completion behavior of the text box. The autocomplete source, which can be one of the values from AutoCompleteSource enumeration. The cursor that is displayed when the mouse is over a button. Specifies the button width instead of using the default width. Indicates if the edit control can undo the previous action. Indicates if all characters should be left alone or converted to uppercase or lowercase. Returns drop-down form instance associated with the control. Alignment of the drop-down form relative to the control. Specifies the class name of a Form serving as the dropdown window.

138 C1.Win.C1Input Namespace

DroppedDown GapHeight HideSelection (inherited from TextBoxBase) InterceptArrowKeys MaxLength (inherited from TextBoxBase) MouseClickPassThrough PasswordChar (inherited from TextBox) ReadOnly (inherited from TextBoxBase) SelectedText (inherited from C1TextBox) SelectionLength (inherited from TextBoxBase) SelectionStart (inherited from TextBoxBase) ShortcutsEnabled (inherited from TextBoxBase) ShowDropDownButton ShowModalButton ShowUpDownButtons TextAlign (inherited from TextBox) UseSystemPasswordChar (inherited from TextBox) VisibleButtons Public Methods CloseDropDown OpenDropDown Public Events AcceptsTabChanged (inherited from TextBoxBase) BorderStyleChanged (inherited from TextBoxBase) ButtonCursorChanged DropDownClosed

Run-time read-only property indicating if the dropdown is currently open. Distance in pixels between the control edge and the drop-down. Indicates that the selection should be hidden when the edit control loses focus. Determines if the up/down buttons intercept and handle the UP and DOWN ARROW keys. Specifies the maximum number of characters that can be entered into the edit control. Gets or sets whether the mouse click event is consumed or passed through after closing the drop-down. Indicates the character to display for password input for single-line edit controls. Controls whether the text in the edit control can be changed or not. The currently selected text. The length of the currently selected text. The beginning of the currently selected text. Indicates whether shortcuts defined for the control are enabled. Determines if the drop-down button is visible. Determines if the Modal button is visible. Determines if the up/down buttons are visible. Indicates how the text should be aligned for edit controls. Indicates if the text in the edit control should appear as the default password character. Enumeration specifying which buttons are visible. Overloaded. Closes the drop-down. Shows the drop-down. Occurs when the value of the AcceptsTab property changes. Occurs when the value of the BorderStyle property changes. Event fired when the value of ButtonCursor property is changed. Occurs when the drop-down has been closed.

C1DropDownControl Properties 139

DropDownFormAlignChanged DropDownOpened HideSelectionChanged (inherited from TextBoxBase) ModalButtonClick ModifiedChanged (inherited from TextBoxBase) ReadOnlyChanged (inherited from TextBoxBase) TextAlignChanged (inherited from TextBox) UpDownButtonClick Protected Properties DefaultDropDownFormClassName See Also

Occurs when the value of the DropDownFormAlign property has changed. Occurs just before the drop-down is opened. Occurs when the value of the HideSelection property changes. Occurs when the Modal button is clicked. Occurs when the value of the Modified property changes. Occurs when the value of the ReadOnly property changes. Occurs when the value of the TextAlign property changes Occurs when UpDown buttons are clicked. Specifies form class that is used by default as the dropdown for the control.

C1DropDownControl Class | C1.Win.C1Input Namespace

C1DropDownControl Properties
The properties of the C1DropDownControl class are listed here. For a complete list of C1DropDownControl class members, see the C1DropDownControl Members topic. Public Properties AutoCompleteCustomSource (inherited from TextBox) AutoCompleteMode (inherited from TextBox) AutoCompleteSource (inherited from TextBox) ButtonCursor ButtonWidth CanUndo (inherited from TextBoxBase) CharacterCasing (inherited from TextBox) DropDownForm DropDownFormAlign DropDownFormClassName The StringCollection to use when the AutoCompleteSource property is set to CustomSource. Indicates the text completion behavior of the text box. The autocomplete source, which can be one of the values from AutoCompleteSource enumeration. The cursor that is displayed when the mouse is over a button. Specifies the button width instead of using the default width. Indicates if the edit control can undo the previous action. Indicates if all characters should be left alone or converted to uppercase or lowercase. Returns drop-down form instance associated with the control. Alignment of the drop-down form relative to the control. Specifies the class name of a Form serving as the dropdown window.

140 C1.Win.C1Input Namespace

DroppedDown GapHeight HideSelection (inherited from TextBoxBase) InterceptArrowKeys MaxLength (inherited from TextBoxBase) MouseClickPassThrough PasswordChar (inherited from TextBox) ReadOnly (inherited from TextBoxBase) SelectedText (inherited from C1TextBox) SelectionLength (inherited from TextBoxBase) SelectionStart (inherited from TextBoxBase) ShortcutsEnabled (inherited from TextBoxBase) ShowDropDownButton ShowModalButton ShowUpDownButtons TextAlign (inherited from TextBox) UseSystemPasswordChar (inherited from TextBox) VisibleButtons Protected Properties DefaultDropDownFormClassName See Also

Run-time read-only property indicating if the dropdown is currently open. Distance in pixels between the control edge and the drop-down. Indicates that the selection should be hidden when the edit control loses focus. Determines if the up/down buttons intercept and handle the UP and DOWN ARROW keys. Specifies the maximum number of characters that can be entered into the edit control. Gets or sets whether the mouse click event is consumed or passed through after closing the drop-down. Indicates the character to display for password input for single-line edit controls. Controls whether the text in the edit control can be changed or not. The currently selected text. The length of the currently selected text. The beginning of the currently selected text. Indicates whether shortcuts defined for the control are enabled. Determines if the drop-down button is visible. Determines if the Modal button is visible. Determines if the up/down buttons are visible. Indicates how the text should be aligned for edit controls. Indicates if the text in the edit control should appear as the default password character. Enumeration specifying which buttons are visible. Specifies form class that is used by default as the dropdown for the control.

C1DropDownControl Class | C1.Win.C1Input Namespace

C1DropDownControl.ButtonCursor Property
The cursor that is displayed when the mouse is over a button. [Visual Basic] Public Property ButtonCursor As Cursor [C#] public Cursor ButtonCursor {get;set;}

C1DropDownControl.ButtonWidth Property 141

[Delphi] public property ButtonCursor: Cursor read get_ButtonCursor write set_ButtonCursor; See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

C1DropDownControl.ButtonWidth Property
Specifies the button width instead of using the default width. [Visual Basic] Public Property ButtonWidth As Integer [C#] public int ButtonWidth {get;set;} [Delphi] public property ButtonWidth: Int32 read get_ButtonWidth write set_ButtonWidth; See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

C1DropDownControl.DefaultDropDownFormClassName Property
Specifies form class that is used by default as the drop-down for the control. [Visual Basic] Overridable Protected ReadOnly Property DefaultDropDownFormClassName As String [C#] virtual protected string DefaultDropDownFormClassName {get;} [Delphi] strict protected property DefaultDropDownFormClassName: String read get_DefaultDropDownFormClassName; See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

C1DropDownControl.DropDownForm Property
Returns drop-down form instance associated with the control. [Visual Basic] Overridable Public Property DropDownForm As DropDownForm [C#] virtual public DropDownForm DropDownForm {get;set;}

142 C1.Win.C1Input Namespace

[Delphi] public property DropDownForm: DropDownForm read get_DropDownForm write set_DropDownForm; See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

C1DropDownControl.DropDownFormAlign Property
Alignment of the drop-down form relative to the control. [Visual Basic] Public Property DropDownFormAlign As DropDownFormAlignmentEnum [C#] public DropDownFormAlignmentEnum DropDownFormAlign {get;set;} [Delphi] public property DropDownFormAlign: DropDownFormAlignmentEnum read get_DropDownFormAlign write set_DropDownFormAlign; See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

C1DropDownControl.DropDownFormClassName Property
Specifies the class name of a Form serving as the drop-down window. [Visual Basic] Public Property DropDownFormClassName As String [C#] public string DropDownFormClassName {get;set;} [Delphi] public property DropDownFormClassName: String read get_DropDownFormClassName write set_DropDownFormClassName; See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

C1DropDownControl.DroppedDown Property
Run-time read-only property indicating if the drop-down is currently open. [Visual Basic] Public ReadOnly Property DroppedDown As Boolean [C#] public bool DroppedDown {get;} [Delphi] public property DroppedDown: Boolean read get_DroppedDown;

C1DropDownControl.GapHeight Property 143

See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

C1DropDownControl.GapHeight Property
Distance in pixels between the control edge and the drop-down. [Visual Basic] Public Property GapHeight As Integer [C#] public int GapHeight {get;set;} [Delphi] public property GapHeight: Int32 read get_GapHeight write set_GapHeight; See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

C1DropDownControl.InterceptArrowKeys Property
Determines if the up/down buttons intercept and handle the UP and DOWN ARROW keys. [Visual Basic] Public Property InterceptArrowKeys As Boolean [C#] public bool InterceptArrowKeys {get;set;} [Delphi] public property InterceptArrowKeys: Boolean read get_InterceptArrowKeys write set_InterceptArrowKeys; See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

C1DropDownControl.MouseClickPassThrough Property
Gets or sets whether the mouse click event is consumed or passed through after closing the drop-down. [Visual Basic] Public Property MouseClickPassThrough As Boolean [C#] public bool MouseClickPassThrough {get;set;} [Delphi] public property MouseClickPassThrough: Boolean read get_MouseClickPassThrough write set_MouseClickPassThrough; See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

144 C1.Win.C1Input Namespace

C1DropDownControl.ShowDropDownButton Property
Determines if the drop-down button is visible. [Visual Basic] Overridable Public Property ShowDropDownButton As Boolean [C#] virtual public bool ShowDropDownButton {get;set;} [Delphi] public property ShowDropDownButton: Boolean read get_ShowDropDownButton write set_ShowDropDownButton; See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

C1DropDownControl.ShowModalButton Property
Determines if the Modal button is visible. [Visual Basic] Overridable Public Property ShowModalButton As Boolean [C#] virtual public bool ShowModalButton {get;set;} [Delphi] public property ShowModalButton: Boolean read get_ShowModalButton write set_ShowModalButton; See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

C1DropDownControl.ShowUpDownButtons Property
Determines if the up/down buttons are visible. [Visual Basic] Overridable Public Property ShowUpDownButtons As Boolean [C#] virtual public bool ShowUpDownButtons {get;set;} [Delphi] public property ShowUpDownButtons: Boolean read get_ShowUpDownButtons write set_ShowUpDownButtons; See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

C1DropDownControl.VisibleButtons Property
Enumeration specifying which buttons are visible.

C1DropDownControl Methods 145

[Visual Basic] Overridable Public Property VisibleButtons As DropDownControlButtonFlags [C#] virtual public DropDownControlButtonFlags VisibleButtons {get;set;} [Delphi] public property VisibleButtons: DropDownControlButtonFlags read get_VisibleButtons write set_VisibleButtons; Remarks The default is UpDown Or DropDown. See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

C1DropDownControl Methods
The methods of the C1DropDownControl class are listed here. For a complete list of C1DropDownControl class members, see the C1DropDownControl Members topic. Public Methods CloseDropDown OpenDropDown See Also C1DropDownControl Class | C1.Win.C1Input Namespace Overloaded. Closes the drop-down. Shows the drop-down.

C1DropDownControl.CloseDropDown Method
Closes the drop-down. [Visual Basic] Public Sub CloseDropDown() [C#] public void CloseDropDown() [Delphi] public procedure CloseDropDown(); overload; See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

C1DropDownControl.OpenDropDown Method
Shows the drop-down. [Visual Basic] Overridable Public Sub OpenDropDown() [C#] virtual public void OpenDropDown()

146 C1.Win.C1Input Namespace

[Delphi] public procedure OpenDropDown(); virtual; See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

C1DropDownControl Events
The events of the C1DropDownControl class are listed here. For a complete list of C1DropDownControl class members, see the C1DropDownControl Members topic. Public Events AcceptsTabChanged (inherited from TextBoxBase) BorderStyleChanged (inherited from TextBoxBase) ButtonCursorChanged DropDownClosed DropDownFormAlignChanged DropDownOpened HideSelectionChanged (inherited from TextBoxBase) ModalButtonClick ModifiedChanged (inherited from TextBoxBase) ReadOnlyChanged (inherited from TextBoxBase) TextAlignChanged (inherited from TextBox) UpDownButtonClick See Also C1DropDownControl Class | C1.Win.C1Input Namespace Occurs when the value of the AcceptsTab property changes. Occurs when the value of the BorderStyle property changes. Event fired when the value of ButtonCursor property is changed. Occurs when the drop-down has been closed. Occurs when the value of the DropDownFormAlign property has changed. Occurs just before the drop-down is opened. Occurs when the value of the HideSelection property changes. Occurs when the Modal button is clicked. Occurs when the value of the Modified property changes. Occurs when the value of the ReadOnly property changes. Occurs when the value of the TextAlign property changes Occurs when UpDown buttons are clicked.

C1DropDownControl.ButtonCursorChanged Event
Event fired when the value of ButtonCursor property is changed. [Visual Basic] Public Event ButtonCursorChanged AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler ButtonCursorChanged [Delphi] public property ButtonCursorChanged: EventHandler read remove_ButtonCursorChanged write add_ButtonCursorChanged;

C1DropDownControl.DropDownClosed Event 147

See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

C1DropDownControl.DropDownClosed Event
Occurs when the drop-down has been closed. [Visual Basic] Public Event DropDownClosed AsDropDownClosedEventHandlerDropDownClosedEventHandler [C#] public eventDropDownClosedEventHandlerDropDownClosedEventHandler DropDownClosed [Delphi] public property DropDownClosed: DropDownClosedEventHandler read remove_DropDownClosed write add_DropDownClosed; See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

C1DropDownControl.DropDownFormAlignChanged Event
Occurs when the value of the DropDownFormAlign property has changed. [Visual Basic] Public Event DropDownFormAlignChanged AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler DropDownFormAlignChanged [Delphi] public property DropDownFormAlignChanged: EventHandler read remove_DropDownFormAlignChanged write add_DropDownFormAlignChanged; See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

C1DropDownControl.DropDownOpened Event
Occurs just before the drop-down is opened. [Visual Basic] Public Event DropDownOpened AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler DropDownOpened [Delphi] public property DropDownOpened: EventHandler read remove_DropDownOpened write add_DropDownOpened;

148 C1.Win.C1Input Namespace

See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

C1DropDownControl.ModalButtonClick Event
Occurs when the Modal button is clicked. [Visual Basic] Public Event ModalButtonClick AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler ModalButtonClick [Delphi] public property ModalButtonClick: EventHandler read remove_ModalButtonClick write add_ModalButtonClick; See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

C1DropDownControl.UpDownButtonClick Event
Occurs when UpDown buttons are clicked. [Visual Basic] Public Event UpDownButtonClick AsUpDownButtonClickEventHandlerUpDownButtonClickEventHandler [C#] public eventUpDownButtonClickEventHandlerUpDownButtonClickEventHandler UpDownButtonClick [Delphi] public property UpDownButtonClick: UpDownButtonClickEventHandler read remove_UpDownButtonClick write add_UpDownButtonClick; See Also C1DropDownControl Class | C1DropDownControl Members | C1.Win.C1Input Namespace

C1Label Class
Read-only data bound control displaying formatted data. C1Label supports all formatting features of the C1TextBox control. For a list of all members of this type, see C1Label Members. System.Object System.MarshalByRefObject System.ComponentModel.Component System.Windows.Forms.Control System.Windows.Forms.Label C1.Win.C1Input.C1Label

C1Label Members 149

[Visual Basic] Public Class C1Label InheritsLabelLabel ImplementsICustomTypeDescriptorICustomTypeDescriptor,ISupportInitialize ISupportInitialize [C#] public class C1Label :LabelLabel ,ICustomTypeDescriptorICustomTypeDescriptor,ISupportInitializeISupportInit ialize [Delphi] type C1Label = class (LabelLabel,(LabelLabel,ICustomTypeDescriptorICustomTypeDescriptor,ISuppor tInitializeISupportInitialize); Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also C1Label Members | C1.Win.C1Input Namespace

C1Label Members
C1Label overview Public Properties AutoEllipsis (inherited from Label) AutoSize (inherited from Label) BorderStyle (inherited from Label) CaseSensitive Culture CultureInfo CultureName CurrentTimeZone Enables the automatic handling of text that extends beyond the width of the label control. Enables automatic resizing based on font size. Note that this is only valid for label controls that do not wrap text. Determines if the label has a visible border. True if string comparisons are case-sensitive; otherwise, False. The culture ID. The current CultureInfo object (available at run time). The name selected for the Culture property in the Properties grid. If True, the control's stored Value is in current time zone; otherwise, the Value is adjusted to the time zone defined by the GMTOffset property. Custom format specifier used if FormatType = FormatTypeEnum.CustomFormat. The field of the data source object to which the control is bound. The data source object to which the control is bound. Type of the Value property.

CustomFormat DataField DataSource DataType

150 C1.Win.C1Input Namespace

DaylightTimeAdjustment

The value specified in the GMTOffset property can be advanced or set back due to daylight-saving time changes (used only if CurrentTimeZone = False). If True, empty strings are interpreted as null values (DbNull). Gets or sets an ErrorProvider object used to indicate error state of the control. Format used to display the value. Enumeration value determining the formatting method, including standard .NET format specifiers, custom and programmatic formatting. The time zone of the Value property used if CurrentTimeZone = False. The image that will be displayed on the control. The alignment of the image that will be displayed on the control. The index of the image in the ImageList to display on the control. The index of the image in the ImageList to display on the control. The ImageList to get the image to display on the control. Edit mask settings. String representing a DbNull value. The preferred height of this control. The preferred width of this control. Gets or sets the object that contains data about the control. Determines the position of the text within the label. Specifies whether the Value and Text properties can be set independently. If True, trailing spaces are removed. If True, leading spaces are removed. Specifies whether text rendering should be compatible with previous releases of Windows Forms. Indicates whether to honor the ColumnStyle properties defined on the C1ViewColumn object that this control is bound to. If True, the first character preceded by an ampersand (&&) will be used as the label's mnemonic key. If True, current user regional settings override the selected culture.

EmptyAsNull ErrorProvider FormatInfo FormatType

GMTOffset Image (inherited from Label) ImageAlign (inherited from Label) ImageIndex (inherited from Label) ImageKey (inherited from Label) ImageList (inherited from Label) MaskInfo NullText PreferredHeight (inherited from Label) PreferredWidth (inherited from Label) Tag TextAlign (inherited from Label) TextDetached TrimEnd TrimStart UseCompatibleTextRendering (inherited from Label) UseFieldStyle

UseMnemonic (inherited from Label) UserCultureOverride

C1Label Properties 151

Value ValueIsDbNull Public Events AutoSizeChanged (inherited from Label) BindingFormatting CultureInfoSetup DataTypeChanged FormatError Formatted Formatting TextAlignChanged (inherited from Label) ValueChanged See Also C1Label Class | C1.Win.C1Input Namespace

The main bindable property of a C1Input control. Gets or sets a value indicating whether the Value is DbNull. Occurs when the AutoSize property has changed. Occurs when Value is retrieved from the data source. CultureInfo can be set up (on startup) or has been changed. Occurs when the DataType property changes. Error occured while formatting the stored value. Occurs after the value has been formatted. Formatting the value programmatically. Event raised when the value of the TextAlign property is changed on Label. Occurs when the Value changes.

C1Label Properties
The properties of the C1Label class are listed here. For a complete list of C1Label class members, see the C1Label Members topic. Public Properties AutoEllipsis (inherited from Label) AutoSize (inherited from Label) BorderStyle (inherited from Label) CaseSensitive Culture CultureInfo CultureName CurrentTimeZone Enables the automatic handling of text that extends beyond the width of the label control. Enables automatic resizing based on font size. Note that this is only valid for label controls that do not wrap text. Determines if the label has a visible border. True if string comparisons are case-sensitive; otherwise, False. The culture ID. The current CultureInfo object (available at run time). The name selected for the Culture property in the Properties grid. If True, the control's stored Value is in current time zone; otherwise, the Value is adjusted to the time zone defined by the GMTOffset property. Custom format specifier used if FormatType = FormatTypeEnum.CustomFormat. The field of the data source object to which the control is bound. The data source object to which the control is bound.

CustomFormat DataField DataSource

152 C1.Win.C1Input Namespace

DataType DaylightTimeAdjustment

Type of the Value property. The value specified in the GMTOffset property can be advanced or set back due to daylight-saving time changes (used only if CurrentTimeZone = False). If True, empty strings are interpreted as null values (DbNull). Gets or sets an ErrorProvider object used to indicate error state of the control. Format used to display the value. Enumeration value determining the formatting method, including standard .NET format specifiers, custom and programmatic formatting. The time zone of the Value property used if CurrentTimeZone = False. The image that will be displayed on the control. The alignment of the image that will be displayed on the control. The index of the image in the ImageList to display on the control. The index of the image in the ImageList to display on the control. The ImageList to get the image to display on the control. Edit mask settings. String representing a DbNull value. The preferred height of this control. The preferred width of this control. Gets or sets the object that contains data about the control. Determines the position of the text within the label. Specifies whether the Value and Text properties can be set independently. If True, trailing spaces are removed. If True, leading spaces are removed. Specifies whether text rendering should be compatible with previous releases of Windows Forms. Indicates whether to honor the ColumnStyle properties defined on the C1ViewColumn object that this control is bound to. If True, the first character preceded by an ampersand (&&) will be used as the label's mnemonic key.

EmptyAsNull ErrorProvider FormatInfo FormatType

GMTOffset Image (inherited from Label) ImageAlign (inherited from Label) ImageIndex (inherited from Label) ImageKey (inherited from Label) ImageList (inherited from Label) MaskInfo NullText PreferredHeight (inherited from Label) PreferredWidth (inherited from Label) Tag TextAlign (inherited from Label) TextDetached TrimEnd TrimStart UseCompatibleTextRendering (inherited from Label) UseFieldStyle

UseMnemonic (inherited from Label)

C1Label.CaseSensitive Property 153

UserCultureOverride Value ValueIsDbNull See Also C1Label Class | C1.Win.C1Input Namespace

If True, current user regional settings override the selected culture. The main bindable property of a C1Input control. Gets or sets a value indicating whether the Value is DbNull.

C1Label.CaseSensitive Property
True if string comparisons are case-sensitive; otherwise, False. [Visual Basic] Public Property CaseSensitive As Boolean [C#] public bool CaseSensitive {get;set;} [Delphi] public property CaseSensitive: Boolean read get_CaseSensitive write set_CaseSensitive; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.Culture Property
The culture ID. [Visual Basic] Public Property Culture As Integer [C#] public int Culture {get;set;} [Delphi] public property Culture: Int32 read get_Culture write set_Culture; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.CultureInfo Property
The current CultureInfo object (available at run time). [Visual Basic] Public ReadOnly Property CultureInfo As CultureInfo [C#] public CultureInfo CultureInfo {get;}

154 C1.Win.C1Input Namespace

[Delphi] public property CultureInfo: CultureInfo read get_CultureInfo; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.CultureName Property
The name selected for the Culture property in the Properties grid. [Visual Basic] Public ReadOnly Property CultureName As String [C#] public string CultureName {get;} [Delphi] public property CultureName: String read get_CultureName; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.CurrentTimeZone Property
If True, the control's stored Value is in current time zone; otherwise, the Value is adjusted to the time zone defined by the GMTOffset property. [Visual Basic] Public Property CurrentTimeZone As Boolean [C#] public bool CurrentTimeZone {get;set;} [Delphi] public property CurrentTimeZone: Boolean read get_CurrentTimeZone write set_CurrentTimeZone; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.CustomFormat Property
Custom format specifier used if FormatType = FormatTypeEnum.CustomFormat. [Visual Basic] Public Property CustomFormat As String [C#] public string CustomFormat {get;set;} [Delphi] public property CustomFormat: String read get_CustomFormat write set_CustomFormat;

C1Label.DataField Property 155

See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.DataField Property
The field of the data source object to which the control is bound. [Visual Basic] Public Property DataField As String [C#] public string DataField {get;set;} [Delphi] public property DataField: String read get_DataField write set_DataField; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.DataSource Property
The data source object to which the control is bound. [Visual Basic] Public Property DataSource As Object [C#] public object DataSource {get;set;} [Delphi] public property DataSource: Object read get_DataSource write set_DataSource; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.DataType Property
Type of the Value property. [Visual Basic] Public Property DataType As Type [C#] public Type DataType {get;set;} [Delphi] public property DataType: Type read get_DataType write set_DataType; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

156 C1.Win.C1Input Namespace

C1Label.DaylightTimeAdjustment Property
The value specified in the GMTOffset property can be advanced or set back due to daylight-saving time changes (used only if CurrentTimeZone = False). [Visual Basic] Public Property DaylightTimeAdjustment As DaylightTimeAdjustmentEnum [C#] public DaylightTimeAdjustmentEnum DaylightTimeAdjustment {get;set;} [Delphi] public property DaylightTimeAdjustment: DaylightTimeAdjustmentEnum read get_DaylightTimeAdjustment write set_DaylightTimeAdjustment; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.EmptyAsNull Property
If True, empty strings are interpreted as null values (DbNull). [Visual Basic] Public Property EmptyAsNull As Boolean [C#] public bool EmptyAsNull {get;set;} [Delphi] public property EmptyAsNull: Boolean read get_EmptyAsNull write set_EmptyAsNull; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.ErrorProvider Property
Gets or sets an ErrorProvider object used to indicate error state of the control. [Visual Basic] Public Property ErrorProvider As ErrorProvider [C#] public ErrorProvider ErrorProvider {get;set;} [Delphi] public property ErrorProvider: ErrorProvider read get_ErrorProvider write set_ErrorProvider; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.FormatInfo Property
Format used to display the value.

C1Label.FormatType Property 157

[Visual Basic] Public ReadOnly Property FormatInfo As FormatInfo [C#] public FormatInfo FormatInfo {get;} [Delphi] public property FormatInfo: FormatInfo read get_FormatInfo; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.FormatType Property
Enumeration value determining the formatting method, including standard .NET format specifiers, custom and programmatic formatting. [Visual Basic] Public Property FormatType As FormatTypeEnum [C#] public FormatTypeEnum FormatType {get;set;} [Delphi] public property FormatType: FormatTypeEnum read get_FormatType write set_FormatType; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.GMTOffset Property
The time zone of the Value property used if CurrentTimeZone = False. [Visual Basic] Public Property GMTOffset As TimeSpan [C#] public TimeSpan GMTOffset {get;set;} [Delphi] public property GMTOffset: TimeSpan read get_GMTOffset write set_GMTOffset; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.MaskInfo Property
Edit mask settings. [Visual Basic] Public ReadOnly Property MaskInfo As MaskInfo

158 C1.Win.C1Input Namespace

[C#] public MaskInfo MaskInfo {get;} [Delphi] public property MaskInfo: MaskInfo read get_MaskInfo; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.NullText Property
String representing a DbNull value. [Visual Basic] Public Property NullText As String [C#] public string NullText {get;set;} [Delphi] public property NullText: String read get_NullText write set_NullText; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.Tag Property
Gets or sets the object that contains data about the control. [Visual Basic] Public Property Tag As Object [C#] new public object Tag {get;set;} [Delphi] public property Tag: Object read get_Tag write set_Tag; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.TextDetached Property
Specifies whether the Value and Text properties can be set independently. [Visual Basic] Public Property TextDetached As Boolean [C#] public bool TextDetached {get;set;}

C1Label.TrimEnd Property 159

[Delphi] public property TextDetached: Boolean read get_TextDetached write set_TextDetached; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.TrimEnd Property
If True, trailing spaces are removed. [Visual Basic] Public Property TrimEnd As Boolean [C#] public bool TrimEnd {get;set;} [Delphi] public property TrimEnd: Boolean read get_TrimEnd write set_TrimEnd; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.TrimStart Property
If True, leading spaces are removed. [Visual Basic] Public Property TrimStart As Boolean [C#] public bool TrimStart {get;set;} [Delphi] public property TrimStart: Boolean read get_TrimStart write set_TrimStart; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.UseFieldStyle Property
Indicates whether to honor the ColumnStyle properties defined on the C1ViewColumn object that this control is bound to. [Visual Basic] Public Property UseFieldStyle As Boolean [C#] public bool UseFieldStyle {get;set;} [Delphi] public property UseFieldStyle: Boolean read get_UseFieldStyle write set_UseFieldStyle;

160 C1.Win.C1Input Namespace

See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.UserCultureOverride Property
If True, current user regional settings override the selected culture. [Visual Basic] Public Property UserCultureOverride As Boolean [C#] public bool UserCultureOverride {get;set;} [Delphi] public property UserCultureOverride: Boolean read get_UserCultureOverride write set_UserCultureOverride; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.Value Property
The main bindable property of a C1Input control. [Visual Basic] Public Property Value As Object [C#] public object Value {get;set;} [Delphi] public property Value: Object read get_Value write set_Value; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.ValueIsDbNull Property
Gets or sets a value indicating whether the Value is DbNull. [Visual Basic] Public Property ValueIsDbNull As Boolean [C#] public bool ValueIsDbNull {get;set;} [Delphi] public property ValueIsDbNull: Boolean read get_ValueIsDbNull write set_ValueIsDbNull; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label Events 161

C1Label Events
The events of the C1Label class are listed here. For a complete list of C1Label class members, see the C1Label Members topic. Public Events AutoSizeChanged (inherited from Label) BindingFormatting CultureInfoSetup DataTypeChanged FormatError Formatted Formatting TextAlignChanged (inherited from Label) ValueChanged See Also C1Label Class | C1.Win.C1Input Namespace Occurs when the AutoSize property has changed. Occurs when Value is retrieved from the data source. CultureInfo can be set up (on startup) or has been changed. Occurs when the DataType property changes. Error occured while formatting the stored value. Occurs after the value has been formatted. Formatting the value programmatically. Event raised when the value of the TextAlign property is changed on Label. Occurs when the Value changes.

C1Label.BindingFormatting Event
Occurs when Value is retrieved from the data source. [Visual Basic] Public Event BindingFormatting AsConvertEventHandlerConvertEventHandler [C#] public eventConvertEventHandlerConvertEventHandler BindingFormatting [Delphi] public property BindingFormatting: ConvertEventHandler read remove_BindingFormatting write add_BindingFormatting; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.CultureInfoSetup Event
CultureInfo can be set up (on startup) or has been changed. [Visual Basic] Public Event CultureInfoSetup AsCultureInfoSetupEventHandlerCultureInfoSetupEventHandler [C#] public eventCultureInfoSetupEventHandlerCultureInfoSetupEventHandler CultureInfoSetup

162 C1.Win.C1Input Namespace

[Delphi] public property CultureInfoSetup: CultureInfoSetupEventHandler read remove_CultureInfoSetup write add_CultureInfoSetup; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.DataTypeChanged Event
Occurs when the DataType property changes. [Visual Basic] Public Event DataTypeChanged AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler DataTypeChanged [Delphi] public property DataTypeChanged: EventHandler read remove_DataTypeChanged write add_DataTypeChanged; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.FormatError Event
Error occured while formatting the stored value. [Visual Basic] Public Event FormatError AsFormatErrorEventHandlerFormatErrorEventHandler [C#] public eventFormatErrorEventHandlerFormatErrorEventHandler FormatError [Delphi] public property FormatError: FormatErrorEventHandler read remove_FormatError write add_FormatError; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.Formatted Event
Occurs after the value has been formatted. [Visual Basic] Public Event Formatted AsFormatEventHandlerFormatEventHandler [C#] public eventFormatEventHandlerFormatEventHandler Formatted [Delphi] public property Formatted: FormatEventHandler read remove_Formatted write add_Formatted;

C1Label.Formatting Event 163

See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.Formatting Event
Formatting the value programmatically. [Visual Basic] Public Event Formatting AsFormatEventHandlerFormatEventHandler [C#] public eventFormatEventHandlerFormatEventHandler Formatting [Delphi] public property Formatting: FormatEventHandler read remove_Formatting write add_Formatting; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1Label.ValueChanged Event
Occurs when the Value changes. [Visual Basic] Public Event ValueChanged AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler ValueChanged [Delphi] public property ValueChanged: EventHandler read remove_ValueChanged write add_ValueChanged; See Also C1Label Class | C1Label Members | C1.Win.C1Input Namespace

C1NumericEdit Class
Displays and edits numeric values. Includes a drop-down calculator for easy input of numeric values. For a list of all members of this type, see C1NumericEdit Members. System.Object System.MarshalByRefObject System.ComponentModel.Component System.Windows.Forms.Control System.Windows.Forms.TextBoxBase System.Windows.Forms.TextBox C1.Win.C1Input.C1TextBox

164 C1.Win.C1Input Namespace

C1.Win.C1Input.C1DropDownControl C1.Win.C1Input.C1NumericEdit [Visual Basic] Public Class C1NumericEdit Inherits C1DropDownControl [C#] public class C1NumericEdit : C1DropDownControl [Delphi] type C1NumericEdit = class (C1DropDownControl);(C1DropDownControl); Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also C1NumericEdit Members | C1.Win.C1Input Namespace

C1NumericEdit Members
C1NumericEdit overview Public Properties AcceptsEscape (inherited from C1TextBox) Indicates if the ESC key that cancels modified value is handled by the control without passing it to the owner form (AcceptsEscape=True), or it is then passed to the form and can close it if the form has CancelButton (AcceptsEscape=False). Indicates if TAB and SHIFT+TAB keys are accepted by control and move the focus to the next (previous) group of input characters in edit mask and in DateTimeInput mode. The StringCollection to use when the AutoCompleteSource property is set to CustomSource. Indicates the text completion behavior of the text box. The autocomplete source, which can be one of the values from AutoCompleteSource enumeration. Determines the style of the control's border. The drop-down calculator object. Indicates if the edit control can undo the previous action. True if string comparisons are case-sensitive; otherwise, False. Indicates if all characters should be left alone or converted to uppercase or lowercase. The culture ID. The current CultureInfo object (available at run time).

AcceptsTab (inherited from C1TextBox)

AutoCompleteCustomSource (inherited from TextBox) AutoCompleteMode (inherited from TextBox) AutoCompleteSource (inherited from TextBox) BorderStyle (inherited from C1TextBox) Calculator CanUndo (inherited from TextBoxBase) CaseSensitive (inherited from C1TextBox) CharacterCasing (inherited from TextBox) Culture (inherited from C1TextBox) CultureInfo (inherited from C1TextBox)

C1NumericEdit Members 165

CultureName (inherited from C1TextBox) CustomFormat (inherited from C1TextBox) DataField (inherited from C1TextBox) DataSource (inherited from C1TextBox) DataType DisableOnNoData (inherited from C1TextBox)

The name selected for the Culture property in the Properties grid. Custom format specifier used if FormatType = FormatTypeEnum.CustomFormat. The field of the data source object to which the control is bound. The data source object to which the control is bound. Overriden. Type of the Value property. Gets or sets whether the text box should be disabled when it is bound to an empty data source, such as CurrencyManager.Count = 0. Format used to display the value when the control is not in edit mode (does not have input focus or is readonly). Format used to display the value when the control is in edit mode (has input focus and is not read-only). The edit mask string restricting user input. Returns True, if the control has input focus and TextDetached = False. If True, empty strings are interpreted as null values (DBNull). Settings affecting error handling in the control. Enumeration value determining the formatting method, including standard .NET format specifiers, custom and programmatic formatting. Indicates that the selection should be hidden when the edit control loses focus. Indicates the amount to increment/decrement when the user clicks up/down buttons. Determines the selection position when a control receives input focus. Label control associated with this input field. The spacing between the input control content and its edges, in pixels. Edit mask settings. Specifies the maximum number of characters that can be entered into the edit control. Gets or sets a value that indicates that the control has been modified by the user since the control received the input focus or its Value last set. String representing a DBNull value. Sets or gets a value indicating whether a special edit mode is used for numeric values.

DisplayFormat (inherited from C1TextBox)

EditFormat (inherited from C1TextBox) EditMask (inherited from C1TextBox) EditMode (inherited from C1TextBox) EmptyAsNull (inherited from C1TextBox) ErrorInfo (inherited from C1TextBox) FormatType

HideSelection (inherited from TextBoxBase) Increment InitialSelection (inherited from C1TextBox) Label (inherited from C1TextBox) Margins (inherited from C1TextBox) MaskInfo (inherited from C1TextBox) MaxLength (inherited from TextBoxBase) Modified (inherited from C1TextBox)

NullText (inherited from C1TextBox) NumericInput (inherited from C1TextBox)

166 C1.Win.C1Input Namespace

NumericInputKeys (inherited from C1TextBox) ParseInfo (inherited from C1TextBox) PasswordChar (inherited from TextBox) PostValidation (inherited from C1TextBox)

Enables/disables the special keys used when NumericInput = True. Settings affecting parsing, that is, converting the string entered by the user to the data type. Indicates the character to display for password input for single-line edit controls. Validation rules applied after parsing, that is, after converting the string entered by the user to the DataType (typed validation). Validation rules applied before parsing, that is, before converting the string entered by the user to the DataType (raw string validation). Controls whether the text in the edit control can be changed or not. The currently selected text. The length of the currently selected text. The beginning of the currently selected text. Indicates whether shortcuts defined for the control are enabled. Specifies whether the context menu can be displayed for the control. Specifies whether a focus rectangle should be displayed around the client area when the control has the input focus. Gets or sets the object that contains data about the control Indicates how the text should be aligned for edit controls. If True, trailing spaces are removed. If True, leading spaces are removed. Indicates whether to honor the ColumnStyle properties defined on the C1ViewColumn object that this control is bound to. If True, current user regional settings override the selected culture. Indicates if the text in the edit control should appear as the default password character. The main bindable property of a C1Input control. Gets or sets a value indicating whether the Value is DBNull. Vertical alignment of the contents in the control.

PreValidation (inherited from C1TextBox)

ReadOnly (inherited from TextBoxBase) SelectedText (inherited from C1TextBox) SelectionLength (inherited from TextBoxBase) SelectionStart (inherited from TextBoxBase) ShortcutsEnabled (inherited from TextBoxBase) ShowContextMenu (inherited from C1TextBox) ShowFocusRectangle (inherited from C1TextBox)

Tag (inherited from C1TextBox) TextAlign (inherited from TextBox) TrimEnd (inherited from C1TextBox) TrimStart (inherited from C1TextBox) UseColumnStyles (inherited from C1TextBox)

UserCultureOverride (inherited from C1TextBox) UseSystemPasswordChar (inherited from TextBox) Value (inherited from C1TextBox) ValueIsDbNull (inherited from C1TextBox) VerticalAlign (inherited from C1TextBox)

C1NumericEdit Members 167

Public Methods DecDateTimeInput (inherited from C1TextBox) IncDateTimeInput (inherited from C1TextBox) ResetText (inherited from C1TextBox) UpdateValueWithCurrentText (inherited from C1TextBox) Public Events AcceptsTabChanged (inherited from TextBoxBase) BindingFormatting (inherited from C1TextBox) BindingParsing (inherited from C1TextBox) BorderStyleChanged (inherited from TextBoxBase) CultureInfoSetup (inherited from C1TextBox) DataTypeChanged (inherited from C1TextBox) FormatError (inherited from C1TextBox) Occurs when the value of the AcceptsTab property changes. Occurs when Value is retrieved from the data source. Occurs when Value is stored in the data source. Occurs when the value of the BorderStyle property changes. CultureInfo can be set up (on startup) or has been changed. Occurs when the DataType property changes. Occurs when the control receives data that cannot be formatted according to the current format and edit mask settings. Occurs after the value has been formatted. Formatting the value programmatically. Occurs when the value of the HideSelection property changes. Occurs when the Margins property or one of the margins has changed. Occurs when the value of the Modified property changes. Occurs after the input string value has been converted to the DataType. Programmatic parsing of the input string. Occurs after the typed value has been validated Programmatic typed value validation. Occurs after the input string value has been validated. Programmatic input string validation. Occurs when the value of the ReadOnly property changes. Occurs when the value of the TextAlign property changes Error occurred while parsing or validating the input string. Decrements the currently selected field in DateTimeInput mode. Increments the currently selected field in DateTimeInput mode. Updates the control's Text with the current Value. Triggers parsing of the Text property and updating the Value.

Formatted (inherited from C1TextBox) Formatting (inherited from C1TextBox) HideSelectionChanged (inherited from TextBoxBase) MarginsChanged (inherited from C1TextBox) ModifiedChanged (inherited from TextBoxBase) Parsed (inherited from C1TextBox) Parsing (inherited from C1TextBox) PostValidated (inherited from C1TextBox) PostValidating (inherited from C1TextBox) PreValidated (inherited from C1TextBox) PreValidating (inherited from C1TextBox) ReadOnlyChanged (inherited from TextBoxBase) TextAlignChanged (inherited from TextBox) ValidationError (inherited from C1TextBox)

168 C1.Win.C1Input Namespace

ValueChanged (inherited from C1TextBox) VerticalAlignChanged (inherited from C1TextBox) See Also C1NumericEdit Class | C1.Win.C1Input Namespace

Occurs when the Value changes. Occurs when the value of the VerticalAlign property has changed.

C1NumericEdit Properties
The properties of the C1NumericEdit class are listed here. For a complete list of C1NumericEdit class members, see the C1NumericEdit Members topic. Public Properties AcceptsEscape (inherited from C1TextBox) Indicates if the ESC key that cancels modified value is handled by the control without passing it to the owner form (AcceptsEscape=True), or it is then passed to the form and can close it if the form has CancelButton (AcceptsEscape=False). Indicates if TAB and SHIFT+TAB keys are accepted by control and move the focus to the next (previous) group of input characters in edit mask and in DateTimeInput mode. The StringCollection to use when the AutoCompleteSource property is set to CustomSource. Indicates the text completion behavior of the text box. The autocomplete source, which can be one of the values from AutoCompleteSource enumeration. Determines the style of the control's border. The drop-down calculator object. Indicates if the edit control can undo the previous action. True if string comparisons are case-sensitive; otherwise, False. Indicates if all characters should be left alone or converted to uppercase or lowercase. The culture ID. The current CultureInfo object (available at run time). The name selected for the Culture property in the Properties grid Custom format specifier used if FormatType = FormatTypeEnum.CustomFormat. The field of the data source object to which the control is bound. The data source object to which the control is bound. Overriden. Type of the Value property.

AcceptsTab (inherited from C1TextBox)

AutoCompleteCustomSource (inherited from TextBox) AutoCompleteMode (inherited from TextBox) AutoCompleteSource (inherited from TextBox) BorderStyle (inherited from C1TextBox) Calculator CanUndo (inherited from TextBoxBase) CaseSensitive (inherited from C1TextBox) CharacterCasing (inherited from TextBox) Culture (inherited from C1TextBox) CultureInfo (inherited from C1TextBox) CultureName (inherited from C1TextBox) CustomFormat (inherited from C1TextBox) DataField (inherited from C1TextBox) DataSource (inherited from C1TextBox) DataType

C1NumericEdit Properties 169

DisableOnNoData (inherited from C1TextBox)

Gets or sets whether the text box should be disabled when it is bound to an empty data source, such as CurrencyManager.Count = 0. Format used to display the value when the control is not in edit mode (does not have input focus or is readonly). Format used to display the value when the control is in edit mode (has input focus and is not read-only). The edit mask string restricting user input. Returns True, if the control has input focus and TextDetached = False. If True, empty strings are interpreted as null values (DBNull). Settings affecting error handling in the control. Enumeration value determining the formatting method, including standard .NET format specifiers, custom and programmatic formatting. Indicates that the selection should be hidden when the edit control loses focus. Indicates the amount to increment/decrement when the user clicks up/down buttons. Determines the selection position when a control receives input focus. Label control associated with this input field. The spacing between the input control content and its edges, in pixels. Edit mask settings. Specifies the maximum number of characters that can be entered into the edit control. Gets or sets a value that indicates that the control has been modified by the user since the control received the input focus or its Value last set. String representing a DBNull value. Sets or gets a value indicating whether a special edit mode is used for numeric values. Enables/disables the special keys used when NumericInput = True. Settings affecting parsing, that is, converting the string entered by the user to the data type. Indicates the character to display for password input for single-line edit controls. Validation rules applied after parsing, that is, after converting the string entered by the user to the DataType (typed validation).

DisplayFormat (inherited from C1TextBox)

EditFormat (inherited from C1TextBox) EditMask (inherited from C1TextBox) EditMode (inherited from C1TextBox) EmptyAsNull (inherited from C1TextBox) ErrorInfo (inherited from C1TextBox) FormatType

HideSelection (inherited from TextBoxBase) Increment InitialSelection (inherited from C1TextBox) Label (inherited from C1TextBox) Margins (inherited from C1TextBox) MaskInfo (inherited from C1TextBox) MaxLength (inherited from TextBoxBase) Modified (inherited from C1TextBox)

NullText (inherited from C1TextBox) NumericInput (inherited from C1TextBox) NumericInputKeys (inherited from C1TextBox) ParseInfo (inherited from C1TextBox) PasswordChar (inherited from TextBox) PostValidation (inherited from C1TextBox)

170 C1.Win.C1Input Namespace

PreValidation (inherited from C1TextBox)

Validation rules applied before parsing, that is, before converting the string entered by the user to the DataType (raw string validation). Controls whether the text in the edit control can be changed or not. The currently selected text. The length of the currently selected text. The beginning of the currently selected text. Indicates whether shortcuts defined for the control are enabled. Specifies whether the context menu can be displayed for the control. Specifies whether a focus rectangle should be displayed around the client area when the control has the input focus. Gets or sets the object that contains data about the control Indicates how the text should be aligned for edit controls. If True, trailing spaces are removed. If True, leading spaces are removed. Indicates whether to honor the ColumnStyle properties defined on the C1ViewColumn object that this control is bound to. If True, current user regional settings override the selected culture. Indicates if the text in the edit control should appear as the default password character. The main bindable property of a C1Input control. Gets or sets a value indicating whether the Value is DBNull. Vertical alignment of the contents in the control.

ReadOnly (inherited from TextBoxBase) SelectedText (inherited from C1TextBox) SelectionLength (inherited from TextBoxBase) SelectionStart (inherited from TextBoxBase) ShortcutsEnabled (inherited from TextBoxBase) ShowContextMenu (inherited from C1TextBox) ShowFocusRectangle (inherited from C1TextBox)

Tag (inherited from C1TextBox) TextAlign (inherited from TextBox) TrimEnd (inherited from C1TextBox) TrimStart (inherited from C1TextBox) UseColumnStyles (inherited from C1TextBox)

UserCultureOverride (inherited from C1TextBox) UseSystemPasswordChar (inherited from TextBox) Value (inherited from C1TextBox) ValueIsDbNull (inherited from C1TextBox) VerticalAlign (inherited from C1TextBox) See Also C1NumericEdit Class | C1.Win.C1Input Namespace

C1NumericEdit.Calculator Property
The drop-down calculator object. [Visual Basic] Public ReadOnly Property Calculator As NumericEditCalculator [C#] public NumericEditCalculator Calculator {get;}

C1NumericEdit.DataType Property 171

[Delphi] public property Calculator: NumericEditCalculator read get_Calculator; See Also C1NumericEdit Class | C1NumericEdit Members | C1.Win.C1Input Namespace

C1NumericEdit.DataType Property
Type of the Value property. [Visual Basic] Overrides Public Property DataType As Type [C#] override public Type DataType {get;set;} [Delphi] public property DataType: Type read get_DataType write set_DataType; See Also C1NumericEdit Class | C1NumericEdit Members | C1.Win.C1Input Namespace

C1NumericEdit.FormatType Property
Enumeration value determining the formatting method, including standard .NET format specifiers, custom and programmatic formatting. [Visual Basic] Public Property FormatType As FormatTypeEnum [C#] new public FormatTypeEnum FormatType {get;set;} [Delphi] public property FormatType: FormatTypeEnum read get_FormatType write set_FormatType; See Also C1NumericEdit Class | C1NumericEdit Members | C1.Win.C1Input Namespace

C1NumericEdit.Increment Property
Indicates the amount to increment/decrement when the user clicks up/down buttons. [Visual Basic] Public Property Increment As Object [C#] public object Increment {get;set;} [Delphi] public property Increment: Object read get_Increment write set_Increment;

172 C1.Win.C1Input Namespace

See Also C1NumericEdit Class | C1NumericEdit Members | C1.Win.C1Input Namespace

C1NumericEdit Methods
The methods of the C1NumericEdit class are listed here. For a complete list of C1NumericEdit class members, see the C1NumericEdit Members topic. Public Methods DecDateTimeInput (inherited from C1TextBox) IncDateTimeInput (inherited from C1TextBox) ResetText (inherited from C1TextBox) UpdateValueWithCurrentText (inherited from C1TextBox) See Also C1NumericEdit Class | C1.Win.C1Input Namespace Decrements the currently selected field in DateTimeInput mode. Increments the currently selected field in DateTimeInput mode. Updates the control's Text with the current Value. Triggers parsing of the Text property and updating the Value.

C1NumericEdit Events
The events of the C1NumericEdit class are listed here. For a complete list of C1NumericEdit class members, see the C1NumericEdit Members topic. Public Events AcceptsTabChanged (inherited from TextBoxBase) BindingFormatting (inherited from C1TextBox) BindingParsing (inherited from C1TextBox) BorderStyleChanged (inherited from TextBoxBase) CultureInfoSetup (inherited from C1TextBox) DataTypeChanged (inherited from C1TextBox) FormatError (inherited from C1TextBox) Occurs when the value of the AcceptsTab property changes. Occurs when Value is retrieved from the data source. Occurs when Value is stored in the data source. Occurs when the value of the BorderStyle property changes. CultureInfo can be set up (on startup) or has been changed. Occurs when the DataType property changes. Occurs when the control receives data that cannot be formatted according to the current format and edit mask settings. Occurs after the value has been formatted. Formatting the value programmatically. Occurs when the value of the HideSelection property changes. Occurs when the Margins property or one of the margins has changed. Occurs when the value of the Modified property changes.

Formatted (inherited from C1TextBox) Formatting (inherited from C1TextBox) HideSelectionChanged (inherited from TextBoxBase) MarginsChanged (inherited from C1TextBox) ModifiedChanged (inherited from TextBoxBase)

C1PictureBox Class 173

Parsed (inherited from C1TextBox) Parsing (inherited from C1TextBox) PostValidated (inherited from C1TextBox) PostValidating (inherited from C1TextBox) PreValidated (inherited from C1TextBox) PreValidating (inherited from C1TextBox) ReadOnlyChanged (inherited from TextBoxBase) TextAlignChanged (inherited from TextBox) ValidationError (inherited from C1TextBox) ValueChanged (inherited from C1TextBox) VerticalAlignChanged (inherited from C1TextBox) See Also C1NumericEdit Class | C1.Win.C1Input Namespace

Occurs after the input string value has been converted to the DataType. Programmatic parsing of the input string. Occurs after the typed value has been validated Programmatic typed value validation. Occurs after the input string value has been validated. Programmatic input string validation. Occurs when the value of the ReadOnly property changes. Occurs when the value of the TextAlign property changes Error occurred while parsing or validating the input string. Occurs when the Value changes. Occurs when the value of the VerticalAlign property has changed.

C1PictureBox Class
In addition to the standard PictureBox functionality, C1PictureBox supports data binding to data source fields containing image data. For a list of all members of this type, see C1PictureBox Members. System.Object System.MarshalByRefObject System.ComponentModel.Component System.Windows.Forms.Control System.Windows.Forms.PictureBox C1.Win.C1Input.C1PictureBox [Visual Basic] Public Class C1PictureBox InheritsPictureBoxPictureBox ImplementsICustomTypeDescriptorICustomTypeDescriptor [C#] public class C1PictureBox :PictureBoxPictureBox ,ICustomTypeDescriptorICustomTypeDescriptor [Delphi] type C1PictureBox = class (PictureBoxPictureBox,(PictureBoxPictureBox,ICustomTypeDescriptorICustomTy peDescriptor);

174 C1.Win.C1Input Namespace

Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also C1PictureBox Members | C1.Win.C1Input Namespace

C1PictureBox Members
C1PictureBox overview Public Properties BorderStyle (inherited from PictureBox) DataField DataSource ErrorImage (inherited from PictureBox) FocusOnClick Image ImageLocation (inherited from PictureBox) ImmediateUpdate Controls what type of border the PictureBox should have. The field of the data source object to which the control is bound. The data source object to which the control is bound. Image to display when the load of another image fails. Gets or sets the value indicating whether the picture box receives focus when clicked. The image displayed in the control. Disk or Web location to load image from. Gets or sets whether the image should be put into the data source right after the Image property has been changed or it shouldn't be put there until the following call of the CurrencyManager.EndCurrentEdit() method. Image to display while another image is loading. Controls how the PictureBox will handle image placement and control sizing. Controls whether processing will stop until the image is loaded. Attempts to cancel any current image-loading operation. Copies the image currently in the control to the clipboard. Converts a byte array to an image. Returns the contents of an image. Overloaded. Loads the image from the location specified in ImageLocation. Overloaded. Initiates asynchronous loading of the image from the location specified in ImageLocation. If the clipboard contains an image, this method replaces the contents of the Image property of the control

InitialImage (inherited from PictureBox) SizeMode (inherited from PictureBox) WaitOnLoad (inherited from PictureBox) Public Methods CancelAsync (inherited from PictureBox) CopyImage ImageFromByteArray ImageToByteArray Load (inherited from PictureBox) LoadAsync (inherited from PictureBox) PasteImage

C1PictureBox Properties 175

Public Events BindingFormatting BindingParsing ImageChanged LoadCompleted (inherited from PictureBox) LoadProgressChanged (inherited from PictureBox) SizeModeChanged (inherited from PictureBox) See Also C1PictureBox Class | C1.Win.C1Input Namespace Occurs when Image is retrieved from the data source. Occurs when Image is stored in the data source. Occurs when the Image changes. Event raised when loading into a PictureBox finishes. Event raised when progress is reported during loading into a PictureBox. Event raised when the value of the SizeMode property is changed on the PictureBox.

C1PictureBox Properties
The properties of the C1PictureBox class are listed here. For a complete list of C1PictureBox class members, see the C1PictureBox Members topic. Public Properties BorderStyle (inherited from PictureBox) DataField DataSource ErrorImage (inherited from PictureBox) FocusOnClick Image ImageLocation (inherited from PictureBox) ImmediateUpdate Controls what type of border the PictureBox should have. The field of the data source object to which the control is bound. The data source object to which the control is bound. Image to display when the load of another image fails. Gets or sets the value indicating whether the picture box receives focus when clicked. The image displayed in the control. Disk or Web location to load image from. Gets or sets whether the image should be put into the data source right after the Image property has been changed or it shouldn't be put there until the following call of the CurrencyManager.EndCurrentEdit() method. Image to display while another image is loading. Controls how the PictureBox will handle image placement and control sizing. Controls whether processing will stop until the image is loaded.

InitialImage (inherited from PictureBox) SizeMode (inherited from PictureBox) WaitOnLoad (inherited from PictureBox) See Also C1PictureBox Class | C1.Win.C1Input Namespace

C1PictureBox.DataField Property
The field of the data source object to which the control is bound.

176 C1.Win.C1Input Namespace

[Visual Basic] Public Property DataField As String [C#] public string DataField {get;set;} [Delphi] public property DataField: String read get_DataField write set_DataField; See Also C1PictureBox Class | C1PictureBox Members | C1.Win.C1Input Namespace

C1PictureBox.DataSource Property
The data source object to which the control is bound. [Visual Basic] Public Property DataSource As Object [C#] public object DataSource {get;set;} [Delphi] public property DataSource: Object read get_DataSource write set_DataSource; See Also C1PictureBox Class | C1PictureBox Members | C1.Win.C1Input Namespace

C1PictureBox.FocusOnClick Property
Gets or sets the value indicating whether the picture box receives focus when clicked. [Visual Basic] Public Property FocusOnClick As Boolean [C#] public bool FocusOnClick {get;set;} [Delphi] public property FocusOnClick: Boolean read get_FocusOnClick write set_FocusOnClick; See Also C1PictureBox Class | C1PictureBox Members | C1.Win.C1Input Namespace

C1PictureBox.Image Property
The image displayed in the control. [Visual Basic] Public Property Image As Image

C1PictureBox.ImmediateUpdate Property 177

[C#] new public Image Image {get;set;} [Delphi] public property Image: Image read get_Image write set_Image; See Also C1PictureBox Class | C1PictureBox Members | C1.Win.C1Input Namespace

C1PictureBox.ImmediateUpdate Property
Gets or sets whether the image should be put into the data source right after the Image property has been changed or it shouldn't be put there until the following call of the CurrencyManager.EndCurrentEdit() method. [Visual Basic] Public Property ImmediateUpdate As Boolean [C#] public bool ImmediateUpdate {get;set;} [Delphi] public property ImmediateUpdate: Boolean read get_ImmediateUpdate write set_ImmediateUpdate; See Also C1PictureBox Class | C1PictureBox Members | C1.Win.C1Input Namespace

C1PictureBox Methods
The methods of the C1PictureBox class are listed here. For a complete list of C1PictureBox class members, see the C1PictureBox Members topic. Public Methods CancelAsync (inherited from PictureBox) CopyImage ImageFromByteArray ImageToByteArray Load (inherited from PictureBox) LoadAsync (inherited from PictureBox) PasteImage See Also C1PictureBox Class | C1.Win.C1Input Namespace Attempts to cancel any current image-loading operation. Copies the image currently in the control to the clipboard. Converts a byte array to an image. Returns the contents of an image. Overloaded. Loads the image from the location specified in ImageLocation. Overloaded. Initiates asynchronous loading of the image from the location specified in ImageLocation. If the clipboard contains an image, this method replaces the contents of the Image property of the control

178 C1.Win.C1Input Namespace

C1PictureBox.CopyImage Method
Copies the image currently in the control to the clipboard. [Visual Basic] Public Sub CopyImage() [C#] public void CopyImage() [Delphi] public procedure CopyImage(); See Also C1PictureBox Class | C1PictureBox Members | C1.Win.C1Input Namespace

C1PictureBox.ImageFromByteArray Method
Converts a byte array to an image. [Visual Basic] Public Shared Function ImageFromByteArray( _ ByVal buffer As Byte() _ ) As Image [C#] public static Image ImageFromByteArray( byte[] buffer ); [Delphi] public class function ImageFromByteArray( buffer: Byte() ): Image; Parameters buffer The contents of an image. See Also C1PictureBox Class | C1PictureBox Members | C1.Win.C1Input Namespace

C1PictureBox.ImageToByteArray Method
Returns the contents of an image. [Visual Basic] Public Shared Function ImageToByteArray( _ ByVal image As Image, _ ByVal format As ImageFormat _ ) As Byte()

C1PictureBox.PasteImage Method 179

[C#] public static byte[] ImageToByteArray( Image image, ImageFormat format ); [Delphi] public class function ImageToByteArray( image: Image; format: ImageFormat ): array of Byte; Parameters image Image to return as a byte array. format Format in which to return the image contents. See Also C1PictureBox Class | C1PictureBox Members | C1.Win.C1Input Namespace

C1PictureBox.PasteImage Method
If the clipboard contains an image, this method replaces the contents of the Image property of the control [Visual Basic] Public Sub PasteImage() [C#] public void PasteImage() [Delphi] public procedure PasteImage(); See Also C1PictureBox Class | C1PictureBox Members | C1.Win.C1Input Namespace

C1PictureBox Events
The events of the C1PictureBox class are listed here. For a complete list of C1PictureBox class members, see the C1PictureBox Members topic. Public Events BindingFormatting BindingParsing ImageChanged LoadCompleted (inherited from PictureBox) LoadProgressChanged (inherited from PictureBox) Occurs when Image is retrieved from the data source. Occurs when Image is stored in the data source. Occurs when the Image changes. Event raised when loading into a PictureBox finishes. Event raised when progress is reported during loading into a PictureBox.

180 C1.Win.C1Input Namespace

SizeModeChanged (inherited from PictureBox) See Also C1PictureBox Class | C1.Win.C1Input Namespace

Event raised when the value of the SizeMode property is changed on the PictureBox.

C1PictureBox.BindingFormatting Event
Occurs when Image is retrieved from the data source. [Visual Basic] Public Event BindingFormatting AsConvertEventHandlerConvertEventHandler [C#] public eventConvertEventHandlerConvertEventHandler BindingFormatting [Delphi] public property BindingFormatting: ConvertEventHandler read remove_BindingFormatting write add_BindingFormatting; Example The following code provides an example of the BindingFormatting event: Visual Basic Private Sub C1PictureBox1_BindingFormatting(sender As Object, e As System.Windows.Forms.ConvertEventArgs) If e.DesiredType = GetType(Image) And TypeOf e.Value Is String And CStr(e.Value) <> String.Empty Then e.Value = Convert.FromBase64String(CStr(e.Value)) End If End Sub C# private void c1PictureBox1_BindingFormatting(object sender, System.Windows.Forms.ConvertEventArgs e) { if (e.DesiredType == typeof(Image) && e.Value is string && (string)e.Value != string.Empty) { e.Value = Convert.FromBase64String((string)e.Value); } } Delphi procedure C1PictureBox1_BindingFormatting(sender: Tobject; e: ConvertEventArgs); begin if (e.DesiredType = typeof(Image) and e.Value is string and e.Value as string <> string.Empty) then e.Value := Convert.FromBase64String((e.Value as string)) end;

See Also C1PictureBox Class | C1PictureBox Members | C1.Win.C1Input Namespace

C1PictureBox.BindingParsing Event 181

C1PictureBox.BindingParsing Event
Occurs when Image is stored in the data source. [Visual Basic] Public Event BindingParsing AsConvertEventHandlerConvertEventHandler [C#] public eventConvertEventHandlerConvertEventHandler BindingParsing [Delphi] public property BindingParsing: ConvertEventHandler read remove_BindingParsing write add_BindingParsing; Example The following code provides an example of the BindingParsing event: Visual Basic Private Sub C1PictureBox1_BindingParsing(sender As Object, e As System.Windows.Forms.ConvertEventArgs) If e.DesiredType = GetType(String) Then If TypeOf e.Value Is Image Then e.Value = Convert.ToBase64String(C1PictureBox.ImageToByteArray(CType(e.Value, Image), ImageFormat.Png)) Else If e.Value Is Nothing Or TypeOf e.Value Is DBNull Then e.Value = [String].Empty End If End If End If End Sub C# private void c1PictureBox1_BindingParsing(object sender, System.Windows.Forms.ConvertEventArgs e) { if (e.DesiredType == typeof(string)) { if (e.Value is Image) { e.Value = Convert.ToBase64String(C1PictureBox.ImageToByteArray((Image)e.Value, ImageFormat.Png)); } else if (e.Value == null || e.Value is DBNull) { e.Value = String.Empty; } } } Delphi -- N/A

See Also C1PictureBox Class | C1PictureBox Members | C1.Win.C1Input Namespace

182 C1.Win.C1Input Namespace

C1PictureBox.ImageChanged Event
Occurs when the Image changes. [Visual Basic] Public Event ImageChanged AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler ImageChanged [Delphi] public property ImageChanged: EventHandler read remove_ImageChanged write add_ImageChanged; See Also C1PictureBox Class | C1PictureBox Members | C1.Win.C1Input Namespace

C1TextBox Class
The main data bound control used for entering and editing information in a text form. Supports data formatting for all data types, including special features for date-time formats. Also supports edit mask, data validation and other features. For a list of all members of this type, see C1TextBox Members. System.Object System.MarshalByRefObject System.ComponentModel.Component System.Windows.Forms.Control System.Windows.Forms.TextBoxBase System.Windows.Forms.TextBox C1.Win.C1Input.C1TextBox C1.Win.C1Input.C1DropDownControl [Visual Basic] Public Class C1TextBox InheritsTextBoxTextBox Implements@as@as,a1a1,ICustomTypeDescriptorICustomTypeDescriptor,ISuppo rtInitializeISupportInitialize,qq [C#] public class C1TextBox :TextBoxTextBox ,@as@as,a1a1,ICustomTypeDescriptorICustomTypeDescriptor,ISupportInitialize ISupportInitialize,qq [Delphi] type C1TextBox = class (TextBoxTextBox,(TextBoxTextBox,@as@as,a1a1,ICustomTypeDescriptorICustomTy peDescriptor,ISupportInitializeISupportInitialize,qq); Namespace: C1.Win.C1Input

C1TextBox Members 183

Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox Members
C1TextBox overview Public Properties AcceptsEscape Indicates if the ESC key that cancels modified value is handled by the control without passing it to the owner form (AcceptsEscape=True), or it is then passed to the form and can close it if the form has CancelButton (AcceptsEscape=False). Indicates if return characters are accepted as input for multiline edit controls. Indicates if TAB and SHIFT+TAB keys are accepted by control and move the focus to the next (previous) group of input characters in edit mask and in DateTimeInput mode. Gets or sets a value indicating whether the position of the character is automatically changed The StringCollection to use when the AutoCompleteSource property is set to CustomSource. Indicates the text completion behavior of the text box. The autocomplete source, which can be one of the values from AutoCompleteSource enumeration. Determines the style of the control's border Indicates if the edit control can undo the previous action. True if string comparisons are case-sensitive; otherwise, False. Gets or sets a value indicating whether the control causes validation (such as, calls Validated and Validating events). Indicates if all characters should be left alone or converted to uppercase or lowercase. The culture ID. The current CultureInfo object (available at run time). The name selected for the Culture property in the Properties grid. If True, the control's stored Value is in current time zone; otherwise, the Value is adjusted to the time zone defined by the GMTOffset property Custom format specifier used if FormatType = FormatTypeEnum.CustomFormat.

AcceptsReturn (inherited from TextBox) AcceptsTab

AutoChangePosition AutoCompleteCustomSource (inherited from TextBox) AutoCompleteMode (inherited from TextBox) AutoCompleteSource (inherited from TextBox) BorderStyle CanUndo (inherited from TextBoxBase) CaseSensitive CausesValidation

CharacterCasing (inherited from TextBox) Culture CultureInfo CultureName CurrentTimeZone

CustomFormat

184 C1.Win.C1Input Namespace

DataField DataSource DataType DateTimeInput DaylightTimeAdjustment

The field of the data source object to which the control is bound. The data source object to which the control is bound. Type of the Value property. Whether or not a special edit mode is applied to DateTime values. The value specified in the GMTOffset property can be advanced or set back due to daylight-saving time changes. Gets or sets whether the text box should be disabled when it is bound to an empty data source, such as CurrencyManager.Count = 0. Format used to display the value when the control is not in edit mode (does not have input focus or is readonly). Format used to display the value when the control is in edit mode (has input focus and is not read-only). The edit mask string restricting user input. Returns True, if the control has input focus and TextDetached = False. If True, empty strings are interpreted as null values (DBNull). Settings affecting error handling in the control. Enumeration value determining the formatting method, including standard .NET format specifiers, custom and programmatic formatting. The time zone of the Value property used if CurrentTimeZone = False. Indicates that the selection should be hidden when the edit control loses focus. Determines the selection position when a control receives input focus. Label control associated with this input field. The lines of text in a multiline control. The spacing between the input control content and its edges, in pixels. Edit mask settings. Specifies the maximum number of characters that can be entered into the edit control. The minimum year that can be entered without leading zeros. Gets or sets a value that indicates that the control has been modified by the user since the control received the input focus or its Value last set.

DisableOnNoData

DisplayFormat

EditFormat EditMask EditMode EmptyAsNull ErrorInfo FormatType

GMTOffset HideSelection (inherited from TextBoxBase) InitialSelection Label Lines Margins MaskInfo MaxLength (inherited from TextBoxBase) MinShortYear Modified

C1TextBox Members 185

NullText NumericInput NumericInputKeys ParseInfo PasswordChar (inherited from TextBox) PostValidation

String representing a DBNull value. Sets or gets a value indicating whether a special edit mode is used for numeric values. Enables/disables the special keys used when NumericInput = True. Settings affecting parsing, that is, converting the string entered by the user to the data type. Indicates the character to display for password input for single-line edit controls. Validation rules applied after parsing, that is, after converting the string entered by the user to the DataType (typed validation). Validation rules applied before parsing, that is, before converting the string entered by the user to the DataType (raw string validation). Controls whether the text in the edit control can be changed or not. Indicates, for multiline edit controls, which scroll bars will be shown for this control. The currently selected text. Overriden. The length of the currently selected text. The beginning of the currently selected text. Indicates whether shortcuts defined for the control are enabled. Specifies whether the context menu can be displayed for the control. Specifies whether a focus rectangle should be displayed around the client area when the control has the input focus. Gets or sets the object that contains data about the control Overriden. The current text in the control. Indicates how the text should be aligned for edit controls. Specifies whether the Value and Text properties can be set independently. If True, trailing spaces are removed. If True, leading spaces are removed. Indicates whether to honor the ColumnStyle properties defined on the C1ViewColumn object that this control is bound to. If True, current user regional settings override the selected culture.

PreValidation

ReadOnly (inherited from TextBoxBase) ScrollBars (inherited from TextBox) SelectedText SelectionLength (inherited from TextBoxBase) SelectionStart (inherited from TextBoxBase) ShortcutsEnabled (inherited from TextBoxBase) ShowContextMenu ShowFocusRectangle

Tag Text TextAlign (inherited from TextBox) TextDetached TrimEnd TrimStart UseColumnStyles

UserCultureOverride

186 C1.Win.C1Input Namespace

UseSystemPasswordChar (inherited from TextBox) Value ValueIsDbNull VerticalAlign WordWrap (inherited from TextBoxBase) WrapDateTimeFields

Indicates if the text in the edit control should appear as the default password character. The main bindable property of a C1Input control. Gets or sets a value indicating whether the Value is DBNull. Vertical alignment of the contents in the control. Indicates if lines are automatically word-wrapped for multiline edit controls. If this property is False the month will be automatically incremented when the user spins the date past the end of the month. The same about other parts of the date/time value. Checks the result of the ParseContent method. Decrements the currently selected field in DateTimeInput mode. Increments the currently selected field in DateTimeInput mode. Parses the Text string. Overriden. Updates the control's Text with the current Value. This method works exactly as setting the Value property, except that it does not change the internal variable storing the value before editing, so the user can press Esc and restore the previous value. This method works only in edit mode. If the control is not in edit mode, this methods does nothing This method temporarily disables numeric input mode Triggers parsing of the Text property and updating the Value. Occurs when the value of the AcceptsTab property changes. Occurs when Value is retrieved from the data source. Occurs when Value is stored in the data source. Occurs when the value of the BorderStyle property changes. CultureInfo can be set up (on startup) or has been changed. Occurs when the DataType property changes. Occurs when the control receives data that cannot be formatted according to the current format and edit mask settings.

Public Methods CheckValidationResult DecDateTimeInput IncDateTimeInput ParseContent ResetText SetProposedValue

SuspendNumericInput UpdateValueWithCurrentText Public Events AcceptsTabChanged (inherited from TextBoxBase) BindingFormatting BindingParsing BorderStyleChanged (inherited from TextBoxBase) CultureInfoSetup DataTypeChanged FormatError

C1TextBox Properties 187

Formatted Formatting HideSelectionChanged (inherited from TextBoxBase) MarginsChanged ModifiedChanged (inherited from TextBoxBase) MultilineChanged (inherited from TextBoxBase) Parsed Parsing PostValidated PostValidating PreValidated PreValidating ReadOnlyChanged (inherited from TextBoxBase) TextAlignChanged (inherited from TextBox) ValidationError ValueChanged VerticalAlignChanged See Also C1TextBox Class | C1.Win.C1Input Namespace

Occurs after the value has been formatted. Formatting the value programmatically. Occurs when the value of the HideSelection property changes. Occurs when the Margins property or one of the margins has changed. Occurs when the value of the Modified property changes. Occurs when the value of the Multiline property changes. Occurs after the input string value has been converted to the DataType. Programmatic parsing of the input string. Occurs after the typed value has been validated Programmatic typed value validation. Occurs after the input string value has been validated. Programmatic input string validation. Occurs when the value of the ReadOnly property changes. Occurs when the value of the TextAlign property changes Error occurred while parsing or validating the input string. Occurs when the Value changes. Occurs when the value of the VerticalAlign property has changed.

C1TextBox Properties
The properties of the C1TextBox class are listed here. For a complete list of C1TextBox class members, see the C1TextBox Members topic. Public Properties AcceptsEscape Indicates if the ESC key that cancels modified value is handled by the control without passing it to the owner form (AcceptsEscape=True), or it is then passed to the form and can close it if the form has CancelButton (AcceptsEscape=False). Indicates if return characters are accepted as input for multiline edit controls.

AcceptsReturn (inherited from TextBox)

188 C1.Win.C1Input Namespace

AcceptsTab

Indicates if TAB and SHIFT+TAB keys are accepted by control and move the focus to the next (previous) group of input characters in edit mask and in DateTimeInput mode. Gets or sets a value indicating whether the position of the character is automatically changed. The StringCollection to use when the AutoCompleteSource property is set to CustomSource. Indicates the text completion behavior of the text box. The autocomplete source, which can be one of the values from AutoCompleteSource enumeration. Determines the style of the control's border. Indicates if the edit control can undo the previous action. True if string comparisons are case-sensitive; otherwise, False. Gets or sets a value indicating whether the control causes validation (that is, calls Validated and Validating events). Indicates if all characters should be left alone or converted to uppercase or lowercase. The culture ID. The current CultureInfo object (available at run time). The name selected for the Culture property in the Properties grid. If True, the control's stored Value is in current time zone; otherwise, the Value is adjusted to the time zone defined by the GMTOffset property Custom format specifier used if FormatType = FormatTypeEnum.CustomFormat. The field of the data source object to which the control is bound. The data source object to which the control is bound. Type of the Value property. Whether or not a special edit mode is applied to DateTime values. The value specified in the GMTOffset property can be advanced or set back due to daylight-saving time changes. Gets or sets whether the text box should be disabled when it is bound to an empty data source, that is, CurrencyManager.Count = 0.

AutoChangePosition AutoCompleteCustomSource (inherited from TextBox) AutoCompleteMode (inherited from TextBox) AutoCompleteSource (inherited from TextBox) BorderStyle CanUndo (inherited from TextBoxBase) CaseSensitive CausesValidation

CharacterCasing (inherited from TextBox) Culture CultureInfo CultureName CurrentTimeZone

CustomFormat DataField DataSource DataType DateTimeInput DaylightTimeAdjustment

DisableOnNoData

C1TextBox Properties 189

DisplayFormat

Format used to display the value when the control is not in edit mode (does not have input focus or is readonly). Format used to display the value when the control is in edit mode (has input focus and is not read-only). The edit mask string restricting user input. Returns True, if the control has input focus and TextDetached = False. If True, empty strings are interpreted as null values (DBNull). Settings affecting error handling in the control. Enumeration value determining the formatting method, including standard .NET format specifiers, custom and programmatic formatting. The time zone of the Value property used if CurrentTimeZone = False. Indicates that the selection should be hidden when the edit control loses focus. Determines the selection position when a control receives input focus. Label control associated with this input field. The lines of text in a multiline control. The spacing between the input control content and its edges, in pixels. Edit mask settings. Specifies the maximum number of characters that can be entered into the edit control. The minimum year that can be entered without leading zeros. Gets or sets a value that indicates that the control has been modified by the user since the control received the input focus or its Value last set. String representing a DBNull value. Sets or gets a value indicating whether a special edit mode is used for numeric values. Enables/disables the special keys used when NumericInput = True. Settings affecting parsing, that is, converting the string entered by the user to the data type. Indicates the character to display for password input for single-line edit controls. Validation rules applied after parsing, that is, after converting the string entered by the user to the DataType (typed validation).

EditFormat EditMask EditMode EmptyAsNull ErrorInfo FormatType

GMTOffset HideSelection (inherited from TextBoxBase) InitialSelection Label Lines Margins MaskInfo MaxLength (inherited from TextBoxBase) MinShortYear Modified

NullText NumericInput NumericInputKeys ParseInfo PasswordChar (inherited from TextBox) PostValidation

190 C1.Win.C1Input Namespace

PreValidation

Validation rules applied before parsing, that is, before converting the string entered by the user to the DataType (raw string validation). Controls whether the text in the edit control can be changed or not. Indicates, for multiline edit controls, which scroll bars will be shown for this control. The currently selected text. Overriden. The length of the currently selected text. The beginning of the currently selected text. Indicates whether shortcuts defined for the control are enabled. Specifies whether the context menu can be displayed for the control. Specifies whether a focus rectangle should be displayed around the client area when the control has the input focus. Gets or sets the object that contains data about the control Overriden. The current text in the control. Indicates how the text should be aligned for edit controls. Specifies whether the Value and Text properties can be set independently. If True, trailing spaces are removed. If True, leading spaces are removed. Indicates whether to honor the ColumnStyle properties defined on the C1ViewColumn object that this control is bound to. If True, current user regional settings override the selected culture. Indicates if the text in the edit control should appear as the default password character. The main bindable property of a C1Input control. Gets or sets a value indicating whether the Value is DBNull. Vertical alignment of the contents in the control. Indicates if lines are automatically word-wrapped for multiline edit controls. If this property is False the month will be automatically incremented when the user spins the date past the end of the month. The same about other parts of the date/time value.

ReadOnly (inherited from TextBoxBase) ScrollBars (inherited from TextBox) SelectedText SelectionLength (inherited from TextBoxBase) SelectionStart (inherited from TextBoxBase) ShortcutsEnabled (inherited from TextBoxBase) ShowContextMenu ShowFocusRectangle

Tag Text TextAlign (inherited from TextBox) TextDetached TrimEnd TrimStart UseColumnStyles

UserCultureOverride UseSystemPasswordChar (inherited from TextBox) Value ValueIsDbNull VerticalAlign WordWrap (inherited from TextBoxBase) WrapDateTimeFields

C1TextBox.AcceptsEscape Property 191

See Also C1TextBox Class | C1.Win.C1Input Namespace

C1TextBox.AcceptsEscape Property
Indicates if the ESC key that cancels modified value is handled by the control without passing it to the owner form (AcceptsEscape=True), or it is then passed to the form and can close it if the form has CancelButton (AcceptsEscape=False). [Visual Basic] Public Property AcceptsEscape As Boolean [C#] public bool AcceptsEscape {get;set;} [Delphi] public property AcceptsEscape: Boolean read get_AcceptsEscape write set_AcceptsEscape; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.AcceptsTab Property
Indicates if TAB and SHIFT+TAB keys are accepted by control and move the focus to the next (previous) group of input characters in edit mask and in DateTimeInput mode. [Visual Basic] Public Property AcceptsTab As Boolean [C#] new public bool AcceptsTab {get;set;} [Delphi] public property AcceptsTab: Boolean read get_AcceptsTab write set_AcceptsTab; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.AutoChangePosition Property
Gets or sets a value indicating whether the position of the character is automatically changed [Visual Basic] Public Property AutoChangePosition As Boolean [C#] public bool AutoChangePosition {get;set;} [Delphi] public property AutoChangePosition: Boolean read get_AutoChangePosition write set_AutoChangePosition;

192 C1.Win.C1Input Namespace

See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.BorderStyle Property
Determines the style of the control's border [Visual Basic] Public Property BorderStyle As BorderStyle [C#] new public BorderStyle BorderStyle {get;set;} [Delphi] public property BorderStyle: BorderStyle read get_BorderStyle write set_BorderStyle; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.CaseSensitive Property
True if string comparisons are case-sensitive; otherwise, False. [Visual Basic] Public Property CaseSensitive As Boolean [C#] public bool CaseSensitive {get;set;} [Delphi] public property CaseSensitive: Boolean read get_CaseSensitive write set_CaseSensitive; Remarks The default is False.See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.CausesValidation Property
Gets or sets a value indicating whether the control causes validation (such as, calls Validated and Validating events). [Visual Basic] Public Property CausesValidation As Boolean [C#] new public bool CausesValidation {get;set;} [Delphi] public property CausesValidation: Boolean read get_CausesValidation write set_CausesValidation;

C1TextBox.Culture Property 193

See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.Culture Property
The culture ID. [Visual Basic] Public Property Culture As Integer [C#] public int Culture {get;set;} [Delphi] public property Culture: Int32 read get_Culture write set_Culture; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.CultureInfo Property
The current CultureInfo object (available at run time). [Visual Basic] Public ReadOnly Property CultureInfo As CultureInfo [C#] public CultureInfo CultureInfo {get;} [Delphi] public property CultureInfo: CultureInfo read get_CultureInfo; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.CultureName Property
The name selected for the Culture property in the Properties grid. [Visual Basic] Public ReadOnly Property CultureName As String [C#] public string CultureName {get;} [Delphi] public property CultureName: String read get_CultureName; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.CurrentTimeZone Property
If True, the control's stored Value is in current time zone; otherwise, the Value is adjusted to the time zone defined by the GMTOffset property

194 C1.Win.C1Input Namespace

[Visual Basic] Public Property CurrentTimeZone As Boolean [C#] public bool CurrentTimeZone {get;set;} [Delphi] public property CurrentTimeZone: Boolean read get_CurrentTimeZone write set_CurrentTimeZone; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.CustomFormat Property
Custom format specifier used if FormatType = FormatTypeEnum.CustomFormat. [Visual Basic] Public Property CustomFormat As String [C#] public string CustomFormat {get;set;} [Delphi] public property CustomFormat: String read get_CustomFormat write set_CustomFormat; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.DataField Property
The field of the data source object to which the control is bound. [Visual Basic] Public Property DataField As String [C#] public string DataField {get;set;} [Delphi] public property DataField: String read get_DataField write set_DataField; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.DataSource Property
The data source object to which the control is bound. [Visual Basic] Public Property DataSource As Object

C1TextBox.DataType Property 195

[C#] public object DataSource {get;set;} [Delphi] public property DataSource: Object read get_DataSource write set_DataSource; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.DataType Property
Type of the Value property. [Visual Basic] Overridable Public Property DataType As Type [C#] virtual public Type DataType {get;set;} [Delphi] public property DataType: Type read get_DataType write set_DataType; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.DateTimeInput Property
Whether or not a special edit mode is applied to DateTime values. [Visual Basic] Overridable Public Property DateTimeInput As Boolean [C#] virtual public bool DateTimeInput {get;set;} [Delphi] public property DateTimeInput: Boolean read get_DateTimeInput write set_DateTimeInput; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.DaylightTimeAdjustment Property
The value specified in the GMTOffset property can be advanced or set back due to daylight-saving time changes. [Visual Basic] Public Property DaylightTimeAdjustment As DaylightTimeAdjustmentEnum [C#] public DaylightTimeAdjustmentEnum DaylightTimeAdjustment {get;set;}

196 C1.Win.C1Input Namespace

[Delphi] public property DaylightTimeAdjustment: DaylightTimeAdjustmentEnum read get_DaylightTimeAdjustment write set_DaylightTimeAdjustment; Remarks The default is NoAdjustments. See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.DisableOnNoData Property
Gets or sets whether the text box should be disabled when it is bound to an empty data source, such as CurrencyManager.Count = 0. [Visual Basic] Public Property DisableOnNoData As Boolean [C#] public bool DisableOnNoData {get;set;} [Delphi] public property DisableOnNoData: Boolean read get_DisableOnNoData write set_DisableOnNoData; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.DisplayFormat Property
Format used to display the value when the control is not in edit mode (does not have input focus or is readonly). [Visual Basic] Public ReadOnly Property DisplayFormat As FormatInfo [C#] public FormatInfo DisplayFormat {get;} [Delphi] public property DisplayFormat: FormatInfo read get_DisplayFormat; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.EditFormat Property
Format used to display the value when the control is in edit mode (has input focus and is not read-only). [Visual Basic] Public ReadOnly Property EditFormat As FormatInfo [C#] public FormatInfo EditFormat {get;}

C1TextBox.EditMask Property 197

[Delphi] public property EditFormat: FormatInfo read get_EditFormat; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.EditMask Property
The edit mask string restricting user input. [Visual Basic] Public Property EditMask As String [C#] public string EditMask {get;set;} [Delphi] public property EditMask: String read get_EditMask write set_EditMask; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.EditMode Property
Returns True, if the control has input focus and TextDetached = False. [Visual Basic] Public ReadOnly Property EditMode As Boolean [C#] public bool EditMode {get;} [Delphi] public property EditMode: Boolean read get_EditMode; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.EmptyAsNull Property
If True, empty strings are interpreted as null values (DBNull). [Visual Basic] Public Property EmptyAsNull As Boolean [C#] public bool EmptyAsNull {get;set;} [Delphi] public property EmptyAsNull: Boolean read get_EmptyAsNull write set_EmptyAsNull; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

198 C1.Win.C1Input Namespace

C1TextBox.ErrorInfo Property
Settings affecting error handling in the control. [Visual Basic] Public ReadOnly Property ErrorInfo As ErrorInfo [C#] public ErrorInfo ErrorInfo {get;} [Delphi] public property ErrorInfo: ErrorInfo read get_ErrorInfo; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.FormatType Property
Enumeration value determining the formatting method, including standard .NET format specifiers, custom and programmatic formatting. [Visual Basic] Public Property FormatType As FormatTypeEnum [C#] public FormatTypeEnum FormatType {get;set;} [Delphi] public property FormatType: FormatTypeEnum read get_FormatType write set_FormatType; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.GMTOffset Property
The time zone of the Value property used if CurrentTimeZone = False. [Visual Basic] Public Property GMTOffset As TimeSpan [C#] public TimeSpan GMTOffset {get;set;} [Delphi] public property GMTOffset: TimeSpan read get_GMTOffset write set_GMTOffset; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.InitialSelection Property
Determines the selection position when a control receives input focus.

C1TextBox.Label Property 199

[Visual Basic] Public Property InitialSelection As InitialSelectionEnum [C#] public InitialSelectionEnum InitialSelection {get;set;} [Delphi] public property InitialSelection: InitialSelectionEnum read get_InitialSelection write set_InitialSelection; Remarks The default is InitialSelectionEnum.SelectAll. See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.Label Property
Label control associated with this input field. [Visual Basic] Public Property Label As Label [C#] public Label Label {get;set;} [Delphi] public property Label: Label read get_Label write set_Label; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.Lines Property
The lines of text in a multiline control. [Visual Basic] Public Property Lines As String() [C#] new public string[] Lines {get;set;} [Delphi] public property Lines: array of String read get_Lines write set_Lines; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.Margins Property
The spacing between the input control content and its edges, in pixels. [Visual Basic] Public Property Margins As Margins

200 C1.Win.C1Input Namespace

[C#] public Margins Margins {get;set;} [Delphi] public property Margins: Margins read get_Margins write set_Margins; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.MaskInfo Property
Edit mask settings. [Visual Basic] Public ReadOnly Property MaskInfo As MaskInfo [C#] public MaskInfo MaskInfo {get;} [Delphi] public property MaskInfo: MaskInfo read get_MaskInfo; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.MinShortYear Property
The minimum year that can be entered without leading zeros. [Visual Basic] Public Property MinShortYear As Integer [C#] public int MinShortYear {get;set;} [Delphi] public property MinShortYear: Int32 read get_MinShortYear write set_MinShortYear; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.Modified Property
Gets or sets a value that indicates that the control has been modified by the user since the control received the input focus or its Value last set. [Visual Basic] Public Property Modified As Boolean [C#] new public bool Modified {get;set;}

C1TextBox.NullText Property 201

[Delphi] public property Modified: Boolean read get_Modified write set_Modified; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.NullText Property
String representing a DBNull value. [Visual Basic] Public Property NullText As String [C#] public string NullText {get;set;} [Delphi] public property NullText: String read get_NullText write set_NullText; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.NumericInput Property
Sets or gets a value indicating whether a special edit mode is used for numeric values. [Visual Basic] Overridable Public Property NumericInput As Boolean [C#] virtual public bool NumericInput {get;set;} [Delphi] public property NumericInput: Boolean read get_NumericInput write set_NumericInput; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.NumericInputKeys Property
Enables/disables the special keys used when NumericInput = True. [Visual Basic] Public Property NumericInputKeys As NumericInputKeyFlags [C#] public NumericInputKeyFlags NumericInputKeys {get;set;} [Delphi] public property NumericInputKeys: NumericInputKeyFlags read get_NumericInputKeys write set_NumericInputKeys;

202 C1.Win.C1Input Namespace

Remarks The default is NumericInputKeyFlags.Standard. See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.ParseInfo Property
Settings affecting parsing, that is, converting the string entered by the user to the data type. [Visual Basic] Public ReadOnly Property ParseInfo As ParseInfo [C#] public ParseInfo ParseInfo {get;} [Delphi] public property ParseInfo: ParseInfo read get_ParseInfo; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.PostValidation Property
Validation rules applied after parsing, that is, after converting the string entered by the user to the DataType (typed validation). [Visual Basic] Public ReadOnly Property PostValidation As PostValidation [C#] public PostValidation PostValidation {get;} [Delphi] public property PostValidation: PostValidation read get_PostValidation; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.PreValidation Property
Validation rules applied before parsing, that is, before converting the string entered by the user to the DataType (raw string validation). [Visual Basic] Public ReadOnly Property PreValidation As PreValidation [C#] public PreValidation PreValidation {get;} [Delphi] public property PreValidation: PreValidation read get_PreValidation;

C1TextBox.SelectedText Property 203

See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.SelectedText Property
The currently selected text. [Visual Basic] Overrides Public Property SelectedText As String [C#] override public string SelectedText {get;set;} [Delphi] public property SelectedText: String read get_SelectedText write set_SelectedText; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.ShowContextMenu Property
Specifies whether the context menu can be displayed for the control. [Visual Basic] Public Property ShowContextMenu As Boolean [C#] public bool ShowContextMenu {get;set;} [Delphi] public property ShowContextMenu: Boolean read get_ShowContextMenu write set_ShowContextMenu; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.ShowFocusRectangle Property
Specifies whether a focus rectangle should be displayed around the client area when the control has the input focus. [Visual Basic] Public Property ShowFocusRectangle As Boolean [C#] public bool ShowFocusRectangle {get;set;} [Delphi] public property ShowFocusRectangle: Boolean read get_ShowFocusRectangle write set_ShowFocusRectangle; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

204 C1.Win.C1Input Namespace

C1TextBox.Tag Property
Gets or sets the object that contains data about the control [Visual Basic] Public Property Tag As Object [C#] new public object Tag {get;set;} [Delphi] public property Tag: Object read get_Tag write set_Tag; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.Text Property
The current text in the control. [Visual Basic] Overrides Public Property Text As String [C#] override public string Text {get;set;} [Delphi] public property Text: String read get_Text write set_Text; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.TextDetached Property
Specifies whether the Value and Text properties can be set independently. [Visual Basic] Public Property TextDetached As Boolean [C#] public bool TextDetached {get;set;} [Delphi] public property TextDetached: Boolean read get_TextDetached write set_TextDetached; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.TrimEnd Property
If True, trailing spaces are removed. [Visual Basic] Public Property TrimEnd As Boolean

C1TextBox.TrimStart Property 205

[C#] public bool TrimEnd {get;set;} [Delphi] public property TrimEnd: Boolean read get_TrimEnd write set_TrimEnd; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.TrimStart Property
If True, leading spaces are removed. [Visual Basic] Public Property TrimStart As Boolean [C#] public bool TrimStart {get;set;} [Delphi] public property TrimStart: Boolean read get_TrimStart write set_TrimStart; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.UseColumnStyles Property
Indicates whether to honor the ColumnStyle properties defined on the C1ViewColumn object that this control is bound to. [Visual Basic] Public Property UseColumnStyles As Boolean [C#] public bool UseColumnStyles {get;set;} [Delphi] public property UseColumnStyles: Boolean read get_UseColumnStyles write set_UseColumnStyles; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.UserCultureOverride Property
If True, current user regional settings override the selected culture. [Visual Basic] Public Property UserCultureOverride As Boolean [C#] public bool UserCultureOverride {get;set;}

206 C1.Win.C1Input Namespace

[Delphi] public property UserCultureOverride: Boolean read get_UserCultureOverride write set_UserCultureOverride; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.Value Property
The main bindable property of a C1Input control. [Visual Basic] Public Property Value As Object [C#] public object Value {get;set;} [Delphi] public property Value: Object read get_Value write set_Value; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.ValueIsDbNull Property
Gets or sets a value indicating whether the Value is DBNull. [Visual Basic] Public Property ValueIsDbNull As Boolean [C#] public bool ValueIsDbNull {get;set;} [Delphi] public property ValueIsDbNull: Boolean read get_ValueIsDbNull write set_ValueIsDbNull; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.VerticalAlign Property
Vertical alignment of the contents in the control. [Visual Basic] Public Property VerticalAlign As VerticalAlignEnum [C#] public VerticalAlignEnum VerticalAlign {get;set;} [Delphi] public property VerticalAlign: VerticalAlignEnum read get_VerticalAlign write set_VerticalAlign;

C1TextBox.WrapDateTimeFields Property 207

Remarks The default is VerticalAlignEnum.Top. See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.WrapDateTimeFields Property
If this property is False the month will be automatically incremented when the user spins the date past the end of the month. The same about other parts of the date/time value. [Visual Basic] Public Property WrapDateTimeFields As Boolean [C#] public bool WrapDateTimeFields {get;set;} [Delphi] public property WrapDateTimeFields: Boolean read get_WrapDateTimeFields write set_WrapDateTimeFields; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox Methods
The methods of the C1TextBox class are listed here. For a complete list of C1TextBox class members, see the C1TextBox Members topic. Public Methods CheckValidationResult DecDateTimeInput IncDateTimeInput ParseContent ResetText SetProposedValue Checks the result of the ParseContent method. Decrements the currently selected field in DateTimeInput mode. Increments the currently selected field in DateTimeInput mode. Parses the Text string. Overriden. Updates the control's Text with the current Value. This method works exactly as setting the Value property, except that it does not change the internal variable storing the value before editing, so the user can press Esc and restore the previous value. This method works only in edit mode. If the control is not in edit mode, this methods does nothing This method temporarily disables numeric input mode Triggers parsing of the Text property and updating the Value.

SuspendNumericInput UpdateValueWithCurrentText See Also C1TextBox Class | C1.Win.C1Input Namespace

208 C1.Win.C1Input Namespace

C1TextBox.CheckValidationResult Method
Checks the result of the ParseContent method. [Visual Basic] Public Function CheckValidationResult( _ ByVal reason As ErrorReasonEnum, _ ByRef parsedValue As Object, _ ByVal errorInfo As ErrorInfo _ ) As Boolean [C#] public bool CheckValidationResult( ErrorReasonEnum reason, ref object parsedValue, ErrorInfo errorInfo ); [Delphi] public function CheckValidationResult( reason: ErrorReasonEnum; var parsedValue: Object; errorInfo: ErrorInfo ): Boolean; Parameters reason Value indicating the reason of validation failure parsedValue Parsed value of type DataType that was undergoing validation errorInfo Object detailing error information, if an error occurred See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.DecDateTimeInput Method
Decrements the currently selected field in DateTimeInput mode. [Visual Basic] Public Sub DecDateTimeInput() [C#] public void DecDateTimeInput() [Delphi] public procedure DecDateTimeInput(); See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.IncDateTimeInput Method 209

C1TextBox.IncDateTimeInput Method
Increments the currently selected field in DateTimeInput mode. [Visual Basic] Public Sub IncDateTimeInput() [C#] public void IncDateTimeInput() [Delphi] public procedure IncDateTimeInput(); See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.ParseContent Method
Parses the Text string. [Visual Basic] Public Function ParseContent( _ ByRef parsedValue As Object, _ ByVal errorInfo As ErrorInfo _ ) As ErrorReasonEnum [C#] public ErrorReasonEnum ParseContent( out object parsedValue, ErrorInfo errorInfo ); [Delphi] public function ParseContent( out parsedValue: Object; errorInfo: ErrorInfo ): ErrorReasonEnum; Parameters parsedValue Output parameter: Parsing result errorInfo Output parameter: Object detailing error information, if an error occurred See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.ResetText Method
Updates the control's Text with the current Value. [Visual Basic] Overrides Public Sub ResetText()

210 C1.Win.C1Input Namespace

[C#] override public void ResetText() [Delphi] public procedure ResetText(); override; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.SetProposedValue Method
This method works exactly as setting the Value property, except that it does not change the internal variable storing the value before editing, so the user can press Esc and restore the previous value. This method works only in edit mode. If the control is not in edit mode, this methods does nothing [Visual Basic] Public Sub SetProposedValue( _ ByVal value As Object _ ) [C#] public void SetProposedValue( object value ); [Delphi] public procedure SetProposedValue( value: Object ); Parameters value See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.SuspendNumericInput Method
This method temporarily disables numeric input mode [Visual Basic] Public Sub SuspendNumericInput( _ ByVal suspend As Boolean, _ ByVal updateValue As Boolean _ ) [C#] public void SuspendNumericInput( bool suspend, bool updateValue );

C1TextBox.UpdateValueWithCurrentText Method 211

[Delphi] public procedure SuspendNumericInput( suspend: Boolean; updateValue: Boolean ); Parameters suspend True to suspend numeric input, False to resume it. updateValue If True, control's Value is updated, obtained from the current control text. See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.UpdateValueWithCurrentText Method
Triggers parsing of the Text property and updating the Value. [Visual Basic] Public Function UpdateValueWithCurrentText() As Boolean [C#] public bool UpdateValueWithCurrentText() [Delphi] public function UpdateValueWithCurrentText(): Boolean; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox Events
The events of the C1TextBox class are listed here. For a complete list of C1TextBox class members, see the C1TextBox Members topic. Public Events AcceptsTabChanged (inherited from TextBoxBase) BindingFormatting BindingParsing BorderStyleChanged (inherited from TextBoxBase) CultureInfoSetup DataTypeChanged FormatError Occurs when the value of the AcceptsTab property changes. Occurs when Value is retrieved from the data source. Occurs when Value is stored in the data source. Occurs when the value of the BorderStyle property changes. CultureInfo can be set up (on startup) or has been changed. Occurs when the DataType property changes. Occurs when the control receives data that cannot be formatted according to the current format and edit mask settings. Occurs after the value has been formatted.

Formatted

212 C1.Win.C1Input Namespace

Formatting HideSelectionChanged (inherited from TextBoxBase) MarginsChanged ModifiedChanged (inherited from TextBoxBase) MultilineChanged (inherited from TextBoxBase) Parsed Parsing PostValidated PostValidating PreValidated PreValidating ReadOnlyChanged (inherited from TextBoxBase) TextAlignChanged (inherited from TextBox) ValidationError ValueChanged VerticalAlignChanged See Also C1TextBox Class | C1.Win.C1Input Namespace

Formatting the value programmatically. Occurs when the value of the HideSelection property changes. Occurs when the Margins property or one of the margins has changed. Occurs when the value of the Modified property changes. Occurs when the value of the Multiline property changes. Occurs after the input string value has been converted to the DataType. Programmatic parsing of the input string. Occurs after the typed value has been validated Programmatic typed value validation. Occurs after the input string value has been validated. Programmatic input string validation. Occurs when the value of the ReadOnly property changes. Occurs when the value of the TextAlign property changes Error occurred while parsing or validating the input string. Occurs when the Value changes. Occurs when the value of the VerticalAlign property has changed.

C1TextBox.BindingFormatting Event
Occurs when Value is retrieved from the data source. [Visual Basic] Public Event BindingFormatting AsConvertEventHandlerConvertEventHandler [C#] public eventConvertEventHandlerConvertEventHandler BindingFormatting [Delphi] public property BindingFormatting: ConvertEventHandler read remove_BindingFormatting write add_BindingFormatting;

C1TextBox.BindingParsing Event 213

Example The following code provides an example of the BindingFormatting event: Visual Basic Private Sub C1DateEdit1_BindingFormatting(sender As Object, e As System.Windows.Forms.ConvertEventArgs) If ((e.DesiredType = GetType(DateTime)) And TypeOf e.Value Is String) Then Dim s As String = CStr(e.Value) If s Is Nothing Or s = [String].Empty Then e.Value = Nothing Else e.Value = DateTime.Today.AddDays(Integer.Parse(s)) End If End If End Sub C# private void c1DateEdit1_BindingFormatting(object sender, System.Windows.Forms.ConvertEventArgs e) { if (e.DesiredType == typeof(DateTime) && e.Value is string) { string s = (string)e.Value; if (s == null || s == String.Empty) { e.Value = null; } else { e.Value = DateTime.Today.AddDays(int.Parse(s)); } } } Delphi procedure C1DateEdit1_BindingFormatting(sender: Tobject; c: ConvertEventArgs); begin if((e.DesiredType = typeof(DateTime)) and (e.Value is string))then begin s := (e.Value as string); if ((s = nil) or (s = string.Empty)) then e.Value := nil else e.Value := DateTime.Today.AddDays((Integer.Parse(s))) end; end;

See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.BindingParsing Event
Occurs when Value is stored in the data source.

214 C1.Win.C1Input Namespace

[Visual Basic] Public Event BindingParsing AsConvertEventHandlerConvertEventHandler [C#] public eventConvertEventHandlerConvertEventHandler BindingParsing [Delphi] public property BindingParsing: ConvertEventHandler read remove_BindingParsing write add_BindingParsing; Example The following code provides an example of the BindingParsing event: Visual Basic Private Sub C1DateEdit1_BindingParsing(sender As Object, e As System.Windows.Forms.ConvertEventArgs) If e.DesiredType = GetType(String) Then If ((e.Value Is Nothing) Or TypeOf e.Value Is DBNull) Then e.Value = "" Else If TypeOf e.Value Is DateTime Then e.Value = CType(CType(e.Value, DateTime).Subtract(DateTime.Today), TimeSpan).Days.ToString() End If End If End If End Sub C# private void c1DateEdit1_BindingParsing(object sender, System.Windows.Forms.ConvertEventArgs e) { if (e.DesiredType == typeof(string)) { if (e.Value == null || e.Value is DBNull) { e.Value = ""; } else if (e.Value is DateTime) { e.Value = ((TimeSpan)(((DateTime)e.Value).Subtract(DateTime.Today))).Days.ToString(); } } } Delphi procedure C1DateEdit1_BindingParsing(sender: Tobject; e: ConvertEventArgs); begin if (e.DesiredType = typeof(string)) then if ((e.Value = nil) or (e.Value is DBNull)) then e.Value := '' else if ((e.Value is DateTime)) then e.Value := ((TimeSpan)(((DateTime)e.Value).Subtract(DateTime.Today))).Days.ToString(); end;

C1TextBox.CultureInfoSetup Event 215

See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.CultureInfoSetup Event
CultureInfo can be set up (on startup) or has been changed. [Visual Basic] Public Event CultureInfoSetup AsCultureInfoSetupEventHandlerCultureInfoSetupEventHandler [C#] public eventCultureInfoSetupEventHandlerCultureInfoSetupEventHandler CultureInfoSetup [Delphi] public property CultureInfoSetup: CultureInfoSetupEventHandler read remove_CultureInfoSetup write add_CultureInfoSetup; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.DataTypeChanged Event
Occurs when the DataType property changes. [Visual Basic] Public Event DataTypeChanged AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler DataTypeChanged [Delphi] public property DataTypeChanged: EventHandler read remove_DataTypeChanged write add_DataTypeChanged; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.FormatError Event
Occurs when the control receives data that cannot be formatted according to the current format and edit mask settings. [Visual Basic] Public Event FormatError AsFormatErrorEventHandlerFormatErrorEventHandler [C#] public eventFormatErrorEventHandlerFormatErrorEventHandler FormatError [Delphi] public property FormatError: FormatErrorEventHandler read remove_FormatError write add_FormatError;

216 C1.Win.C1Input Namespace

See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.Formatted Event
Occurs after the value has been formatted. [Visual Basic] Public Event Formatted AsFormatEventHandlerFormatEventHandler [C#] public eventFormatEventHandlerFormatEventHandler Formatted [Delphi] public property Formatted: FormatEventHandler read remove_Formatted write add_Formatted; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.Formatting Event
Formatting the value programmatically. [Visual Basic] Public Event Formatting AsFormatEventHandlerFormatEventHandler [C#] public eventFormatEventHandlerFormatEventHandler Formatting [Delphi] public property Formatting: FormatEventHandler read remove_Formatting write add_Formatting; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.MarginsChanged Event
Occurs when the Margins property or one of the margins has changed. [Visual Basic] Public Event MarginsChanged AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler MarginsChanged [Delphi] public property MarginsChanged: EventHandler read remove_MarginsChanged write add_MarginsChanged; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.Parsed Event 217

C1TextBox.Parsed Event
Occurs after the input string value has been converted to the DataType. [Visual Basic] Public Event Parsed AsParseEventHandlerParseEventHandler [C#] public eventParseEventHandlerParseEventHandler Parsed [Delphi] public property Parsed: ParseEventHandler read remove_Parsed write add_Parsed; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.Parsing Event
Programmatic parsing of the input string. [Visual Basic] Public Event Parsing AsParseEventHandlerParseEventHandler [C#] public eventParseEventHandlerParseEventHandler Parsing [Delphi] public property Parsing: ParseEventHandler read remove_Parsing write add_Parsing; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.PostValidated Event
Occurs after the typed value has been validated [Visual Basic] Public Event PostValidated AsPostValidationEventHandlerPostValidationEventHandler [C#] public eventPostValidationEventHandlerPostValidationEventHandler PostValidated [Delphi] public property PostValidated: PostValidationEventHandler read remove_PostValidated write add_PostValidated; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

218 C1.Win.C1Input Namespace

C1TextBox.PostValidating Event
Programmatic typed value validation. [Visual Basic] Public Event PostValidating AsPostValidationEventHandlerPostValidationEventHandler [C#] public eventPostValidationEventHandlerPostValidationEventHandler PostValidating [Delphi] public property PostValidating: PostValidationEventHandler read remove_PostValidating write add_PostValidating; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.PreValidated Event
Occurs after the input string value has been validated. [Visual Basic] Public Event PreValidated AsPreValidationEventHandlerPreValidationEventHandler [C#] public eventPreValidationEventHandlerPreValidationEventHandler PreValidated [Delphi] public property PreValidated: PreValidationEventHandler read remove_PreValidated write add_PreValidated; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.PreValidating Event
Programmatic input string validation. [Visual Basic] Public Event PreValidating AsPreValidationEventHandlerPreValidationEventHandler [C#] public eventPreValidationEventHandlerPreValidationEventHandler PreValidating [Delphi] public property PreValidating: PreValidationEventHandler read remove_PreValidating write add_PreValidating;

C1TextBox.ValidationError Event 219

See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.ValidationError Event
Error occurred while parsing or validating the input string. [Visual Basic] Public Event ValidationError AsValidationErrorEventHandlerValidationErrorEventHandler [C#] public eventValidationErrorEventHandlerValidationErrorEventHandler ValidationError [Delphi] public property ValidationError: ValidationErrorEventHandler read remove_ValidationError write add_ValidationError; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.ValueChanged Event
Occurs when the Value changes. [Visual Basic] Public Event ValueChanged AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler ValueChanged [Delphi] public property ValueChanged: EventHandler read remove_ValueChanged write add_ValueChanged; Example The following code changes the value of the C1TextBox control: Visual Basic Private Sub FontEditor1_ValueChanged(sender As Object, e As System.EventArgs) Try Dim font As Font = fontEdit1.Value If Not (font Is Nothing) Then label1.Font = font End If Catch End Try End Sub C# private void fontEditor1_ValueChanged(object sender, System.EventArgs e) { try {

220 C1.Win.C1Input Namespace

Font font = fontEdit1.Value as Font; if (font != null) label1.Font = font; } catch {} } Delphi procedure FontEditor1_ValueChanged(sender: object; e: System.EventArgs); var font := Font; begin try font := FontEdit1.Value as Font; if (font <> nil) then label1.Font := font; except on System.Exception do end;

See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

C1TextBox.VerticalAlignChanged Event
Occurs when the value of the VerticalAlign property has changed. [Visual Basic] Public Event VerticalAlignChanged AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler VerticalAlignChanged [Delphi] public property VerticalAlignChanged: EventHandler read remove_VerticalAlignChanged write add_VerticalAlignChanged; See Also C1TextBox Class | C1TextBox Members | C1.Win.C1Input Namespace

CustomPlaceholder Class
Custom user-defined characters (placeholders) used in edit mask and in wildcard patterns in pre-validation. For a list of all members of this type, see CustomPlaceholder Members. System.Object C1.Win.C1Input.CustomPlaceholder [Visual Basic] Public Class CustomPlaceholder ImplementsICloneableICloneable,ISerializableISerializable

CustomPlaceholder Members 221

[C#] public class CustomPlaceholder :ICloneableICloneable,ISerializableISerializable [Delphi] type CustomPlaceholder = class (TObject,(TObject,ICloneableICloneable,ISerializableISerializable); Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also CustomPlaceholder Members | C1.Win.C1Input Namespace

CustomPlaceholder Members
CustomPlaceholder overview Public Properties CaseSensitive Excluding LookupChars Optional Placeholder See Also CustomPlaceholder Class | C1.Win.C1Input Namespace True if string comparison is case-sensitive; otherwise, False. Specifies whether the LookupChars are interpreted as allowed or disallowed characters. The list (string) of characters matching the placeholder (see also Excluding). True if character is optional and can be omitted. The special character used as a user-defined placeholder.

CustomPlaceholder Properties
The properties of the CustomPlaceholder class are listed here. For a complete list of CustomPlaceholder class members, see the CustomPlaceholder Members topic. Public Properties CaseSensitive Excluding LookupChars Optional Placeholder See Also CustomPlaceholder Class | C1.Win.C1Input Namespace True if string comparison is case-sensitive; otherwise, False. Specifies whether the LookupChars are interpreted as allowed or disallowed characters. The list (string) of characters matching the placeholder (see also Excluding). True if character is optional and can be omitted. The special character used as a user-defined placeholder.

222 C1.Win.C1Input Namespace

CustomPlaceholder.CaseSensitive Property
True if string comparison is case-sensitive; otherwise, False. [Visual Basic] Public Property CaseSensitive As Boolean [C#] public bool CaseSensitive {get;set;} [Delphi] public property CaseSensitive: Boolean read get_CaseSensitive write set_CaseSensitive; See Also CustomPlaceholder Class | CustomPlaceholder Members | C1.Win.C1Input Namespace

CustomPlaceholder.Excluding Property
Specifies whether the LookupChars are interpreted as allowed or disallowed characters. [Visual Basic] Public Property Excluding As Boolean [C#] public bool Excluding {get;set;} [Delphi] public property Excluding: Boolean read get_Excluding write set_Excluding; See Also CustomPlaceholder Class | CustomPlaceholder Members | C1.Win.C1Input Namespace

CustomPlaceholder.LookupChars Property
The list (string) of characters matching the placeholder (see also Excluding). [Visual Basic] Public Property LookupChars As String [C#] public string LookupChars {get;set;} [Delphi] public property LookupChars: String read get_LookupChars write set_LookupChars; See Also CustomPlaceholder Class | CustomPlaceholder Members | C1.Win.C1Input Namespace

CustomPlaceholder.Optional Property
True if character is optional and can be omitted.

CustomPlaceholder.Placeholder Property 223

[Visual Basic] Public Property Optional As Boolean [C#] public bool Optional {get;set;} [Delphi] public property Optional: Boolean read get_Optional write set_Optional; See Also CustomPlaceholder Class | CustomPlaceholder Members | C1.Win.C1Input Namespace

CustomPlaceholder.Placeholder Property
The special character used as a user-defined placeholder. [Visual Basic] Public Property Placeholder As Char [C#] public char Placeholder {get;set;} [Delphi] public property Placeholder: Char read get_Placeholder write set_Placeholder; See Also CustomPlaceholder Class | CustomPlaceholder Members | C1.Win.C1Input Namespace

DateEditMonthCalendar Class
The calendar used as a drop-down in the C1DateEdit control. For a list of all members of this type, see DateEditMonthCalendar Members. System.Object System.MarshalByRefObject System.ComponentModel.Component System.Windows.Forms.Control System.Windows.Forms.MonthCalendar C1.Win.C1Input.DateEditMonthCalendar [Visual Basic] Public Class DateEditMonthCalendar InheritsMonthCalendarMonthCalendar [C#] public class DateEditMonthCalendar :MonthCalendarMonthCalendar [Delphi] type DateEditMonthCalendar = class (MonthCalendarMonthCalendar);(MonthCalendarMonthCalendar);

224 C1.Win.C1Input Namespace

Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also DateEditMonthCalendar Members | C1.Win.C1Input Namespace

DateEditMonthCalendar Members
DateEditMonthCalendar overview Public Properties AnnuallyBoldedDates (inherited from MonthCalendar) BackColor (inherited from MonthCalendar) CalendarDimensions (inherited from MonthCalendar) FirstDayOfWeek (inherited from MonthCalendar) ForeColor (inherited from MonthCalendar) MaxDate (inherited from MonthCalendar) MinDate (inherited from MonthCalendar) MonthlyBoldedDates (inherited from MonthCalendar) RightToLeftLayout (inherited from MonthCalendar) ScrollChange (inherited from MonthCalendar) ShowClearButton ShowTodayButton ShowTodayCircle (inherited from MonthCalendar) ShowWeekNumbers (inherited from MonthCalendar) Indicates which annual dates should be boldface. The background color displayed within the month. The number of rows and columns of months in a month calendar. The first day of the week. The color used to display text within a month. The maximum date that can be selected for a month calendar control. The minimum date that can be selected for a month calendar control. Indicates which monthly dates to bold. Indicates whether the control layout is right-to-left when the RightToLeft property is set to Yes. The number of months that a single click on a next/previous button moves the display by. Determines if the Clear button of the drop-down calendar is visible. Determines if the Today button of the drop-down calendar is visible. Indicates whether the month calendar control will circle the "today" date. Indicates whether the month calendar control will display week numbers (1 to 52) to the left of each row of days. The minimum size required to display a full month. The background color displayed in the calendar's title. The color used to display text within the calendar's title. The current day. Indicates if the current day has been set. The color used to display the previous and following months that appear on the month calendar. The string collection of user interface strings used in the calendar.

SingleMonthSize (inherited from MonthCalendar) TitleBackColor (inherited from MonthCalendar) TitleForeColor (inherited from MonthCalendar) TodayDate (inherited from MonthCalendar) TodayDateSet (inherited from MonthCalendar) TrailingForeColor (inherited from MonthCalendar) UIStrings

DateEditMonthCalendar Properties 225

Public Events ClearButtonClick ClearButtonVisibilityChanged DateValueChanged DateValueSelected RightToLeftLayoutChanged (inherited from MonthCalendar) TodayButtonClick TodayButtonVisibilityChanged See Also DateEditMonthCalendar Class | C1.Win.C1Input Namespace Occurs when Clear button is clicked. Occurs when Clear button visibility is changed. Occurs when the value of the Date property is changed. Occurs when the user selects a new value for the Date property. Occurs when the value of the RightToLeftLayout property changes. Occurs when Today button is clicked. Occurs when Today button visibility is changed.

DateEditMonthCalendar Properties
The properties of the DateEditMonthCalendar class are listed here. For a complete list of DateEditMonthCalendar class members, see the DateEditMonthCalendar Members topic. Public Properties AnnuallyBoldedDates (inherited from MonthCalendar) BackColor (inherited from MonthCalendar) CalendarDimensions (inherited from MonthCalendar) FirstDayOfWeek (inherited from MonthCalendar) ForeColor (inherited from MonthCalendar) MaxDate (inherited from MonthCalendar) MinDate (inherited from MonthCalendar) MonthlyBoldedDates (inherited from MonthCalendar) RightToLeftLayout (inherited from MonthCalendar) ScrollChange (inherited from MonthCalendar) ShowClearButton ShowTodayButton ShowTodayCircle (inherited from MonthCalendar) ShowWeekNumbers (inherited from MonthCalendar) Indicates which annual dates should be boldface. The background color displayed within the month. The number of rows and columns of months in a month calendar. The first day of the week. The color used to display text within a month. The maximum date that can be selected for a month calendar control. The minimum date that can be selected for a month calendar control. Indicates which monthly dates to bold. Indicates whether the control layout is right-to-left when the RightToLeft property is set to Yes. The number of months that a single click on a next/previous button moves the display by. Determines if the Clear button of the drop-down calendar is visible. Determines if the Today button of the drop-down calendar is visible. Indicates whether the month calendar control will circle the "today" date. Indicates whether the month calendar control will display week numbers (1 to 52) to the left of each row of days.

226 C1.Win.C1Input Namespace

SingleMonthSize (inherited from MonthCalendar) TitleBackColor (inherited from MonthCalendar) TitleForeColor (inherited from MonthCalendar) TodayDate (inherited from MonthCalendar) TodayDateSet (inherited from MonthCalendar) TrailingForeColor (inherited from MonthCalendar) UIStrings See Also

The minimum size required to display a full month. The background color displayed in the calendar's title. The color used to display text within the calendar's title. The current day. Indicates if the current day has been set. The color used to display the previous and following months that appear on the month calendar. The string collection of user interface strings used in the calendar.

DateEditMonthCalendar Class | C1.Win.C1Input Namespace

DateEditMonthCalendar.ShowClearButton Property
Determines if the Clear button of the drop-down calendar is visible. [Visual Basic] Public Property ShowClearButton As Boolean [C#] public bool ShowClearButton {get;set;} [Delphi] public property ShowClearButton: Boolean read get_ShowClearButton write set_ShowClearButton; See Also DateEditMonthCalendar Class | DateEditMonthCalendar Members | C1.Win.C1Input Namespace

DateEditMonthCalendar.ShowTodayButton Property
Determines if the Today button of the drop-down calendar is visible. [Visual Basic] Public Property ShowTodayButton As Boolean [C#] public bool ShowTodayButton {get;set;} [Delphi] public property ShowTodayButton: Boolean read get_ShowTodayButton write set_ShowTodayButton; See Also DateEditMonthCalendar Class | DateEditMonthCalendar Members | C1.Win.C1Input Namespace

DateEditMonthCalendar.UIStrings Property
The string collection of user interface strings used in the calendar.

DateEditMonthCalendar Events 227

[Visual Basic] Public ReadOnly Property UIStrings As UIStrings [C#] public UIStrings UIStrings {get;} [Delphi] public property UIStrings: UIStrings read get_UIStrings; See Also DateEditMonthCalendar Class | DateEditMonthCalendar Members | C1.Win.C1Input Namespace

DateEditMonthCalendar Events
The events of the DateEditMonthCalendar class are listed here. For a complete list of DateEditMonthCalendar class members, see the DateEditMonthCalendar Members topic. Public Events ClearButtonClick ClearButtonVisibilityChanged DateValueChanged DateValueSelected RightToLeftLayoutChanged (inherited from MonthCalendar) TodayButtonClick TodayButtonVisibilityChanged See Also DateEditMonthCalendar Class | C1.Win.C1Input Namespace Occurs when Clear button is clicked. Occurs when Clear button visibility is changed. Occurs when the value of the Date property is changed. Occurs when the user selects a new value for the Date property. Occurs when the value of the RightToLeftLayout property changes. Occurs when Today button is clicked. Occurs when Today button visibility is changed.

DateEditMonthCalendar.ClearButtonClick Event
Occurs when Clear button is clicked. [Visual Basic] Public Event ClearButtonClick AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler ClearButtonClick [Delphi] public property ClearButtonClick: EventHandler read remove_ClearButtonClick write add_ClearButtonClick; See Also DateEditMonthCalendar Class | DateEditMonthCalendar Members | C1.Win.C1Input Namespace

DateEditMonthCalendar.ClearButtonVisibilityChanged Event
Occurs when Clear button visibility is changed.

228 C1.Win.C1Input Namespace

[Visual Basic] Public Event ClearButtonVisibilityChanged AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler ClearButtonVisibilityChanged [Delphi] public property ClearButtonVisibilityChanged: EventHandler read remove_ClearButtonVisibilityChanged write add_ClearButtonVisibilityChanged; See Also DateEditMonthCalendar Class | DateEditMonthCalendar Members | C1.Win.C1Input Namespace

DateEditMonthCalendar.DateValueChanged Event
Occurs when the value of the Date property is changed. [Visual Basic] Public Event DateValueChanged AsNullableDateTimeEventHandlerNullableDateTimeEventHandler [C#] public eventNullableDateTimeEventHandlerNullableDateTimeEventHandler DateValueChanged [Delphi] public property DateValueChanged: NullableDateTimeEventHandler read remove_DateValueChanged write add_DateValueChanged; See Also DateEditMonthCalendar Class | DateEditMonthCalendar Members | C1.Win.C1Input Namespace

DateEditMonthCalendar.DateValueSelected Event
Occurs when the user selects a new value for the Date property. [Visual Basic] Public Event DateValueSelected AsNullableDateTimeEventHandlerNullableDateTimeEventHandler [C#] public eventNullableDateTimeEventHandlerNullableDateTimeEventHandler DateValueSelected [Delphi] public property DateValueSelected: NullableDateTimeEventHandler read remove_DateValueSelected write add_DateValueSelected; See Also DateEditMonthCalendar Class | DateEditMonthCalendar Members | C1.Win.C1Input Namespace

DateEditMonthCalendar.TodayButtonClick Event 229

DateEditMonthCalendar.TodayButtonClick Event
Occurs when Today button is clicked. [Visual Basic] Public Event TodayButtonClick AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler TodayButtonClick [Delphi] public property TodayButtonClick: EventHandler read remove_TodayButtonClick write add_TodayButtonClick; See Also DateEditMonthCalendar Class | DateEditMonthCalendar Members | C1.Win.C1Input Namespace

DateEditMonthCalendar.TodayButtonVisibilityChanged Event
Occurs when Today button visibility is changed. [Visual Basic] Public Event TodayButtonVisibilityChanged AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler TodayButtonVisibilityChanged [Delphi] public property TodayButtonVisibilityChanged: EventHandler read remove_TodayButtonVisibilityChanged write add_TodayButtonVisibilityChanged; See Also DateEditMonthCalendar Class | DateEditMonthCalendar Members | C1.Win.C1Input Namespace

DropDownCalculator Class
Represents the class of drop-down calculator form. For a list of all members of this type, see DropDownCalculator Members. System.Object System.MarshalByRefObject System.ComponentModel.Component System.Windows.Forms.Control System.Windows.Forms.ScrollableControl System.Windows.Forms.ContainerControl System.Windows.Forms.Form C1.Win.C1Input.DropDownForm C1.Win.C1Input.DropDownCalculator

230 C1.Win.C1Input Namespace

[Visual Basic] Public Class DropDownCalculator Inherits DropDownForm [C#] public class DropDownCalculator : DropDownForm [Delphi] type DropDownCalculator = class Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also DropDownCalculator Members | C1.Win.C1Input Namespace

(DropDownForm);(DropDownForm);

DropDownCalculator Members
DropDownCalculator overview Public Properties AcceptButton (inherited from Form) ActiveMdiChild (inherited from Form) AllowTransparency (inherited from Form) AutoSizeMode (inherited from Form) CancelButton (inherited from Form) The accept button of the form. If this is set, the button is clicked whenever the user presses the ENTER key. The currently active MDI child form. Indicates whether the opacity of the control can be adjusted. Specifies the mode by which the user interface element automatically resizes itself. The cancel button of the form. If this property is set, the button is 'clicked' whenever the user presses the ESC key. The bounds of this form in desktop coordinates. The location of this form in desktop coordinates. The value this form will return if displayed as a dialog box. Determines whether the form is a child of a MDI container. Specifies the primary MenuStrip for the Form. This property is used for keyboard activation and automatic merging in MDI. The maximum size the form can be resized to. Retrieves the MDI children of this form. Retrieves the MDI parent of this form. The main menu of the form. This must be set to a component of type MainMenu. The merged menu of this form, which is used when displaying a single merged MDI menu.

DesktopBounds (inherited from Form) DesktopLocation (inherited from Form) DialogResult (inherited from Form) IsMdiChild (inherited from Form) MainMenuStrip (inherited from Form)

MaximumSize (inherited from Form) MdiChildren (inherited from Form) MdiParent (inherited from Form) Menu (inherited from Form) MergedMenu (inherited from Form)

DropDownCalculator Members 231

MinimumSize (inherited from Form) Modal (inherited from Form) Opacity (inherited from Form) OwnedForms (inherited from Form) Owner (inherited from Form) RightToLeftLayout (inherited from Form) ShowIcon (inherited from Form) TopMost (inherited from Form) TransparencyKey (inherited from Form) Public Events Activated (inherited from Form) AutoSizeChanged (inherited from Form) Deactivate (inherited from Form) FormClosed (inherited from Form) FormClosing (inherited from Form) HelpButtonClicked (inherited from Form) InputLanguageChanged (inherited from Form) InputLanguageChanging (inherited from Form) Load (inherited from Form) MaximizedBoundsChanged (inherited from Form) MaximumSizeChanged (inherited from Form) MdiChildActivate (inherited from Form) MenuComplete (inherited from Form) MenuStart (inherited from Form) MinimumSizeChanged (inherited from Form) ResizeBegin (inherited from Form) ResizeEnd (inherited from Form)

The minimum size the form can be resized to. Indicates if this form is currently being displayed as a modal dialog box. The opacity percentage of the control. Array of forms owned by this form. The owner of this form. Indicates whether the control layout is right-to-left when the RightToLeft property is set to Yes. Indicates whether an icon is displayed in the title bar of the form. Indicates whether the form always appears above all other forms that do not have this property set to True. A color which will appear transparent when painted on the form. Occurs whenever the form is activated. Occurs when the AutoSize property has changed. Occurs whenever the form is deactivated. Occurs whenever the user closes the form, after the form has been closed and specifies the close reason. Occurs whenever the user closes the form, before the form has been closed and specifies the close reason. Event raised when the help button is clicked. Occurs whenever the language used for input for this form changes. A request by the system to change the input language for this form. This request can be refused. Occurs whenever the user loads the form. Event raised when the value of the MaximizedBounds property is changed on Form. Event raised when the value of the MaximumSize property is changed on Form. Occurs when an MDI Child window is activated. Occurs when menu selection is completed and menu modal message loop has exited. Occurs when any menu is displayed and menu modal message loop is entered. Event raised when the value of the MinimumSize property is changed on Form. Occurs when the form enters the sizing modal loop. Occurs when the control exits the sizing modal loop.

232 C1.Win.C1Input Namespace

RightToLeftLayoutChanged (inherited from Form) Shown (inherited from Form) See Also

Occurs when the value of the RightToLeftLayout property changes. Occurs whenever the form is first shown.

DropDownCalculator Class | C1.Win.C1Input Namespace

DropDownCalculator Properties
The properties of the DropDownCalculator class are listed here. For a complete list of DropDownCalculator class members, see the DropDownCalculator Members topic. Public Properties AcceptButton (inherited from Form) ActiveMdiChild (inherited from Form) AllowTransparency (inherited from Form) AutoSizeMode (inherited from Form) CancelButton (inherited from Form) The accept button of the form. If this is set, the button is clicked whenever the user presses the ENTER key. The currently active MDI child form. Indicates whether the opacity of the control can be adjusted. Specifies the mode by which the user interface element automatically resizes itself. The cancel button of the form. If this property is set, the button is 'clicked' whenever the user presses the ESC key. The bounds of this form in desktop coordinates. The location of this form in desktop coordinates. The value this form will return if displayed as a dialog box. Determines whether the form is a child of a MDI container. Specifies the primary MenuStrip for the Form. This property is used for keyboard activation and automatic merging in MDI. The maximum size the form can be resized to. Retrieves the MDI children of this form. Retrieves the MDI parent of this form. The main menu of the form. This must be set to a component of type MainMenu. The merged menu of this form, which is used when displaying a single merged MDI menu. The minimum size the form can be resized to. Indicates if this form is currently being displayed as a modal dialog box. The opacity percentage of the control. Array of forms owned by this form.

DesktopBounds (inherited from Form) DesktopLocation (inherited from Form) DialogResult (inherited from Form) IsMdiChild (inherited from Form) MainMenuStrip (inherited from Form)

MaximumSize (inherited from Form) MdiChildren (inherited from Form) MdiParent (inherited from Form) Menu (inherited from Form) MergedMenu (inherited from Form) MinimumSize (inherited from Form) Modal (inherited from Form) Opacity (inherited from Form) OwnedForms (inherited from Form)

DropDownCalculator Events 233

Owner (inherited from Form) RightToLeftLayout (inherited from Form) ShowIcon (inherited from Form) TopMost (inherited from Form) TransparencyKey (inherited from Form) See Also

The owner of this form. Indicates whether the control layout is right-to-left when the RightToLeft property is set to Yes. Indicates whether an icon is displayed in the title bar of the form. Indicates whether the form always appears above all other forms that do not have this property set to True. A color which will appear transparent when painted on the form.

DropDownCalculator Class | C1.Win.C1Input Namespace

DropDownCalculator Events
The events of the DropDownCalculator class are listed here. For a complete list of DropDownCalculator class members, see the DropDownCalculator Members topic. Public Events Activated (inherited from Form) AutoSizeChanged (inherited from Form) Deactivate (inherited from Form) FormClosed (inherited from Form) FormClosing (inherited from Form) HelpButtonClicked (inherited from Form) InputLanguageChanged (inherited from Form) InputLanguageChanging (inherited from Form) Load (inherited from Form) MaximizedBoundsChanged (inherited from Form) MaximumSizeChanged (inherited from Form) MdiChildActivate (inherited from Form) MenuComplete (inherited from Form) MenuStart (inherited from Form) MinimumSizeChanged (inherited from Form) ResizeBegin (inherited from Form) Occurs whenever the form is activated. Occurs when the AutoSize property has changed. Occurs whenever the form is deactivated. Occurs whenever the user closes the form, after the form has been closed and specifies the close reason. Occurs whenever the user closes the form, before the form has been closed and specifies the close reason. Event raised when the help button is clicked. Occurs whenever the language used for input for this form changes. A request by the system to change the input language for this form. This request can be refused. Occurs whenever the user loads the form. Event raised when the value of the MaximizedBounds property is changed on Form. Event raised when the value of the MaximumSize property is changed on Form. Occurs when an MDI Child window is activated. Occurs when menu selection is completed and menu modal message loop has exited. Occurs when any menu is displayed and menu modal message loop is entered. Event raised when the value of the MinimumSize property is changed on Form. Occurs when the form enters the sizing modal loop.

234 C1.Win.C1Input Namespace

ResizeEnd (inherited from Form) RightToLeftLayoutChanged (inherited from Form) Shown (inherited from Form) See Also

Occurs when the control exits the sizing modal loop. Occurs when the value of the RightToLeftLayout property changes. Occurs whenever the form is first shown.

DropDownCalculator Class | C1.Win.C1Input Namespace

DropDownCalendar Class
The drop-down calendar form. For a list of all members of this type, see DropDownCalendar Members. System.Object System.MarshalByRefObject System.ComponentModel.Component System.Windows.Forms.Control System.Windows.Forms.ScrollableControl System.Windows.Forms.ContainerControl System.Windows.Forms.Form C1.Win.C1Input.DropDownForm C1.Win.C1Input.DropDownCalendar [Visual Basic] Public Class DropDownCalendar Inherits DropDownForm [C#] public class DropDownCalendar : DropDownForm [Delphi] type DropDownCalendar = class (DropDownForm);(DropDownForm); Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also DropDownCalendar Members | C1.Win.C1Input Namespace

DropDownCalendar Members
DropDownCalendar overview Public Properties AcceptButton (inherited from Form) ActiveMdiChild (inherited from Form) The accept button of the form. If this is set, the button is clicked whenever the user presses the ENTER key. The currently active MDI child form.

DropDownCalendar Members 235

AllowTransparency (inherited from Form) AutoSizeMode (inherited from Form) CancelButton (inherited from Form)

Indicates whether the opacity of the control can be adjusted. Specifies the mode by which the user interface element automatically resizes itself. The cancel button of the form. If this property is set, the button is 'clicked' whenever the user presses the ESC key. The bounds of this form in desktop coordinates. The location of this form in desktop coordinates. The value this form will return if displayed as a dialog box. Determines whether the form is a child of a MDI container. Specifies the primary MenuStrip for the Form. This property is used for keyboard activation and automatic merging in MDI. The maximum size the form can be resized to. Retrieves the MDI children of this form. Retrieves the MDI parent of this form. The main menu of the form. This must be set to a component of type MainMenu. The merged menu of this form, which is used when displaying a single merged MDI menu. The minimum size the form can be resized to. Indicates if this form is currently being displayed as a modal dialog box. The opacity percentage of the control. Array of forms owned by this form. The owner of this form. Indicates whether the control layout is right-to-left when the RightToLeft property is set to Yes. Indicates whether an icon is displayed in the title bar of the form. Indicates whether the form always appears above all other forms that do not have this property set to True. A color which will appear transparent when painted on the form. Occurs whenever the form is activated. Occurs when the AutoSize property has changed. Occurs whenever the form is deactivated.

DesktopBounds (inherited from Form) DesktopLocation (inherited from Form) DialogResult (inherited from Form) IsMdiChild (inherited from Form) MainMenuStrip (inherited from Form)

MaximumSize (inherited from Form) MdiChildren (inherited from Form) MdiParent (inherited from Form) Menu (inherited from Form) MergedMenu (inherited from Form) MinimumSize (inherited from Form) Modal (inherited from Form) Opacity (inherited from Form) OwnedForms (inherited from Form) Owner (inherited from Form) RightToLeftLayout (inherited from Form) ShowIcon (inherited from Form) TopMost (inherited from Form) TransparencyKey (inherited from Form) Public Events Activated (inherited from Form) AutoSizeChanged (inherited from Form) Deactivate (inherited from Form)

236 C1.Win.C1Input Namespace

FormClosed (inherited from Form) FormClosing (inherited from Form) HelpButtonClicked (inherited from Form) InputLanguageChanged (inherited from Form) InputLanguageChanging (inherited from Form) Load (inherited from Form) MaximizedBoundsChanged (inherited from Form) MaximumSizeChanged (inherited from Form) MdiChildActivate (inherited from Form) MenuComplete (inherited from Form) MenuStart (inherited from Form) MinimumSizeChanged (inherited from Form) ResizeBegin (inherited from Form) ResizeEnd (inherited from Form) RightToLeftLayoutChanged (inherited from Form) Shown (inherited from Form) See Also

Occurs whenever the user closes the form, after the form has been closed and specifies the close reason. Occurs whenever the user closes the form, before the form has been closed and specifies the close reason. Event raised when the help button is clicked. Occurs whenever the language used for input for this form changes. A request by the system to change the input language for this form. This request can be refused. Occurs whenever the user loads the form. Event raised when the value of the MaximizedBounds property is changed on Form. Event raised when the value of the MaximumSize property is changed on Form. Occurs when an MDI Child window is activated. Occurs when menu selection is completed and menu modal message loop has exited. Occurs when any menu is displayed and menu modal message loop is entered. Event raised when the value of the MinimumSize property is changed on Form. Occurs when the form enters the sizing modal loop. Occurs when the control exits the sizing modal loop. Occurs when the value of the RightToLeftLayout property changes. Occurs whenever the form is first shown.

DropDownCalendar Class | C1.Win.C1Input Namespace

DropDownCalendar Properties
The properties of the DropDownCalendar class are listed here. For a complete list of DropDownCalendar class members, see the DropDownCalendar Members topic. Public Properties AcceptButton (inherited from Form) ActiveMdiChild (inherited from Form) AllowTransparency (inherited from Form) AutoSizeMode (inherited from Form) The accept button of the form. If this is set, the button is clicked whenever the user presses the ENTER key. The currently active MDI child form. Indicates whether the opacity of the control can be adjusted. Specifies the mode by which the user interface element automatically resizes itself.

DropDownCalendar Events 237

CancelButton (inherited from Form)

The cancel button of the form. If this property is set, the button is 'clicked' whenever the user presses the ESC key. The bounds of this form in desktop coordinates. The location of this form in desktop coordinates. The value this form will return if displayed as a dialog box. Determines whether the form is a child of a MDI container. Specifies the primary MenuStrip for the Form. This property is used for keyboard activation and automatic merging in MDI. The maximum size the form can be resized to. Retrieves the MDI children of this form. Retrieves the MDI parent of this form. The main menu of the form. This must be set to a component of type MainMenu. The merged menu of this form, which is used when displaying a single merged MDI menu. The minimum size the form can be resized to. Indicates if this form is currently being displayed as a modal dialog box. The opacity percentage of the control. Array of forms owned by this form. The owner of this form. Indicates whether the control layout is right-to-left when the RightToLeft property is set to Yes. Indicates whether an icon is displayed in the title bar of the form. Indicates whether the form always appears above all other forms that do not have this property set to True. A color which will appear transparent when painted on the form.

DesktopBounds (inherited from Form) DesktopLocation (inherited from Form) DialogResult (inherited from Form) IsMdiChild (inherited from Form) MainMenuStrip (inherited from Form)

MaximumSize (inherited from Form) MdiChildren (inherited from Form) MdiParent (inherited from Form) Menu (inherited from Form) MergedMenu (inherited from Form) MinimumSize (inherited from Form) Modal (inherited from Form) Opacity (inherited from Form) OwnedForms (inherited from Form) Owner (inherited from Form) RightToLeftLayout (inherited from Form) ShowIcon (inherited from Form) TopMost (inherited from Form) TransparencyKey (inherited from Form) See Also

DropDownCalendar Class | C1.Win.C1Input Namespace

DropDownCalendar Events
The events of the DropDownCalendar class are listed here. For a complete list of DropDownCalendar class members, see the DropDownCalendar Members topic. Public Events Activated (inherited from Form) Occurs whenever the form is activated.

238 C1.Win.C1Input Namespace

AutoSizeChanged (inherited from Form) Deactivate (inherited from Form) FormClosed (inherited from Form) FormClosing (inherited from Form) HelpButtonClicked (inherited from Form) InputLanguageChanged (inherited from Form) InputLanguageChanging (inherited from Form) Load (inherited from Form) MaximizedBoundsChanged (inherited from Form) MaximumSizeChanged (inherited from Form) MdiChildActivate (inherited from Form) MenuComplete (inherited from Form) MenuStart (inherited from Form) MinimumSizeChanged (inherited from Form) ResizeBegin (inherited from Form) ResizeEnd (inherited from Form) RightToLeftLayoutChanged (inherited from Form) Shown (inherited from Form) See Also

Occurs when the AutoSize property has changed. Occurs whenever the form is deactivated. Occurs whenever the user closes the form, after the form has been closed and specifies the close reason. Occurs whenever the user closes the form, before the form has been closed and specifies the close reason. Event raised when the help button is clicked. Occurs whenever the language used for input for this form changes. A request by the system to change the input language for this form. This request can be refused. Occurs whenever the user loads the form. Event raised when the value of the MaximizedBounds property is changed on Form. Event raised when the value of the MaximumSize property is changed on Form. Occurs when an MDI Child window is activated. Occurs when menu selection is completed and menu modal message loop has exited. Occurs when any menu is displayed and menu modal message loop is entered. Event raised when the value of the MinimumSize property is changed on Form. Occurs when the form enters the sizing modal loop. Occurs when the control exits the sizing modal loop. Occurs when the value of the RightToLeftLayout property changes. Occurs whenever the form is first shown.

DropDownCalendar Class | C1.Win.C1Input Namespace

DropDownForm Class
Base class for custom drop-down forms. For a list of all members of this type, see DropDownForm Members. System.Object System.MarshalByRefObject System.ComponentModel.Component System.Windows.Forms.Control System.Windows.Forms.ScrollableControl System.Windows.Forms.ContainerControl

DropDownForm Members 239

System.Windows.Forms.Form C1.Win.C1Input.DropDownForm C1.Win.C1Input.DropDownCalculator C1.Win.C1Input.DropDownCalendar [Visual Basic] Public Class DropDownForm InheritsFormForm ImplementsIMessageFilterIMessageFilter [C#] public class DropDownForm :FormForm ,IMessageFilterIMessageFilter [Delphi] type DropDownForm = class (FormForm,(FormForm,IMessageFilterIMessageFilter); Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also DropDownForm Members | C1.Win.C1Input Namespace

DropDownForm Members
DropDownForm overview Public Properties AcceptButton (inherited from Form) ActiveMdiChild (inherited from Form) AllowTransparency (inherited from Form) AutoSizeMode (inherited from Form) BorderStyle CancelButton (inherited from Form) The accept button of the form. If this is set, the button is clicked whenever the user presses the ENTER key. The currently active MDI child form. Indicates whether the opacity of the control can be adjusted. Specifies the mode by which the user interface element automatically resizes itself. Determines the style of the control's border. The cancel button of the form. If this property is set, the button is 'clicked' whenever the user presses the ESC key. The bounds of this form in desktop coordinates. The location of this form in desktop coordinates. The value this form will return if displayed as a dialog box. Alignment of the drop-down form relative to the owner control. Determines the control on the form that gets input focus when the form is shown.

DesktopBounds (inherited from Form) DesktopLocation (inherited from Form) DialogResult (inherited from Form) DropDownAlign FocusControl

240 C1.Win.C1Input Namespace

IsMdiChild (inherited from Form) MainMenuStrip (inherited from Form)

Determines whether the form is a child of a MDI container. Specifies the primary MenuStrip for the Form. This property is used for keyboard activation and automatic merging in MDI. The maximum size the form can be resized to. Retrieves the MDI children of this form. Retrieves the MDI parent of this form. The main menu of the form. This must be set to a component of type MainMenu. The merged menu of this form, which is used when displaying a single merged MDI menu. The minimum size the form can be resized to. Indicates if this form is currently being displayed as a modal dialog box. The opacity percentage of the control. Determine various behavioral options of the drop-down form. Array of forms owned by this form. The owner of this form. Indicates whether the control layout is right-to-left when the RightToLeft property is set to Yes. Indicates whether an icon is displayed in the title bar of the form. Indicates whether the form always appears above all other forms that do not have this property set to True. A color which will appear transparent when painted on the form. Overloaded. Closes the drop-down form. Occurs whenever the form is activated. Occurs when the AutoSize property has changed. Occurs when changes made by drop-down form are cancelled. Occurs whenever the form is deactivated. Occurs whenever the user closes the form, after the form has been closed and specifies the close reason. Occurs whenever the user closes the form, before the form has been closed and specifies the close reason. Event raised when the help button is clicked.

MaximumSize (inherited from Form) MdiChildren (inherited from Form) MdiParent (inherited from Form) Menu (inherited from Form) MergedMenu (inherited from Form) MinimumSize (inherited from Form) Modal (inherited from Form) Opacity (inherited from Form) Options OwnedForms (inherited from Form) Owner (inherited from Form) RightToLeftLayout (inherited from Form) ShowIcon (inherited from Form) TopMost (inherited from Form) TransparencyKey (inherited from Form) Public Methods CloseDropDown Public Events Activated (inherited from Form) AutoSizeChanged (inherited from Form) CancelChanges Deactivate (inherited from Form) FormClosed (inherited from Form) FormClosing (inherited from Form) HelpButtonClicked (inherited from Form)

DropDownForm Properties 241

InputLanguageChanged (inherited from Form) InputLanguageChanging (inherited from Form) Load (inherited from Form) MaximizedBoundsChanged (inherited from Form) MaximumSizeChanged (inherited from Form) MdiChildActivate (inherited from Form) MenuComplete (inherited from Form) MenuStart (inherited from Form) MinimumSizeChanged (inherited from Form) Open OwnerControlTextChanged OwnerControlValueChanged PostChanges ResizeBegin (inherited from Form) ResizeEnd (inherited from Form) RightToLeftLayoutChanged (inherited from Form) Shown (inherited from Form) See Also

Occurs whenever the language used for input for this form changes. A request by the system to change the input language for this form. This request can be refused. Occurs whenever the user loads the form. Event raised when the value of the MaximizedBounds property is changed on Form. Event raised when the value of the MaximumSize property is changed on Form. Occurs when an MDI Child window is activated. Occurs when menu selection is completed and menu modal message loop has exited. Occurs when any menu is displayed and menu modal message loop is entered. Event raised when the value of the MinimumSize property is changed on Form. Occurs when drop-down form is opened. Occurs when OwnerControl.Text property is changed. Occurs when OwnerControl.Value property is changed. Occurs when Value property of the OwnerControl is updated. Occurs when the form enters the sizing modal loop. Occurs when the control exits the sizing modal loop. Occurs when the value of the RightToLeftLayout property changes. Occurs whenever the form is first shown.

DropDownForm Class | C1.Win.C1Input Namespace

DropDownForm Properties
The properties of the DropDownForm class are listed here. For a complete list of DropDownForm class members, see the DropDownForm Members topic. Public Properties AcceptButton (inherited from Form) ActiveMdiChild (inherited from Form) AllowTransparency (inherited from Form) AutoSizeMode (inherited from Form) BorderStyle The accept button of the form. If this is set, the button is clicked whenever the user presses the ENTER key. The currently active MDI child form. Indicates whether the opacity of the control can be adjusted. Specifies the mode by which the user interface element automatically resizes itself. Determines the style of the control's border.

242 C1.Win.C1Input Namespace

CancelButton (inherited from Form)

The cancel button of the form. If this property is set, the button is 'clicked' whenever the user presses the ESC key. The bounds of this form in desktop coordinates. The location of this form in desktop coordinates. The value this form will return if displayed as a dialog box. Alignment of the drop-down form relative to the owner control. Determines the control on the form that gets input focus when the form is shown. Determines whether the form is a child of a MDI container. Specifies the primary MenuStrip for the Form. This property is used for keyboard activation and automatic merging in MDI. The maximum size the form can be resized to. Retrieves the MDI children of this form. Retrieves the MDI parent of this form. The main menu of the form. This must be set to a component of type MainMenu. The merged menu of this form, which is used when displaying a single merged MDI menu. The minimum size the form can be resized to. Indicates if this form is currently being displayed as a modal dialog box. The opacity percentage of the control. Determine various behavioral options of the drop-down form. Array of forms owned by this form. The owner of this form. Indicates whether the control layout is right-to-left when the RightToLeft property is set to Yes. Indicates whether an icon is displayed in the title bar of the form. Indicates whether the form always appears above all other forms that do not have this property set to True. A color which will appear transparent when painted on the form.

DesktopBounds (inherited from Form) DesktopLocation (inherited from Form) DialogResult (inherited from Form) DropDownAlign FocusControl IsMdiChild (inherited from Form) MainMenuStrip (inherited from Form)

MaximumSize (inherited from Form) MdiChildren (inherited from Form) MdiParent (inherited from Form) Menu (inherited from Form) MergedMenu (inherited from Form) MinimumSize (inherited from Form) Modal (inherited from Form) Opacity (inherited from Form) Options OwnedForms (inherited from Form) Owner (inherited from Form) RightToLeftLayout (inherited from Form) ShowIcon (inherited from Form) TopMost (inherited from Form) TransparencyKey (inherited from Form) See Also

DropDownForm Class | C1.Win.C1Input Namespace

DropDownForm.BorderStyle Property 243

DropDownForm.BorderStyle Property
Determines the style of the control's border. [Visual Basic] Public Property BorderStyle As BorderStyle [C#] public BorderStyle BorderStyle {get;set;} [Delphi] public property BorderStyle: BorderStyle read get_BorderStyle write set_BorderStyle; See Also DropDownForm Class | DropDownForm Members | C1.Win.C1Input Namespace

DropDownForm.DropDownAlign Property
Alignment of the drop-down form relative to the owner control. [Visual Basic] Public Property DropDownAlign As DropDownFormAlignmentEnum [C#] public DropDownFormAlignmentEnum DropDownAlign {get;set;} [Delphi] public property DropDownAlign: DropDownFormAlignmentEnum read get_DropDownAlign write set_DropDownAlign; See Also DropDownForm Class | DropDownForm Members | C1.Win.C1Input Namespace

DropDownForm.FocusControl Property
Determines the control on the form that gets input focus when the form is shown. [Visual Basic] Public Property FocusControl As Control [C#] public Control FocusControl {get;set;} [Delphi] public property FocusControl: Control read get_FocusControl write set_FocusControl; See Also DropDownForm Class | DropDownForm Members | C1.Win.C1Input Namespace

DropDownForm.Options Property
Determine various behavioral options of the drop-down form.

244 C1.Win.C1Input Namespace

[Visual Basic] Public Property Options As DropDownFormOptionsFlags [C#] public DropDownFormOptionsFlags Options {get;set;} [Delphi] public property Options: DropDownFormOptionsFlags read get_Options write set_Options; See Also DropDownForm Class | DropDownForm Members | C1.Win.C1Input Namespace

DropDownForm Methods
The methods of the DropDownForm class are listed here. For a complete list of DropDownForm class members, see the DropDownForm Members topic. Public Methods CloseDropDown See Also DropDownForm Class | C1.Win.C1Input Namespace Overloaded. Closes the drop-down form.

DropDownForm.CloseDropDown Method
Closes the drop-down form. [Visual Basic] Public Sub CloseDropDown() [C#] public void CloseDropDown() [Delphi] public procedure CloseDropDown(); overload; See Also DropDownForm Class | DropDownForm Members | C1.Win.C1Input Namespace

DropDownForm Events
The events of the DropDownForm class are listed here. For a complete list of DropDownForm class members, see the DropDownForm Members topic. Public Events Activated (inherited from Form) AutoSizeChanged (inherited from Form) CancelChanges Deactivate (inherited from Form) Occurs whenever the form is activated. Occurs when the AutoSize property has changed. Occurs when changes made by drop-down form are cancelled. Occurs whenever the form is deactivated.

DropDownForm.CancelChanges Event 245

FormClosed (inherited from Form) FormClosing (inherited from Form) HelpButtonClicked (inherited from Form) InputLanguageChanged (inherited from Form) InputLanguageChanging (inherited from Form) Load (inherited from Form) MaximizedBoundsChanged (inherited from Form) MaximumSizeChanged (inherited from Form) MdiChildActivate (inherited from Form) MenuComplete (inherited from Form) MenuStart (inherited from Form) MinimumSizeChanged (inherited from Form) Open OwnerControlTextChanged OwnerControlValueChanged PostChanges ResizeBegin (inherited from Form) ResizeEnd (inherited from Form) RightToLeftLayoutChanged (inherited from Form) Shown (inherited from Form) See Also

Occurs whenever the user closes the form, after the form has been closed and specifies the close reason. Occurs whenever the user closes the form, before the form has been closed and specifies the close reason. Event raised when the help button is clicked. Occurs whenever the language used for input for this form changes. A request by the system to change the input language for this form. This request can be refused. Occurs whenever the user loads the form. Event raised when the value of the MaximizedBounds property is changed on Form. Event raised when the value of the MaximumSize property is changed on Form. Occurs when an MDI Child window is activated. Occurs when menu selection is completed and menu modal message loop has exited. Occurs when any menu is displayed and menu modal message loop is entered. Event raised when the value of the MinimumSize property is changed on Form. Occurs when drop-down form is opened. Occurs when OwnerControl.Text property is changed. Occurs when OwnerControl.Value property is changed. Occurs when Value property of the OwnerControl is updated. Occurs when the form enters the sizing modal loop. Occurs when the control exits the sizing modal loop. Occurs when the value of the RightToLeftLayout property changes. Occurs whenever the form is first shown.

DropDownForm Class | C1.Win.C1Input Namespace

DropDownForm.CancelChanges Event
Occurs when changes made by drop-down form are cancelled. [Visual Basic] Public Event CancelChanges AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler CancelChanges

246 C1.Win.C1Input Namespace

[Delphi] public property CancelChanges: EventHandler read remove_CancelChanges write add_CancelChanges; See Also DropDownForm Class | DropDownForm Members | C1.Win.C1Input Namespace

DropDownForm.Open Event
Occurs when drop-down form is opened. [Visual Basic] Public Event Open AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler Open [Delphi] public property Open: EventHandler read remove_Open write add_Open; See Also DropDownForm Class | DropDownForm Members | C1.Win.C1Input Namespace

DropDownForm.OwnerControlTextChanged Event
Occurs when OwnerControl.Text property is changed. [Visual Basic] Public Event OwnerControlTextChanged AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler OwnerControlTextChanged [Delphi] public property OwnerControlTextChanged: EventHandler read remove_OwnerControlTextChanged write add_OwnerControlTextChanged; See Also DropDownForm Class | DropDownForm Members | C1.Win.C1Input Namespace

DropDownForm.OwnerControlValueChanged Event
Occurs when OwnerControl.Value property is changed. [Visual Basic] Public Event OwnerControlValueChanged AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler OwnerControlValueChanged [Delphi] public property OwnerControlValueChanged: EventHandler read remove_OwnerControlValueChanged write add_OwnerControlValueChanged;

DropDownForm.PostChanges Event 247

See Also DropDownForm Class | DropDownForm Members | C1.Win.C1Input Namespace

DropDownForm.PostChanges Event
Occurs when Value property of the OwnerControl is updated. [Visual Basic] Public Event PostChanges AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler PostChanges [Delphi] public property PostChanges: EventHandler read remove_PostChanges write add_PostChanges; Example The following code provides an example of the PostChanges event: Visual Basic Private Sub DropDownForm1_PostChanges(sender As Object, e As System.EventArgs) If (MyBase.DialogResult = DialogResult.OK) Then Dim control1 As Control For Each control1 In MyBase.Controls If (TypeOf control1 is RadioButton AndAlso CType(control1, RadioButton).Checked) Then MyBase.OwnerControl.Value = CType(control1, RadioButton).Text End If Next End If End Sub C# private void DropDownForm1_PostChanges(object sender, System.EventArgs e) { if (DialogResult == DialogResult.OK) { foreach (Control control1 in Controls) { if (control1 as RadioButton != null && ((RadioButton)control1).Checked) { OwnerControl.Value = ((RadioButton)control1).Text; } } } } Delphi procedure DropDownForm1_PostChanges(sender: Tobject; e: EventArgs); var control1: Control; begin if (inherited DialogResult = DialogResult.OK) then

248 C1.Win.C1Input Namespace

for control1 in inherited Controls do begin if ((control1 is RadioButton) and (control1 as RadioButton).Checked) then inherited OwnerControl.Value := (control1 as RadioButton).Text end; end; See Also DropDownForm Class | DropDownForm Members | C1.Win.C1Input Namespace

ErrorInfo Class
Settings affecting error handling. For a list of all members of this type, see ErrorInfo Members. System.Object C1.Win.C1Input.ErrorInfo [Visual Basic] Public Class ErrorInfo [C#] public class ErrorInfo [Delphi] type ErrorInfo = class; Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also ErrorInfo Members | C1.Win.C1Input Namespace

ErrorInfo Members
ErrorInfo overview Public Properties BeepOnError CanLoseFocus ErrorAction ErrorMessage ErrorMessageCaption ErrorProvider If True, the control beeps signaling an error. Determines whether or not the control is allowed to lose focus after the error. Enumerated value that determines what action is performed on the control value when an error occurs. Error message shown in the standard message box and/or in the exception. The text to display in the title bar of the error message box. Gets or sets an ErrorProvider object used to indicate error state of the control.

ErrorInfo Properties 249

ShowErrorMessage ValueOnError ValueOnErrorIsDbNull Public Methods Reset See Also ErrorInfo Class | C1.Win.C1Input Namespace

If True (default), the standard error message is shown. Value used to reset the control if ErrorAction = SetValueOnError. Boolean property used to set ValueOnError to DbNull (only necessary at design time). Resets whole ErrorInfo property in base control

ErrorInfo Properties
The properties of the ErrorInfo class are listed here. For a complete list of ErrorInfo class members, see the ErrorInfo Members topic. Public Properties BeepOnError CanLoseFocus ErrorAction ErrorMessage ErrorMessageCaption ErrorProvider ShowErrorMessage ValueOnError ValueOnErrorIsDbNull See Also ErrorInfo Class | C1.Win.C1Input Namespace If True, the control beeps signaling an error. Determines whether or not the control is allowed to lose focus after the error. Enumerated value that determines what action is performed on the control value when an error occurs. Error message shown in the standard message box and/or in the exception. The text to display in the title bar of the error message box. Gets or sets an ErrorProvider object used to indicate error state of the control. If True (default), the standard error message is shown. Value used to reset the control if ErrorAction = SetValueOnError. Boolean property used to set ValueOnError to DbNull (only necessary at design time).

ErrorInfo.BeepOnError Property
If True, the control beeps signaling an error. [Visual Basic] Public Property BeepOnError As Boolean [C#] public bool BeepOnError {get;set;}

250 C1.Win.C1Input Namespace

[Delphi] public property BeepOnError: Boolean read get_BeepOnError write set_BeepOnError; Remarks The default is False. See Also ErrorInfo Class | ErrorInfo Members | C1.Win.C1Input Namespace

ErrorInfo.CanLoseFocus Property
Determines whether or not the control is allowed to lose focus after the error. [Visual Basic] Public Property CanLoseFocus As Boolean [C#] public bool CanLoseFocus {get;set;} [Delphi] public property CanLoseFocus: Boolean read get_CanLoseFocus write set_CanLoseFocus; See Also ErrorInfo Class | ErrorInfo Members | C1.Win.C1Input Namespace

ErrorInfo.ErrorAction Property
Enumerated value that determines what action is performed on the control value when an error occurs. [Visual Basic] Public Property ErrorAction As ErrorActionEnum [C#] public ErrorActionEnum ErrorAction {get;set;} [Delphi] public property ErrorAction: ErrorActionEnum read get_ErrorAction write set_ErrorAction; See Also ErrorInfo Class | ErrorInfo Members | C1.Win.C1Input Namespace

ErrorInfo.ErrorMessage Property
Error message shown in the standard message box and/or in the exception. [Visual Basic] Public Property ErrorMessage As String [C#] public string ErrorMessage {get;set;}

ErrorInfo.ErrorMessageCaption Property 251

[Delphi] public property ErrorMessage: String read get_ErrorMessage write set_ErrorMessage; See Also ErrorInfo Class | ErrorInfo Members | C1.Win.C1Input Namespace

ErrorInfo.ErrorMessageCaption Property
The text to display in the title bar of the error message box. [Visual Basic] Public Property ErrorMessageCaption As String [C#] public string ErrorMessageCaption {get;set;} [Delphi] public property ErrorMessageCaption: String read get_ErrorMessageCaption write set_ErrorMessageCaption; See Also ErrorInfo Class | ErrorInfo Members | C1.Win.C1Input Namespace

ErrorInfo.ErrorProvider Property
Gets or sets an ErrorProvider object used to indicate error state of the control. [Visual Basic] Public Property ErrorProvider As ErrorProvider [C#] public ErrorProvider ErrorProvider {get;set;} [Delphi] public property ErrorProvider: ErrorProvider read get_ErrorProvider write set_ErrorProvider; See Also ErrorInfo Class | ErrorInfo Members | C1.Win.C1Input Namespace

ErrorInfo.ShowErrorMessage Property
If True (default), the standard error message is shown. [Visual Basic] Public Property ShowErrorMessage As Boolean [C#] public bool ShowErrorMessage {get;set;} [Delphi] public property ShowErrorMessage: Boolean read get_ShowErrorMessage write set_ShowErrorMessage;

252 C1.Win.C1Input Namespace

See Also ErrorInfo Class | ErrorInfo Members | C1.Win.C1Input Namespace

ErrorInfo.ValueOnError Property
Value used to reset the control if ErrorAction = SetValueOnError. [Visual Basic] Public Property ValueOnError As Object [C#] public object ValueOnError {get;set;} [Delphi] public property ValueOnError: Object read get_ValueOnError write set_ValueOnError; See Also ErrorInfo Class | ErrorInfo Members | C1.Win.C1Input Namespace

ErrorInfo.ValueOnErrorIsDbNull Property
Boolean property used to set ValueOnError to DbNull (only necessary at design time). [Visual Basic] Public Property ValueOnErrorIsDbNull As Boolean [C#] public bool ValueOnErrorIsDbNull {get;set;} [Delphi] public property ValueOnErrorIsDbNull: Boolean read get_ValueOnErrorIsDbNull write set_ValueOnErrorIsDbNull; See Also ErrorInfo Class | ErrorInfo Members | C1.Win.C1Input Namespace

ErrorInfo Methods
The methods of the ErrorInfo class are listed here. For a complete list of ErrorInfo class members, see the ErrorInfo Members topic. Public Methods Reset See Also ErrorInfo Class | C1.Win.C1Input Namespace Resets whole ErrorInfo property in base control

ErrorInfo.Reset Method
Resets whole ErrorInfo property in base control [Visual Basic] Public Sub Reset()

FormatInfo Class 253

[C#] public void Reset() [Delphi] public procedure Reset(); See Also ErrorInfo Class | ErrorInfo Members | C1.Win.C1Input Namespace

FormatInfo Class
Settings for data formatting, converting data to string. For a list of all members of this type, see FormatInfo Members. System.Object System.MarshalByRefObject C1.Win.C1Input.FormatInfo [Visual Basic] Public Class FormatInfo InheritsMarshalByRefObjectMarshalByRefObject ImplementsIDisposableIDisposable [C#] public class FormatInfo :MarshalByRefObjectMarshalByRefObject ,IDisposableIDisposable [Delphi] type FormatInfo = class (MarshalByRefObjectMarshalByRefObject,(MarshalByRefObjectMarshalByRefObjec t,IDisposableIDisposable); Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also FormatInfo Members | C1.Win.C1Input Namespace

FormatInfo Members
FormatInfo overview Public Properties CustomFormat EmptyAsNull FormatType Custom format specifier used if FormatType = FormatTypeEnum.CustomFormat. If True, empty strings are interpreted as null values (DbNull). Enumeration value determining the formatting method, including standard .NET format specifiers, custom and programmatic formatting.

254 C1.Win.C1Input Namespace

Inherit NullText TrimEnd TrimStart Public Methods Format Reset See Also FormatInfo Class | C1.Win.C1Input Namespace

Manages inheritance of the FormatInfo properties from the host control properties. String representing a DbNull value. If True, trailing spaces are removed. If True, leading spaces are removed. Overloaded. Formats a value, converts it to a string. Resets whole FormatInfo property of base control

FormatInfo Properties
The properties of the FormatInfo class are listed here. For a complete list of FormatInfo class members, see the FormatInfo Members topic. Public Properties CustomFormat EmptyAsNull FormatType Custom format specifier used if FormatType = FormatTypeEnum.CustomFormat. If True, empty strings are interpreted as null values (DbNull). Enumeration value determining the formatting method, including standard .NET format specifiers, custom and programmatic formatting. Manages inheritance of the FormatInfo properties from the host control properties. String representing a DbNull value. If True, trailing spaces are removed. If True, leading spaces are removed.

Inherit NullText TrimEnd TrimStart See Also FormatInfo Class | C1.Win.C1Input Namespace

FormatInfo.CustomFormat Property
Custom format specifier used if FormatType = FormatTypeEnum.CustomFormat. [Visual Basic] Public Property CustomFormat As String [C#] public string CustomFormat {get;set;} [Delphi] public property CustomFormat: String read get_CustomFormat write set_CustomFormat;

FormatInfo.EmptyAsNull Property 255

See Also FormatInfo Class | FormatInfo Members | C1.Win.C1Input Namespace

FormatInfo.EmptyAsNull Property
If True, empty strings are interpreted as null values (DbNull). [Visual Basic] Public Property EmptyAsNull As Boolean [C#] public bool EmptyAsNull {get;set;} [Delphi] public property EmptyAsNull: Boolean read get_EmptyAsNull write set_EmptyAsNull; See Also FormatInfo Class | FormatInfo Members | C1.Win.C1Input Namespace

FormatInfo.FormatType Property
Enumeration value determining the formatting method, including standard .NET format specifiers, custom and programmatic formatting. [Visual Basic] Public Property FormatType As FormatTypeEnum [C#] public FormatTypeEnum FormatType {get;set;} [Delphi] public property FormatType: FormatTypeEnum read get_FormatType write set_FormatType; See Also FormatInfo Class | FormatInfo Members | C1.Win.C1Input Namespace

FormatInfo.Inherit Property
Manages inheritance of the FormatInfo properties from the host control properties. [Visual Basic] Public Property Inherit As FormatInfoInheritFlags [C#] public FormatInfoInheritFlags Inherit {get;set;} [Delphi] public property Inherit: FormatInfoInheritFlags read get_Inherit write set_Inherit; See Also FormatInfo Class | FormatInfo Members | C1.Win.C1Input Namespace

256 C1.Win.C1Input Namespace

FormatInfo.NullText Property
String representing a DbNull value. [Visual Basic] Public Property NullText As String [C#] public string NullText {get;set;} [Delphi] public property NullText: String read get_NullText write set_NullText; See Also FormatInfo Class | FormatInfo Members | C1.Win.C1Input Namespace

FormatInfo.TrimEnd Property
If True, trailing spaces are removed. [Visual Basic] Public Property TrimEnd As Boolean [C#] public bool TrimEnd {get;set;} [Delphi] public property TrimEnd: Boolean read get_TrimEnd write set_TrimEnd; See Also FormatInfo Class | FormatInfo Members | C1.Win.C1Input Namespace

FormatInfo.TrimStart Property
If True, leading spaces are removed. [Visual Basic] Public Property TrimStart As Boolean [C#] public bool TrimStart {get;set;} [Delphi] public property TrimStart: Boolean read get_TrimStart write set_TrimStart; See Also FormatInfo Class | FormatInfo Members | C1.Win.C1Input Namespace

FormatInfo Methods
The methods of the FormatInfo class are listed here. For a complete list of FormatInfo class members, see the FormatInfo Members topic.

FormatInfo.Format Method 257

Public Methods Format Reset See Also FormatInfo Class | C1.Win.C1Input Namespace Overloaded. Formats a value, converts it to a string. Resets whole FormatInfo property of base control

FormatInfo.Format Method
Formats a value, converts it to a string. [Visual Basic] Public Function Format( _ ByVal value As Object _ ) As String [C#] public string Format( object value ); [Delphi] public function Format( value: Object ): String; overload; Parameters value Typed value to convert to a string. See Also FormatInfo Class | FormatInfo Members | C1.Win.C1Input Namespace

FormatInfo.Reset Method
Resets whole FormatInfo property of base control [Visual Basic] Public Sub Reset() [C#] public void Reset() [Delphi] public procedure Reset(); See Also FormatInfo Class | FormatInfo Members | C1.Win.C1Input Namespace

HighlightingToolBar Class
This class is for internal use only.

258 C1.Win.C1Input Namespace

For a list of all members of this type, see HighlightingToolBar Members. System.Object System.MarshalByRefObject System.ComponentModel.Component System.Windows.Forms.Control System.Windows.Forms.ToolBar C1.Win.C1Input.HighlightingToolBar [Visual Basic] Public Class HighlightingToolBar InheritsToolBarToolBar [C#] public class HighlightingToolBar :ToolBarToolBar [Delphi] type HighlightingToolBar = class (ToolBarToolBar);(ToolBarToolBar); Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also HighlightingToolBar Members | C1.Win.C1Input Namespace

HighlightingToolBar Members
HighlightingToolBar overview Public Properties Appearance (inherited from ToolBar) AutoSize (inherited from ToolBar) BorderStyle (inherited from ToolBar) Buttons (inherited from ToolBar) ButtonSize (inherited from ToolBar) Divider (inherited from ToolBar) DropDownArrows (inherited from ToolBar) ImageList (inherited from ToolBar) ImageSize (inherited from ToolBar) Controls the appearance of the ToolBar control, using values from the ToolBarAppearance enumeration. Controls whether the ToolBar will automatically size itself based on Button size. Controls what type of border the ToolBar control will have. The collection of ToolBarButtons that make up this ToolBar. The size of the buttons on the control if the button contents do not require a larger size. Controls whether the ToolBar will display a 3-D line at the top of its client area. Controls whether the ToolBar will display an arrow on the side of drop-down buttons. The ImageList from which this ToolBar will get all of the button images. The size of the images within the ToolBar's ImageList.

HighlightingToolBar Properties 259

ShowToolTips (inherited from ToolBar) TextAlign (inherited from ToolBar) Wrappable (inherited from ToolBar) Public Events AutoSizeChanged (inherited from ToolBar) ButtonClick (inherited from ToolBar) ButtonDropDown (inherited from ToolBar) See Also

Indicates whether ToolTips will be shown for each of the buttons, if available. Controls how the text is positioned relative to the Image in each button. Indicates if more than one row of buttons is allowed. Occurs when the AutoSize property has changed. Occurs whenever a button in the ToolBar is clicked by the user. Occurs whenever a button with the DropDownButton style is pressed.

HighlightingToolBar Class | C1.Win.C1Input Namespace

HighlightingToolBar Properties
The properties of the HighlightingToolBar class are listed here. For a complete list of HighlightingToolBar class members, see the HighlightingToolBar Members topic. Public Properties Appearance (inherited from ToolBar) AutoSize (inherited from ToolBar) BorderStyle (inherited from ToolBar) Buttons (inherited from ToolBar) ButtonSize (inherited from ToolBar) Divider (inherited from ToolBar) DropDownArrows (inherited from ToolBar) ImageList (inherited from ToolBar) ImageSize (inherited from ToolBar) ShowToolTips (inherited from ToolBar) TextAlign (inherited from ToolBar) Wrappable (inherited from ToolBar) See Also HighlightingToolBar Class | C1.Win.C1Input Namespace Controls the appearance of the ToolBar control, using values from the ToolBarAppearance enumeration. Controls whether the ToolBar will automatically size itself based on Button size. Controls what type of border the ToolBar control will have. The collection of ToolBarButtons that make up this ToolBar. The size of the buttons on the control if the button contents do not require a larger size. Controls whether the ToolBar will display a 3-D line at the top of its client area. Controls whether the ToolBar will display an arrow on the side of drop-down buttons. The ImageList from which this ToolBar will get all of the button images. The size of the images within the ToolBar's ImageList. Indicates whether ToolTips will be shown for each of the buttons, if available. Controls how the text is positioned relative to the Image in each button. Indicates if more than one row of buttons is allowed.

260 C1.Win.C1Input Namespace

HighlightingToolBar Events
The events of the HighlightingToolBar class are listed here. For a complete list of HighlightingToolBar class members, see the HighlightingToolBar Members topic. Public Events AutoSizeChanged (inherited from ToolBar) ButtonClick (inherited from ToolBar) ButtonDropDown (inherited from ToolBar) See Also HighlightingToolBar Class | C1.Win.C1Input Namespace Occurs when the AutoSize property has changed. Occurs whenever a button in the ToolBar is clicked by the user. Occurs whenever a button with the DropDownButton style is pressed.

Margins Class
Represents the four margins around a control's content. For a list of all members of this type, see Margins Members. System.Object C1.Win.C1Input.Margins [Visual Basic] Public Class Margins ImplementsICloneableICloneable [C#] public class Margins :ICloneableICloneable [Delphi] type Margins = class (TObject,(TObject,ICloneableICloneable); Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also Margins Members | C1.Win.C1Input Namespace

Margins Members
Margins overview Public Properties Bottom Left Right Top Gets or sets the bottom margin, in pixels. Gets or sets the left margin, in pixels. Gets or sets the right margin, in pixels. Gets or sets the top margin, in pixels.

Margins Properties 261

Public Methods Reset Set ShouldSerialize See Also Margins Class | C1.Win.C1Input Namespace Sets all margins to zero. Overloaded. Overloaded. Sets the margin values. Returns True if at least one margin differs from the default zero value. Otherwise, returns False.

Margins Properties
The properties of the Margins class are listed here. For a complete list of Margins class members, see the Margins Members topic. Public Properties Bottom Left Right Top See Also Margins Class | C1.Win.C1Input Namespace Gets or sets the bottom margin, in pixels. Gets or sets the left margin, in pixels. Gets or sets the right margin, in pixels. Gets or sets the top margin, in pixels.

Margins.Bottom Property
Gets or sets the bottom margin, in pixels. [Visual Basic] Public Property Bottom As Integer [C#] public int Bottom {get;set;} [Delphi] public property Bottom: Int32 read get_Bottom write set_Bottom; See Also Margins Class | Margins Members | C1.Win.C1Input Namespace

Margins.Left Property
Gets or sets the left margin, in pixels. [Visual Basic] Public Property Left As Integer [C#] public int Left {get;set;}

262 C1.Win.C1Input Namespace

[Delphi] public property Left: Int32 read get_Left write set_Left; See Also Margins Class | Margins Members | C1.Win.C1Input Namespace

Margins.Right Property
Gets or sets the right margin, in pixels. [Visual Basic] Public Property Right As Integer [C#] public int Right {get;set;} [Delphi] public property Right: Int32 read get_Right write set_Right; See Also Margins Class | Margins Members | C1.Win.C1Input Namespace

Margins.Top Property
Gets or sets the top margin, in pixels. [Visual Basic] Public Property Top As Integer [C#] public int Top {get;set;} [Delphi] public property Top: Int32 read get_Top write set_Top; See Also Margins Class | Margins Members | C1.Win.C1Input Namespace

Margins Methods
The methods of the Margins class are listed here. For a complete list of Margins class members, see the Margins Members topic. Public Methods Reset Set ShouldSerialize See Also Margins Class | C1.Win.C1Input Namespace Sets all margins to zero. Overloaded. Overloaded. Sets the margin values. Returns True if at least one margin differs from the default zero value. Otherwise, returns False.

Margins.Reset Method 263

Margins.Reset Method
Sets all margins to zero. [Visual Basic] Public Sub Reset() [C#] public void Reset() [Delphi] public procedure Reset(); See Also Margins Class | Margins Members | C1.Win.C1Input Namespace

Margins.Set Method
Overload List Overloaded. Sets the margin values. [Visual Basic] Overloads Public Sub Set(Integer, Integer, Integer, Integer) [C#] public void Set(int, int, int, int); [Delphi] public procedure Set(Int32; Int32; Int32; Int32); overload; Overloaded. Sets the margin values. [Visual Basic] Overloads Public Sub Set(Margins) [C#] public void Set(Margins); [Delphi] public procedure Set(Margins); overload; See Also Margins Class | Margins Members | C1.Win.C1Input Namespace

Margins.Set Method (Int32, Int32, Int32, Int32)


Overloaded. Sets the margin values. [Visual Basic] Overloads Public Sub Set( _ ByVal left As Integer, _ ByVal right As Integer, _ ByVal top As Integer, _ ByVal bottom As Integer _ ) [C#] public int int int int );

void Set( left, right, top, bottom

264 C1.Win.C1Input Namespace

[Delphi] public procedure Set( left: Int32; right: Int32; top: Int32; bottom: Int32 ); overload; Parameters left right top bottom See Also Margins Class | Margins Members | C1.Win.C1Input Namespace | Margins.Set Overload List

Margins.Set Method (Margins)


Overloaded. Sets the margin values. [Visual Basic] Overloads Public Sub Set( _ ByVal printMargins As Margins _ ) [C#] public void Set( Margins printMargins ); [Delphi] public procedure Set( printMargins: Margins ); overload; Parameters printMargins See Also Margins Class | Margins Members | C1.Win.C1Input Namespace | Margins.Set Overload List

Margins.ShouldSerialize Method
Returns True if at least one margin differs from the default zero value. Otherwise, returns False. [Visual Basic] Public Function ShouldSerialize() As Boolean [C#] public bool ShouldSerialize()

MaskInfo Class 265

[Delphi] public function ShouldSerialize(): Boolean; See Also Margins Class | Margins Members | C1.Win.C1Input Namespace

MaskInfo Class
Contains edit mask settings. For a list of all members of this type, see MaskInfo Members. System.Object System.MarshalByRefObject C1.Win.C1Input.MaskInfo [Visual Basic] Public Class MaskInfo InheritsMarshalByRefObjectMarshalByRefObject ImplementsICustomTypeDescriptorICustomTypeDescriptor,IDisposableIDispos able,ISupportInitializeISupportInitialize [C#] public class MaskInfo :MarshalByRefObjectMarshalByRefObject ,ICustomTypeDescriptorICustomTypeDescriptor,IDisposableIDisposable,ISuppor tInitializeISupportInitialize [Delphi] type MaskInfo = class (MarshalByRefObjectMarshalByRefObject,(MarshalByRefObjectMarshalByRefObjec t,ICustomTypeDescriptorICustomTypeDescriptor,IDisposableIDisposable,ISuppo rtInitializeISupportInitialize); Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also MaskInfo Members | C1.Win.C1Input Namespace

MaskInfo Members
MaskInfo overview Public Properties AutoTabWhenFilled CaseSensitive CopyWithLiterals CustomPlaceholders EditMask If True, focus automatically moves to the next control when the mask is filled. True if comparison with mask literals is case-sensitive; otherwise, False. If True, text copied to the clipboard includes literals. The collection of user-defined mask characters. The edit mask string restricting user input.

266 C1.Win.C1Input Namespace

EmptyAsNull ErrorMessage Inherit PromptChar SaveBlanks SaveLiterals ShowLiterals SkipOptional

If True, empty strings are interpreted as null values (DbNull). Error message shown in the standard message box and/or if an exception occurs. Manages inheritance of the MaskInfo properties from the host control properties. Character displayed on empty mask positions in edit mode. If True, the stored text includes blank positions as StoredEmptyChar. If True (default), the stored text includes literals. Literal display method. If True (default), optional mask positions are automatically skipped until the first position allowing the typed character. Character stored in empty mask positions. Returns the string containing characters entered by the user, including those on optional positions that were left blank (skipped). Returns a string formatted for display using edit mask. Returns the string that will be stored in the database, in accordance with current values of SaveLiterals, SaveBlanks and StoredEmptyChar properties. Returns True if EditMask is non-empty and the control is in edit mode. Returns True if the input string is valid with respect to the edit mask. Resets whole MaskInfo property of base control Resets the text to the string representing a DBNull value.

StoredEmptyChar Public Methods GetContent

GetDisplayText GetStoredText

IsMaskedMode IsValid Reset ResetContent See Also MaskInfo Class | C1.Win.C1Input Namespace

MaskInfo Properties
The properties of the MaskInfo class are listed here. For a complete list of MaskInfo class members, see the MaskInfo Members topic. Public Properties AutoTabWhenFilled CaseSensitive If True, focus automatically moves to the next control when the mask is filled. True if comparison with mask literals is case-sensitive; otherwise, False.

MaskInfo.AutoTabWhenFilled Property 267

CopyWithLiterals CustomPlaceholders EditMask EmptyAsNull ErrorMessage Inherit PromptChar SaveBlanks SaveLiterals ShowLiterals SkipOptional

If True, text copied to the clipboard includes literals. The collection of user-defined mask characters. The edit mask string restricting user input. If True, empty strings are interpreted as null values (DbNull). Error message shown in the standard message box and/or if an exception occurs. Manages inheritance of the MaskInfo properties from the host control properties. Character displayed on empty mask positions in edit mode. If True, the stored text includes blank positions as StoredEmptyChar. If True (default), the stored text includes literals. Literal display method. If True (default), optional mask positions are automatically skipped until the first position allowing the typed character. Character stored in empty mask positions.

StoredEmptyChar See Also MaskInfo Class | C1.Win.C1Input Namespace

MaskInfo.AutoTabWhenFilled Property
If True, focus automatically moves to the next control when the mask is filled. [Visual Basic] Public Property AutoTabWhenFilled As Boolean [C#] public bool AutoTabWhenFilled {get;set;} [Delphi] public property AutoTabWhenFilled: Boolean read get_AutoTabWhenFilled write set_AutoTabWhenFilled; See Also MaskInfo Class | MaskInfo Members | C1.Win.C1Input Namespace

MaskInfo.CaseSensitive Property
True if comparison with mask literals is case-sensitive; otherwise, False. [Visual Basic] Public Property CaseSensitive As Boolean [C#] public bool CaseSensitive {get;set;}

268 C1.Win.C1Input Namespace

[Delphi] public property CaseSensitive: Boolean read get_CaseSensitive write set_CaseSensitive; See Also MaskInfo Class | MaskInfo Members | C1.Win.C1Input Namespace

MaskInfo.CopyWithLiterals Property
If True, text copied to the clipboard includes literals. [Visual Basic] Public Property CopyWithLiterals As Boolean [C#] public bool CopyWithLiterals {get;set;} [Delphi] public property CopyWithLiterals: Boolean read get_CopyWithLiterals write set_CopyWithLiterals; See Also MaskInfo Class | MaskInfo Members | C1.Win.C1Input Namespace

MaskInfo.CustomPlaceholders Property
The collection of user-defined mask characters. [Visual Basic] Public ReadOnly Property CustomPlaceholders As PlaceholderCollection [C#] public PlaceholderCollection CustomPlaceholders {get;} [Delphi] public property CustomPlaceholders: PlaceholderCollection read get_CustomPlaceholders; See Also MaskInfo Class | MaskInfo Members | C1.Win.C1Input Namespace

MaskInfo.EditMask Property
The edit mask string restricting user input. [Visual Basic] Public Property EditMask As String [C#] public string EditMask {get;set;} [Delphi] public property EditMask: String read get_EditMask write set_EditMask;

MaskInfo.EmptyAsNull Property 269

See Also MaskInfo Class | MaskInfo Members | C1.Win.C1Input Namespace

MaskInfo.EmptyAsNull Property
If True, empty strings are interpreted as null values (DbNull). [Visual Basic] Public Property EmptyAsNull As Boolean [C#] public bool EmptyAsNull {get;set;} [Delphi] public property EmptyAsNull: Boolean read get_EmptyAsNull write set_EmptyAsNull; See Also MaskInfo Class | MaskInfo Members | C1.Win.C1Input Namespace

MaskInfo.ErrorMessage Property
Error message shown in the standard message box and/or if an exception occurs. [Visual Basic] Public Property ErrorMessage As String [C#] public string ErrorMessage {get;set;} [Delphi] public property ErrorMessage: String read get_ErrorMessage write set_ErrorMessage; See Also MaskInfo Class | MaskInfo Members | C1.Win.C1Input Namespace

MaskInfo.Inherit Property
Manages inheritance of the MaskInfo properties from the host control properties. [Visual Basic] Public Property Inherit As MaskInfoInheritFlags [C#] public MaskInfoInheritFlags Inherit {get;set;} [Delphi] public property Inherit: MaskInfoInheritFlags read get_Inherit write set_Inherit; See Also MaskInfo Class | MaskInfo Members | C1.Win.C1Input Namespace

270 C1.Win.C1Input Namespace

MaskInfo.PromptChar Property
Character displayed on empty mask positions in edit mode. [Visual Basic] Public Property PromptChar As Char [C#] public char PromptChar {get;set;} [Delphi] public property PromptChar: Char read get_PromptChar write set_PromptChar; See Also MaskInfo Class | MaskInfo Members | C1.Win.C1Input Namespace

MaskInfo.SaveBlanks Property
If True, the stored text includes blank positions as StoredEmptyChar. [Visual Basic] Public Property SaveBlanks As Boolean [C#] public bool SaveBlanks {get;set;} [Delphi] public property SaveBlanks: Boolean read get_SaveBlanks write set_SaveBlanks; See Also MaskInfo Class | MaskInfo Members | C1.Win.C1Input Namespace

MaskInfo.SaveLiterals Property
If True (default), the stored text includes literals. [Visual Basic] Public Property SaveLiterals As Boolean [C#] public bool SaveLiterals {get;set;} [Delphi] public property SaveLiterals: Boolean read get_SaveLiterals write set_SaveLiterals; See Also MaskInfo Class | MaskInfo Members | C1.Win.C1Input Namespace

MaskInfo.ShowLiterals Property
Literal display method.

MaskInfo.SkipOptional Property 271

[Visual Basic] Public Property ShowLiterals As ShowLiteralsEnum [C#] public ShowLiteralsEnum ShowLiterals {get;set;} [Delphi] public property ShowLiterals: ShowLiteralsEnum read get_ShowLiterals write set_ShowLiterals; See Also MaskInfo Class | MaskInfo Members | C1.Win.C1Input Namespace

MaskInfo.SkipOptional Property
If True (default), optional mask positions are automatically skipped until the first position allowing the typed character. [Visual Basic] Public Property SkipOptional As Boolean [C#] public bool SkipOptional {get;set;} [Delphi] public property SkipOptional: Boolean read get_SkipOptional write set_SkipOptional; See Also MaskInfo Class | MaskInfo Members | C1.Win.C1Input Namespace

MaskInfo.StoredEmptyChar Property
Character stored in empty mask positions. [Visual Basic] Public Property StoredEmptyChar As Char [C#] public char StoredEmptyChar {get;set;} [Delphi] public property StoredEmptyChar: Char read get_StoredEmptyChar write set_StoredEmptyChar; See Also MaskInfo Class | MaskInfo Members | C1.Win.C1Input Namespace

MaskInfo Methods
The methods of the MaskInfo class are listed here. For a complete list of MaskInfo class members, see the MaskInfo Members topic.

272 C1.Win.C1Input Namespace

Public Methods GetContent Returns the string containing characters entered by the user, including those on optional positions that were left blank (skipped). Returns a string formatted for display using edit mask. Returns the string that will be stored in the database, in accordance with current values of SaveLiterals, SaveBlanks and StoredEmptyChar properties. Returns True if EditMask is non-empty and the control is in edit mode. Returns True if the input string is valid with respect to the edit mask. Resets whole MaskInfo property of base control Resets the text to the string representing a DBNull value.

GetDisplayText GetStoredText

IsMaskedMode IsValid Reset ResetContent See Also MaskInfo Class | C1.Win.C1Input Namespace

MaskInfo.GetContent Method
Returns the string containing characters entered by the user, including those on optional positions that were left blank (skipped). [Visual Basic] Public Function GetContent( _ ByVal text As String, _ ByVal textContainsLiterals As Boolean, _ ByVal textContainsBlanks As Boolean, _ ByVal blankCharacter As Char _ ) As String [C#] public string GetContent( string text, bool textContainsLiterals, bool textContainsBlanks, char blankCharacter ); [Delphi] public function GetContent( text: String; textContainsLiterals: Boolean; textContainsBlanks: Boolean; blankCharacter: Char ): String; Parameters text Text to parse.

MaskInfo.GetDisplayText Method 273

textContainsLiterals Same as MaskInfo.SaveLiterals property. textContainsBlanks Same as MaskInfo.SaveBlanks property. blankCharacter Same as MaskInfo.StoredEmptyChar property See Also MaskInfo Class | MaskInfo Members | C1.Win.C1Input Namespace

MaskInfo.GetDisplayText Method
Returns a string formatted for display using edit mask. [Visual Basic] Public Function GetDisplayText( _ ByVal content As String, _ ByVal skipBlanks As Boolean _ ) As String [C#] public string GetDisplayText( string content, bool skipBlanks ); [Delphi] public function GetDisplayText( content: String; skipBlanks: Boolean ): String; Parameters content String containing characters entered by the user, including those on optional positions that were left blank (skipped). skipBlanks If set to True, the result will omit blank positions. If set to False, the resulting text will contain PromptChar on blank positions See Also MaskInfo Class | MaskInfo Members | C1.Win.C1Input Namespace

MaskInfo.GetStoredText Method
Returns the string that will be stored in the database, in accordance with current values of SaveLiterals, SaveBlanks and StoredEmptyChar properties. [Visual Basic] Public Function GetStoredText( _ ByVal content As String _ ) As String

274 C1.Win.C1Input Namespace

[C#] public string GetStoredText( string content ); [Delphi] public function GetStoredText( content: String ): String; Parameters content String containing characters entered by the user, including those on optional positions that were left blank (skipped). See Also MaskInfo Class | MaskInfo Members | C1.Win.C1Input Namespace

MaskInfo.IsMaskedMode Method
Returns True if EditMask is non-empty and the control is in edit mode. [Visual Basic] Public Function IsMaskedMode() As Boolean [C#] public bool IsMaskedMode() [Delphi] public function IsMaskedMode(): Boolean; See Also MaskInfo Class | MaskInfo Members | C1.Win.C1Input Namespace

MaskInfo.IsValid Method
Returns True if the input string is valid with respect to the edit mask. [Visual Basic] Public Function IsValid() As Boolean [C#] public bool IsValid() [Delphi] public function IsValid(): Boolean; See Also MaskInfo Class | MaskInfo Members | C1.Win.C1Input Namespace

MaskInfo.Reset Method
Resets whole MaskInfo property of base control

MaskInfo.ResetContent Method 275

[Visual Basic] Public Sub Reset() [C#] public void Reset() [Delphi] public procedure Reset(); See Also MaskInfo Class | MaskInfo Members | C1.Win.C1Input Namespace

MaskInfo.ResetContent Method
Resets the text to the string representing a DBNull value. [Visual Basic] Public Sub ResetContent() [C#] public void ResetContent() [Delphi] public procedure ResetContent(); See Also MaskInfo Class | MaskInfo Members | C1.Win.C1Input Namespace

NumericEditCalculator Class
The calculator used as a drop-down in the C1NumericEdit control. For a list of all members of this type, see NumericEditCalculator Members. System.Object System.MarshalByRefObject System.ComponentModel.Component System.Windows.Forms.Control C1.Win.C1Input.NumericEditCalculator [Visual Basic] Public Class NumericEditCalculator InheritsControlControl [C#] public class NumericEditCalculator :ControlControl [Delphi] type NumericEditCalculator = class (ControlControl);(ControlControl); Namespace: C1.Win.C1Input

276 C1.Win.C1Input Namespace

Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also NumericEditCalculator Members | C1.Win.C1Input Namespace

NumericEditCalculator Members
NumericEditCalculator overview Public Properties ButtonFlatStyle DisplayFormat FormatOnClose StoredFormat UIStrings UseStaticMemory See Also NumericEditCalculator Class | C1.Win.C1Input Namespace Determines the style of the drop-down calculator buttons. patch: localization: added after StringTables.cs was created Gets or sets whether StoredFormat should be applied to the value entered in the drop-down calculator. Custom format specifier used to format the stored value of the drop-down calculator. The collection of user interface strings. Gets or sets whether Static Memory context menu should appear for the drop-down calculator.

NumericEditCalculator Properties
The properties of the NumericEditCalculator class are listed here. For a complete list of NumericEditCalculator class members, see the NumericEditCalculator Members topic. Public Properties ButtonFlatStyle DisplayFormat FormatOnClose StoredFormat UIStrings UseStaticMemory See Also NumericEditCalculator Class | C1.Win.C1Input Namespace Determines the style of the drop-down calculator buttons. patch: localization: added after StringTables.cs was created Gets or sets whether StoredFormat should be applied to the value entered in the drop-down calculator. Custom format specifier used to format the stored value of the drop-down calculator. The collection of user interface strings. Gets or sets whether Static Memory context menu should appear for the drop-down calculator.

NumericEditCalculator.ButtonFlatStyle Property
Determines the style of the drop-down calculator buttons.

NumericEditCalculator.DisplayFormat Property 277

[Visual Basic] Public Property ButtonFlatStyle As FlatStyle [C#] public FlatStyle ButtonFlatStyle {get;set;} [Delphi] public property ButtonFlatStyle: FlatStyle read get_ButtonFlatStyle write set_ButtonFlatStyle; See Also NumericEditCalculator Class | NumericEditCalculator Members | C1.Win.C1Input Namespace

NumericEditCalculator.DisplayFormat Property
patch: localization: added after StringTables.cs was created [Visual Basic] Public Property DisplayFormat As String [C#] public string DisplayFormat {get;set;} [Delphi] public property DisplayFormat: String read get_DisplayFormat write set_DisplayFormat; See Also NumericEditCalculator Class | NumericEditCalculator Members | C1.Win.C1Input Namespace

NumericEditCalculator.FormatOnClose Property
Gets or sets whether StoredFormat should be applied to the value entered in the drop-down calculator. [Visual Basic] Public Property FormatOnClose As Boolean [C#] public bool FormatOnClose {get;set;} [Delphi] public property FormatOnClose: Boolean read get_FormatOnClose write set_FormatOnClose; See Also NumericEditCalculator Class | NumericEditCalculator Members | C1.Win.C1Input Namespace

NumericEditCalculator.StoredFormat Property
Custom format specifier used to format the stored value of the drop-down calculator. [Visual Basic] Public Property StoredFormat As String

278 C1.Win.C1Input Namespace

[C#] public string StoredFormat {get;set;} [Delphi] public property StoredFormat: String read get_StoredFormat write set_StoredFormat; See Also NumericEditCalculator Class | NumericEditCalculator Members | C1.Win.C1Input Namespace

NumericEditCalculator.UIStrings Property
The collection of user interface strings. [Visual Basic] Public ReadOnly Property UIStrings As UIStrings [C#] public UIStrings UIStrings {get;} [Delphi] public property UIStrings: UIStrings read get_UIStrings; See Also NumericEditCalculator Class | NumericEditCalculator Members | C1.Win.C1Input Namespace

NumericEditCalculator.UseStaticMemory Property
Gets or sets whether Static Memory context menu should appear for the drop-down calculator. [Visual Basic] Public Property UseStaticMemory As Boolean [C#] public bool UseStaticMemory {get;set;} [Delphi] public property UseStaticMemory: Boolean read get_UseStaticMemory write set_UseStaticMemory; See Also NumericEditCalculator Class | NumericEditCalculator Members | C1.Win.C1Input Namespace

ParseInfo Class
Contains settings affecting parsing, that is, converting a string to the required data type. For a list of all members of this type, see ParseInfo Members. System.Object System.MarshalByRefObject C1.Win.C1Input.ParseInfo

ParseInfo Members 279

[Visual Basic] Public Class ParseInfo InheritsMarshalByRefObjectMarshalByRefObject ImplementsICustomTypeDescriptorICustomTypeDescriptor,IDisposableIDispos able [C#] public class ParseInfo :MarshalByRefObjectMarshalByRefObject ,ICustomTypeDescriptorICustomTypeDescriptor,IDisposableIDisposable [Delphi] type ParseInfo = class (MarshalByRefObjectMarshalByRefObject,(MarshalByRefObjectMarshalByRefObjec t,ICustomTypeDescriptorICustomTypeDescriptor,IDisposableIDisposable); Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also ParseInfo Members | C1.Win.C1Input Namespace

ParseInfo Members
ParseInfo overview Public Properties CaseSensitive CustomFormat DateTimeStyle EmptyAsNull ErrorMessage FormatType Inherit NullText NumberStyle TrimEnd TrimStart Public Methods IsTextDbNull Returns True if the argument represents a null value (DBNull). True if string comparisons are case-sensitive; otherwise, False. Custom format specifier (in parsing used for DateTime and Boolean types only). Determines the styles (flags) permitted in input strings representing date/time. If True, empty strings are interpreted as null values (DbNull). Error message shown in the standard message box and/or in the exception. The format used for parsing. Manages inheritance of the ParseInfo properties from the host control properties. The string representing DbNull value. Determines the styles (flags) permitted in input strings representing numbers. If True, trailing spaces are removed before parsing. If True, leading spaces are removed before parsing.

280 C1.Win.C1Input Namespace

Parse ParseBoolean ParseDateTime ParseFixed ParseFloat ParseInteger Reset See Also ParseInfo Class | C1.Win.C1Input Namespace

Converts text to the specified data type. Converts the text to a Boolean value. Converts text to a value using one of DateTime formats. Converts the text to a Decimal value using a fixed numeric format. Converts the text to a Double value using a float numeric format. Converts the text to Int64 value using an integer numeric format. Resets whole ParseInfo property of base control

ParseInfo Properties
The properties of the ParseInfo class are listed here. For a complete list of ParseInfo class members, see the ParseInfo Members topic. Public Properties CaseSensitive CustomFormat DateTimeStyle EmptyAsNull ErrorMessage FormatType Inherit NullText NumberStyle TrimEnd TrimStart See Also ParseInfo Class | C1.Win.C1Input Namespace True if string comparisons are case-sensitive; otherwise, False. Custom format specifier (in parsing used for DateTime and Boolean types only). Determines the styles (flags) permitted in input strings representing date/time. If True, empty strings are interpreted as null values (DbNull). Error message shown in the standard message box and/or in the exception. The format used for parsing. Manages inheritance of the ParseInfo properties from the host control properties. The string representing DbNull value. Determines the styles (flags) permitted in input strings representing numbers. If True, trailing spaces are removed before parsing. If True, leading spaces are removed before parsing.

ParseInfo.CaseSensitive Property
True if string comparisons are case-sensitive; otherwise, False.

ParseInfo.CustomFormat Property 281

[Visual Basic] Public Property CaseSensitive As Boolean [C#] public bool CaseSensitive {get;set;} [Delphi] public property CaseSensitive: Boolean read get_CaseSensitive write set_CaseSensitive; See Also ParseInfo Class | ParseInfo Members | C1.Win.C1Input Namespace

ParseInfo.CustomFormat Property
Custom format specifier (in parsing used for DateTime and Boolean types only). [Visual Basic] Public Property CustomFormat As String [C#] public string CustomFormat {get;set;} [Delphi] public property CustomFormat: String read get_CustomFormat write set_CustomFormat; See Also ParseInfo Class | ParseInfo Members | C1.Win.C1Input Namespace

ParseInfo.DateTimeStyle Property
Determines the styles (flags) permitted in input strings representing date/time. [Visual Basic] Public Property DateTimeStyle As DateTimeStyleFlags [C#] public DateTimeStyleFlags DateTimeStyle {get;set;} [Delphi] public property DateTimeStyle: DateTimeStyleFlags read get_DateTimeStyle write set_DateTimeStyle; See Also ParseInfo Class | ParseInfo Members | C1.Win.C1Input Namespace

ParseInfo.EmptyAsNull Property
If True, empty strings are interpreted as null values (DbNull). [Visual Basic] Public Property EmptyAsNull As Boolean

282 C1.Win.C1Input Namespace

[C#] public bool EmptyAsNull {get;set;} [Delphi] public property EmptyAsNull: Boolean read get_EmptyAsNull write set_EmptyAsNull; See Also ParseInfo Class | ParseInfo Members | C1.Win.C1Input Namespace

ParseInfo.ErrorMessage Property
Error message shown in the standard message box and/or in the exception. [Visual Basic] Public Property ErrorMessage As String [C#] public string ErrorMessage {get;set;} [Delphi] public property ErrorMessage: String read get_ErrorMessage write set_ErrorMessage; See Also ParseInfo Class | ParseInfo Members | C1.Win.C1Input Namespace

ParseInfo.FormatType Property
The format used for parsing. [Visual Basic] Public Property FormatType As FormatTypeEnum [C#] public FormatTypeEnum FormatType {get;set;} [Delphi] public property FormatType: FormatTypeEnum read get_FormatType write set_FormatType; See Also ParseInfo Class | ParseInfo Members | C1.Win.C1Input Namespace

ParseInfo.Inherit Property
Manages inheritance of the ParseInfo properties from the host control properties. [Visual Basic] Public Property Inherit As ParseInfoInheritFlags [C#] public ParseInfoInheritFlags Inherit {get;set;}

ParseInfo.NullText Property 283

[Delphi] public property Inherit: ParseInfoInheritFlags read get_Inherit write set_Inherit; See Also ParseInfo Class | ParseInfo Members | C1.Win.C1Input Namespace

ParseInfo.NullText Property
The string representing DbNull value. [Visual Basic] Public Property NullText As String [C#] public string NullText {get;set;} [Delphi] public property NullText: String read get_NullText write set_NullText; See Also ParseInfo Class | ParseInfo Members | C1.Win.C1Input Namespace

ParseInfo.NumberStyle Property
Determines the styles (flags) permitted in input strings representing numbers. [Visual Basic] Public Property NumberStyle As NumberStyleFlags [C#] public NumberStyleFlags NumberStyle {get;set;} [Delphi] public property NumberStyle: NumberStyleFlags read get_NumberStyle write set_NumberStyle; See Also ParseInfo Class | ParseInfo Members | C1.Win.C1Input Namespace

ParseInfo.TrimEnd Property
If True, trailing spaces are removed before parsing. [Visual Basic] Public Property TrimEnd As Boolean [C#] public bool TrimEnd {get;set;} [Delphi] public property TrimEnd: Boolean read get_TrimEnd write set_TrimEnd;

284 C1.Win.C1Input Namespace

See Also ParseInfo Class | ParseInfo Members | C1.Win.C1Input Namespace

ParseInfo.TrimStart Property
If True, leading spaces are removed before parsing. [Visual Basic] Public Property TrimStart As Boolean [C#] public bool TrimStart {get;set;} [Delphi] public property TrimStart: Boolean read get_TrimStart write set_TrimStart; See Also ParseInfo Class | ParseInfo Members | C1.Win.C1Input Namespace

ParseInfo Methods
The methods of the ParseInfo class are listed here. For a complete list of ParseInfo class members, see the ParseInfo Members topic. Public Methods IsTextDbNull Parse ParseBoolean ParseDateTime ParseFixed ParseFloat ParseInteger Reset See Also ParseInfo Class | C1.Win.C1Input Namespace Returns True if the argument represents a null value (DBNull). Converts text to the specified data type. Converts the text to a Boolean value. Converts text to a value using one of DateTime formats. Converts the text to a Decimal value using a fixed numeric format. Converts the text to a Double value using a float numeric format. Converts the text to Int64 value using an integer numeric format. Resets whole ParseInfo property of base control

ParseInfo.IsTextDbNull Method
Returns True if the argument represents a null value (DBNull). [Visual Basic] Public Function IsTextDbNull( _ ByVal text As String, _ ByVal culture As CultureInfo _ ) As Boolean

ParseInfo.Parse Method 285

[C#] public bool IsTextDbNull( string text, CultureInfo culture ); [Delphi] public function IsTextDbNull( text: String; culture: CultureInfo ): Boolean; Parameters text The string to parse. culture Culture used in parsing. See Also ParseInfo Class | ParseInfo Members | C1.Win.C1Input Namespace

ParseInfo.Parse Method
Converts text to the specified data type. [Visual Basic] Public Function Parse( _ ByVal text As String, _ ByVal destinationType As Type, _ ByRef result As Object, _ ByVal errorInfo As ErrorInfo _ ) As Boolean [C#] public bool Parse( string text, Type destinationType, out object result, ErrorInfo errorInfo ); [Delphi] public function Parse( text: String; destinationType: Type; out result: Object; errorInfo: ErrorInfo ): Boolean; Parameters text The string to parse.

286 C1.Win.C1Input Namespace

destinationType Type to which the string is converted. result Conversion result. errorInfo Object detailing error information, if an error occurred. See Also ParseInfo Class | ParseInfo Members | C1.Win.C1Input Namespace

ParseInfo.ParseBoolean Method
Converts the text to a Boolean value. [Visual Basic] Public Function ParseBoolean( _ ByVal text As String, _ ByVal formatType As FormatTypeEnum, _ ByVal culture As CultureInfo _ ) As Boolean [C#] public bool ParseBoolean( string text, FormatTypeEnum formatType, CultureInfo culture ); [Delphi] public function ParseBoolean( text: String; formatType: FormatTypeEnum; culture: CultureInfo ): Boolean; Parameters text The string to parse. formatType Format type used in parsing. culture Culture used in parsing. See Also ParseInfo Class | ParseInfo Members | C1.Win.C1Input Namespace

ParseInfo.ParseDateTime Method
Converts text to a value using one of DateTime formats.

ParseInfo.ParseFixed Method 287

[Visual Basic] Public Function ParseDateTime( _ ByVal text As String, _ ByVal formatType As FormatTypeEnum, _ ByVal culture As CultureInfo _ ) As Date [C#] public DateTime ParseDateTime( string text, FormatTypeEnum formatType, CultureInfo culture ); [Delphi] public function ParseDateTime( text: String; formatType: FormatTypeEnum; culture: CultureInfo ): DateTime; Parameters text The string to parse. formatType Format type used in parsing. culture Culture used in parsing. See Also ParseInfo Class | ParseInfo Members | C1.Win.C1Input Namespace

ParseInfo.ParseFixed Method
Converts the text to a Decimal value using a fixed numeric format. [Visual Basic] Public Function ParseFixed( _ ByVal text As String, _ ByVal formatType As FormatTypeEnum, _ ByVal culture As CultureInfo _ ) As Decimal [C#] public decimal ParseFixed( string text, FormatTypeEnum formatType, CultureInfo culture );

288 C1.Win.C1Input Namespace

[Delphi] public function ParseFixed( text: String; formatType: FormatTypeEnum; culture: CultureInfo ): Decimal; Parameters text The string to parse. formatType Format type used in parsing. culture Culture used in parsing. See Also ParseInfo Class | ParseInfo Members | C1.Win.C1Input Namespace

ParseInfo.ParseFloat Method
Converts the text to a Double value using a float numeric format. [Visual Basic] Public Function ParseFloat( _ ByVal text As String, _ ByVal formatType As FormatTypeEnum, _ ByVal culture As CultureInfo _ ) As Double [C#] public double ParseFloat( string text, FormatTypeEnum formatType, CultureInfo culture ); [Delphi] public function ParseFloat( text: String; formatType: FormatTypeEnum; culture: CultureInfo ): Double; Parameters text The string to parse. formatType Format type used in parsing. culture Culture used in parsing.

ParseInfo.ParseInteger Method 289

See Also ParseInfo Class | ParseInfo Members | C1.Win.C1Input Namespace

ParseInfo.ParseInteger Method
Converts the text to Int64 value using an integer numeric format. [Visual Basic] Public Function ParseInteger( _ ByVal text As String, _ ByVal formatType As FormatTypeEnum, _ ByVal culture As CultureInfo _ ) As Long [C#] public long ParseInteger( string text, FormatTypeEnum formatType, CultureInfo culture ); [Delphi] public function ParseInteger( text: String; formatType: FormatTypeEnum; culture: CultureInfo ): Int64; Parameters text formatType culture See Also ParseInfo Class | ParseInfo Members | C1.Win.C1Input Namespace

ParseInfo.Reset Method
Resets whole ParseInfo property of base control [Visual Basic] Public Sub Reset() [C#] public void Reset() [Delphi] public procedure Reset(); See Also ParseInfo Class | ParseInfo Members | C1.Win.C1Input Namespace

290 C1.Win.C1Input Namespace

PlaceholderCollection Class
A collection of CustomPlaceholder objects. For a list of all members of this type, see PlaceholderCollection Members. System.Object System.Collections.CollectionBase C1.Win.C1Input.PlaceholderCollection [Visual Basic] Public Class PlaceholderCollection InheritsCollectionBaseCollectionBase [C#] public class PlaceholderCollection :CollectionBaseCollectionBase [Delphi] type PlaceholderCollection = class (CollectionBaseCollectionBase);(CollectionBaseCollectionBase); Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also PlaceholderCollection Members | C1.Win.C1Input Namespace

PlaceholderCollection Members
PlaceholderCollection overview Public Methods Add CheckItemBeforeAdding Contains CopyTo GetItem Adds a new special character to the collection. Checks validity of the placeholder Determines whether a character is in the placeholder collection. Copies elements of the collection to an array starting at a particular array index. Returns the CustomPlaceholder object corresponding to the character argument, or null if it does not belong to the collection. Returns the index of a character in the placeholder collection, or -1 if it does not belong to the collection. Inserts a new special character to the collection at the specified position. Removes a specific character from the collection.

IndexOf Insert Remove See Also

PlaceholderCollection Class | C1.Win.C1Input Namespace

PlaceholderCollection Methods 291

PlaceholderCollection Methods
The methods of the PlaceholderCollection class are listed here. For a complete list of PlaceholderCollection class members, see the PlaceholderCollection Members topic. Public Methods Add CheckItemBeforeAdding Contains CopyTo GetItem Adds a new special character to the collection. Checks validity of the placeholder Determines whether a character is in the placeholder collection. Copies elements of the collection to an array starting at a particular array index. Returns the CustomPlaceholder object corresponding to the character argument, or null if it does not belong to the collection. Returns the index of a character in the placeholder collection, or -1 if it does not belong to the collection. Inserts a new special character to the collection at the specified position. Removes a specific character from the collection.

IndexOf Insert Remove See Also

PlaceholderCollection Class | C1.Win.C1Input Namespace

PlaceholderCollection.Add Method
Adds a new special character to the collection. [Visual Basic] Public Sub Add( _ ByVal cph As CustomPlaceholder _ ) [C#] public void Add( CustomPlaceholder cph ); [Delphi] public procedure Add( cph: CustomPlaceholder ); Parameters cph The CustomPlaceholder to add. See Also PlaceholderCollection Class | PlaceholderCollection Members | C1.Win.C1Input Namespace

292 C1.Win.C1Input Namespace

PlaceholderCollection.CheckItemBeforeAdding Method
Checks validity of the placeholder [Visual Basic] Public Sub CheckItemBeforeAdding( _ ByVal cph As CustomPlaceholder _ ) [C#] public void CheckItemBeforeAdding( CustomPlaceholder cph ); [Delphi] public procedure CheckItemBeforeAdding( cph: CustomPlaceholder ); Parameters cph See Also PlaceholderCollection Class | PlaceholderCollection Members | C1.Win.C1Input Namespace

PlaceholderCollection.Contains Method
Determines whether a character is in the placeholder collection. [Visual Basic] Public Function Contains( _ ByVal placeholder As Char _ ) As Boolean [C#] public bool Contains( char placeholder ); [Delphi] public function Contains( placeholder: Char ): Boolean; Parameters placeholder The character argument. See Also PlaceholderCollection Class | PlaceholderCollection Members | C1.Win.C1Input Namespace

PlaceholderCollection.CopyTo Method
Copies elements of the collection to an array starting at a particular array index.

PlaceholderCollection.GetItem Method 293

[Visual Basic] Public Sub CopyTo( _ ByVal array As CustomPlaceholder(), _ ByVal index As Integer _ ) [C#] public void CopyTo( CustomPlaceholder[] array, int index ); [Delphi] public procedure CopyTo( array: CustomPlaceholder(); index: Int32 ); Parameters array The one-array that is the destination of the elements copied from the collection. index The zero-based index in array at which copying begins. See Also PlaceholderCollection Class | PlaceholderCollection Members | C1.Win.C1Input Namespace

PlaceholderCollection.GetItem Method
Returns the CustomPlaceholder object corresponding to the character argument, or null if it does not belong to the collection. [Visual Basic] Public Function GetItem( _ ByVal placeholder As Char _ ) As CustomPlaceholder [C#] public CustomPlaceholder GetItem( char placeholder ); [Delphi] public function GetItem( placeholder: Char ): CustomPlaceholder; Parameters placeholder The character argument. See Also PlaceholderCollection Class | PlaceholderCollection Members | C1.Win.C1Input Namespace

294 C1.Win.C1Input Namespace

PlaceholderCollection.IndexOf Method
Returns the index of a character in the placeholder collection, or -1 if it does not belong to the collection. [Visual Basic] Public Function IndexOf( _ ByVal placeholder As Char _ ) As Integer [C#] public int IndexOf( char placeholder ); [Delphi] public function IndexOf( placeholder: Char ): Int32; Parameters placeholder The character argument. See Also PlaceholderCollection Class | PlaceholderCollection Members | C1.Win.C1Input Namespace

PlaceholderCollection.Insert Method
Inserts a new special character to the collection at the specified position. [Visual Basic] Public Sub Insert( _ ByVal index As Integer, _ ByVal cph As CustomPlaceholder _ ) [C#] public void Insert( int index, CustomPlaceholder cph ); [Delphi] public procedure Insert( index: Int32; cph: CustomPlaceholder ); Parameters index The zero-based index at which CustomPlaceholder should be inserted. cph The CustomPlaceholder to insert.

PlaceholderCollection.Remove Method 295

See Also PlaceholderCollection Class | PlaceholderCollection Members | C1.Win.C1Input Namespace

PlaceholderCollection.Remove Method
Removes a specific character from the collection. [Visual Basic] Public Sub Remove( _ ByVal placeholder As Char _ ) [C#] public void Remove( char placeholder ); [Delphi] public procedure Remove( placeholder: Char ); Parameters placeholder The character to remove from the collection. See Also PlaceholderCollection Class | PlaceholderCollection Members | C1.Win.C1Input Namespace

PostValidation Class
Validating the typed value after parsing, after the input string has been converted to the DataType. For a list of all members of this type, see PostValidation Members. System.Object System.MarshalByRefObject C1.Win.C1Input.PostValidation [Visual Basic] Public Class PostValidation InheritsMarshalByRefObjectMarshalByRefObject ImplementsIDisposableIDisposable [C#] public class PostValidation :MarshalByRefObjectMarshalByRefObject ,IDisposableIDisposable [Delphi] type PostValidation = class (MarshalByRefObjectMarshalByRefObject,(MarshalByRefObjectMarshalByRefObjec t,IDisposableIDisposable);

296 C1.Win.C1Input Namespace

Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also PostValidation Members | C1.Win.C1Input Namespace

PostValidation Members
PostValidation overview Public Properties AllowDbNull CaseSensitive ErrorMessage Inherit Intervals Validation Values ValuesExcluded Public Methods Reset Validate Resets whole PostValidation property of base control Performs validation using the current settings of the PostValidation object. Returns True if validation was successful. Performs validation of the value against the collections of Values, ValuesExcluded and Intervals. Determines whether it is possible to enter DbNull value in the control. True if string comparisons are case-sensitive; otherwise, False. Error message shown in the standard message box and/or in the exception. Manages inheritance of the PreValidation properties from the host control properties. Collection of intervals. The input value must belong to one of these intervals. Validation method. Predefined values used for matching the input value. List of values that are not permitted as input value.

ValidateValuesAndIntervals See Also PostValidation Class | C1.Win.C1Input Namespace

PostValidation Properties
The properties of the PostValidation class are listed here. For a complete list of PostValidation class members, see the PostValidation Members topic. Public Properties AllowDbNull CaseSensitive ErrorMessage Determines whether it is possible to enter DbNull value in the control. True if string comparisons are case-sensitive; otherwise, False. Error message shown in the standard message box and/or in the exception.

PostValidation.AllowDbNull Property 297

Inherit Intervals Validation Values ValuesExcluded See Also PostValidation Class | C1.Win.C1Input Namespace

Manages inheritance of the PreValidation properties from the host control properties. Collection of intervals. The input value must belong to one of these intervals. Validation method. Predefined values used for matching the input value. List of values that are not permitted as input value.

PostValidation.AllowDbNull Property
Determines whether it is possible to enter DbNull value in the control. [Visual Basic] Public Property AllowDbNull As Boolean [C#] public bool AllowDbNull {get;set;} [Delphi] public property AllowDbNull: Boolean read get_AllowDbNull write set_AllowDbNull; See Also PostValidation Class | PostValidation Members | C1.Win.C1Input Namespace

PostValidation.CaseSensitive Property
True if string comparisons are case-sensitive; otherwise, False. [Visual Basic] Public Property CaseSensitive As Boolean [C#] public bool CaseSensitive {get;set;} [Delphi] public property CaseSensitive: Boolean read get_CaseSensitive write set_CaseSensitive; See Also PostValidation Class | PostValidation Members | C1.Win.C1Input Namespace

PostValidation.ErrorMessage Property
Error message shown in the standard message box and/or in the exception. [Visual Basic] Public Property ErrorMessage As String

298 C1.Win.C1Input Namespace

[C#] public string ErrorMessage {get;set;} [Delphi] public property ErrorMessage: String read get_ErrorMessage write set_ErrorMessage; See Also PostValidation Class | PostValidation Members | C1.Win.C1Input Namespace

PostValidation.Inherit Property
Manages inheritance of the PreValidation properties from the host control properties. [Visual Basic] Public Property Inherit As PostValidationInheritFlags [C#] public PostValidationInheritFlags Inherit {get;set;} [Delphi] public property Inherit: PostValidationInheritFlags read get_Inherit write set_Inherit; See Also PostValidation Class | PostValidation Members | C1.Win.C1Input Namespace

PostValidation.Intervals Property
Collection of intervals. The input value must belong to one of these intervals. [Visual Basic] Public ReadOnly Property Intervals As ValueIntervalCollection [C#] public ValueIntervalCollection Intervals {get;} [Delphi] public property Intervals: ValueIntervalCollection read get_Intervals; See Also PostValidation Class | PostValidation Members | C1.Win.C1Input Namespace

PostValidation.Validation Property
Validation method. [Visual Basic] Public Property Validation As PostValidationTypeEnum [C#] public PostValidationTypeEnum Validation {get;set;}

PostValidation.Values Property 299

[Delphi] public property Validation: PostValidationTypeEnum read get_Validation write set_Validation; See Also PostValidation Class | PostValidation Members | C1.Win.C1Input Namespace

PostValidation.Values Property
Predefined values used for matching the input value. [Visual Basic] Public Property Values As Array [C#] public Array Values {get;set;} [Delphi] public property Values: Array read get_Values write set_Values; See Also PostValidation Class | PostValidation Members | C1.Win.C1Input Namespace

PostValidation.ValuesExcluded Property
List of values that are not permitted as input value. [Visual Basic] Public Property ValuesExcluded As Array [C#] public Array ValuesExcluded {get;set;} [Delphi] public property ValuesExcluded: Array read get_ValuesExcluded write set_ValuesExcluded; See Also PostValidation Class | PostValidation Members | C1.Win.C1Input Namespace

PostValidation Methods
The methods of the PostValidation class are listed here. For a complete list of PostValidation class members, see the PostValidation Members topic. Public Methods Reset Validate Resets whole PostValidation property of base control Performs validation using the current settings of the PostValidation object. Returns True if validation was successful. Performs validation of the value against the collections of Values, ValuesExcluded and Intervals.

ValidateValuesAndIntervals

300 C1.Win.C1Input Namespace

See Also PostValidation Class | C1.Win.C1Input Namespace

PostValidation.Reset Method
Resets whole PostValidation property of base control [Visual Basic] Public Sub Reset() [C#] public void Reset() [Delphi] public procedure Reset(); See Also PostValidation Class | PostValidation Members | C1.Win.C1Input Namespace

PostValidation.Validate Method
Performs validation using the current settings of the PostValidation object. Returns True if validation was successful. [Visual Basic] Public Function Validate( _ ByVal value As Object, _ ByVal errorInfo As ErrorInfo _ ) As Boolean [C#] public bool Validate( object value, ErrorInfo errorInfo ); [Delphi] public function Validate( value: Object; errorInfo: ErrorInfo ): Boolean; Parameters value The value to validate. errorInfo Error information filled in case of failure. See Also PostValidation Class | PostValidation Members | C1.Win.C1Input Namespace

PostValidation.ValidateValuesAndIntervals Method 301

PostValidation.ValidateValuesAndIntervals Method
Performs validation of the value against the collections of Values, ValuesExcluded and Intervals. [Visual Basic] Public Function ValidateValuesAndIntervals( _ ByVal value As Object, _ ByVal errorInfo As ErrorInfo _ ) As Boolean [C#] public bool ValidateValuesAndIntervals( object value, ErrorInfo errorInfo ); [Delphi] public function ValidateValuesAndIntervals( value: Object; errorInfo: ErrorInfo ): Boolean; Parameters value The value to validate. errorInfo Error information filled in case of failure. See Also PostValidation Class | PostValidation Members | C1.Win.C1Input Namespace

PreValidation Class
Validating the input string entered by the user, before parsing. For a list of all members of this type, see PreValidation Members. System.Object System.MarshalByRefObject C1.Win.C1Input.PreValidation [Visual Basic] Public Class PreValidation InheritsMarshalByRefObjectMarshalByRefObject ImplementsIDisposableIDisposable [C#] public class PreValidation :MarshalByRefObjectMarshalByRefObject ,IDisposableIDisposable

302 C1.Win.C1Input Namespace

[Delphi] type PreValidation = class (MarshalByRefObjectMarshalByRefObject,(MarshalByRefObjectMarshalByRefObjec t,IDisposableIDisposable); Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also PreValidation Members | C1.Win.C1Input Namespace

PreValidation Members
PreValidation overview Public Properties CaseSensitive CustomPlaceholders ErrorMessage Inherit ItemSeparator PatternString RegexOptions TrimEnd TrimStart Validation Public Methods MatchExactList MatchRegex MatchWildcardPattern MatchWildcardPatterns Reset Validate See Also PreValidation Class | C1.Win.C1Input Namespace Returns True if the input text matches one of the exact list items specified in PatternString. Returns True if the input text matches the regular expression pattern specified in PatternString. Returns True if the input text matches the specified wildcard pattern passed as argument. Returns True if the input text matches at least one of the wildcard patterns specified in PatternString. Resets whole PreValidation property of base control Returns True if the text successfully passes validation using the current settings of the PreValidation object. True if string comparisons are case-sensitive; otherwise, False. The collection of user-defined characters to use in a wildcard pattern. Error message shown in the standard message box and/or in the exception. Manages inheritance of the PreValidation properties from the host control properties. String separating list items in PatternString. String containing the validation pattern. Settings affecting regular expression matching. If True, trailing spaces are removed before validation. If True, leading spaces are removed before validation. Validation method.

PreValidation Properties 303

PreValidation Properties
The properties of the PreValidation class are listed here. For a complete list of PreValidation class members, see the PreValidation Members topic. Public Properties CaseSensitive CustomPlaceholders ErrorMessage Inherit ItemSeparator PatternString RegexOptions TrimEnd TrimStart Validation See Also PreValidation Class | C1.Win.C1Input Namespace True if string comparisons are case-sensitive; otherwise, False. The collection of user-defined characters to use in a wildcard pattern. Error message shown in the standard message box and/or in the exception. Manages inheritance of the PreValidation properties from the host control properties. String separating list items in PatternString. String containing the validation pattern. Settings affecting regular expression matching. If True, trailing spaces are removed before validation. If True, leading spaces are removed before validation. Validation method.

PreValidation.CaseSensitive Property
True if string comparisons are case-sensitive; otherwise, False. [Visual Basic] Public Property CaseSensitive As Boolean [C#] public bool CaseSensitive {get;set;} [Delphi] public property CaseSensitive: Boolean read get_CaseSensitive write set_CaseSensitive; See Also PreValidation Class | PreValidation Members | C1.Win.C1Input Namespace

PreValidation.CustomPlaceholders Property
The collection of user-defined characters to use in a wildcard pattern. [Visual Basic] Public ReadOnly Property CustomPlaceholders As PlaceholderCollection [C#] public PlaceholderCollection CustomPlaceholders {get;}

304 C1.Win.C1Input Namespace

[Delphi] public property CustomPlaceholders: PlaceholderCollection read get_CustomPlaceholders; See Also PreValidation Class | PreValidation Members | C1.Win.C1Input Namespace

PreValidation.ErrorMessage Property
Error message shown in the standard message box and/or in the exception. [Visual Basic] Public Property ErrorMessage As String [C#] public string ErrorMessage {get;set;} [Delphi] public property ErrorMessage: String read get_ErrorMessage write set_ErrorMessage; See Also PreValidation Class | PreValidation Members | C1.Win.C1Input Namespace

PreValidation.Inherit Property
Manages inheritance of the PreValidation properties from the host control properties. [Visual Basic] Public Property Inherit As PreValidationInheritFlags [C#] public PreValidationInheritFlags Inherit {get;set;} [Delphi] public property Inherit: PreValidationInheritFlags read get_Inherit write set_Inherit; See Also PreValidation Class | PreValidation Members | C1.Win.C1Input Namespace

PreValidation.ItemSeparator Property
String separating list items in PatternString. [Visual Basic] Public Property ItemSeparator As String [C#] public string ItemSeparator {get;set;} [Delphi] public property ItemSeparator: String read get_ItemSeparator write set_ItemSeparator;

PreValidation.PatternString Property 305

See Also PreValidation Class | PreValidation Members | C1.Win.C1Input Namespace

PreValidation.PatternString Property
String containing the validation pattern. [Visual Basic] Public Property PatternString As String [C#] public string PatternString {get;set;} [Delphi] public property PatternString: String read get_PatternString write set_PatternString; See Also PreValidation Class | PreValidation Members | C1.Win.C1Input Namespace

PreValidation.RegexOptions Property
Settings affecting regular expression matching. [Visual Basic] Public Property RegexOptions As RegexOptionFlags [C#] public RegexOptionFlags RegexOptions {get;set;} [Delphi] public property RegexOptions: RegexOptionFlags read get_RegexOptions write set_RegexOptions; See Also PreValidation Class | PreValidation Members | C1.Win.C1Input Namespace

PreValidation.TrimEnd Property
If True, trailing spaces are removed before validation. [Visual Basic] Public Property TrimEnd As Boolean [C#] public bool TrimEnd {get;set;} [Delphi] public property TrimEnd: Boolean read get_TrimEnd write set_TrimEnd; See Also PreValidation Class | PreValidation Members | C1.Win.C1Input Namespace

306 C1.Win.C1Input Namespace

PreValidation.TrimStart Property
If True, leading spaces are removed before validation. [Visual Basic] Public Property TrimStart As Boolean [C#] public bool TrimStart {get;set;} [Delphi] public property TrimStart: Boolean read get_TrimStart write set_TrimStart; See Also PreValidation Class | PreValidation Members | C1.Win.C1Input Namespace

PreValidation.Validation Property
Validation method. [Visual Basic] Public Property Validation As PreValidationTypeEnum [C#] public PreValidationTypeEnum Validation {get;set;} [Delphi] public property Validation: PreValidationTypeEnum read get_Validation write set_Validation; See Also PreValidation Class | PreValidation Members | C1.Win.C1Input Namespace

PreValidation Methods
The methods of the PreValidation class are listed here. For a complete list of PreValidation class members, see the PreValidation Members topic. Public Methods MatchExactList MatchRegex MatchWildcardPattern MatchWildcardPatterns Reset Validate Returns True if the input text matches one of the exact list items specified in PatternString. Returns True if the input text matches the regular expression pattern specified in PatternString. Returns True if the input text matches the specified wildcard pattern passed as argument. Returns True if the input text matches at least one of the wildcard patterns specified in PatternString. Resets whole PreValidation property of base control Returns True if the text successfully passes validation using the current settings of the PreValidation object.

PreValidation.MatchExactList Method 307

See Also PreValidation Class | C1.Win.C1Input Namespace

PreValidation.MatchExactList Method
Returns True if the input text matches one of the exact list items specified in PatternString. [Visual Basic] Public Function MatchExactList( _ ByVal text As String, _ ByVal errorInfo As ErrorInfo _ ) As Boolean [C#] public bool MatchExactList( string text, ErrorInfo errorInfo ); [Delphi] public function MatchExactList( text: String; errorInfo: ErrorInfo ): Boolean; Parameters text The input string to match. errorInfo Error information filled in case of failure. See Also PreValidation Class | PreValidation Members | C1.Win.C1Input Namespace

PreValidation.MatchRegex Method
Returns True if the input text matches the regular expression pattern specified in PatternString. [Visual Basic] Public Function MatchRegex( _ ByVal text As String, _ ByVal errorInfo As ErrorInfo _ ) As Boolean [C#] public bool MatchRegex( string text, ErrorInfo errorInfo );

308 C1.Win.C1Input Namespace

[Delphi] public function MatchRegex( text: String; errorInfo: ErrorInfo ): Boolean; Parameters text The input string to match. errorInfo Error information filled in case of failure. See Also PreValidation Class | PreValidation Members | C1.Win.C1Input Namespace

PreValidation.MatchWildcardPattern Method
Returns True if the input text matches the specified wildcard pattern passed as argument. [Visual Basic] Public Function MatchWildcardPattern( _ ByVal text As String, _ ByVal pattern As String _ ) As Boolean [C#] public bool MatchWildcardPattern( string text, string pattern ); [Delphi] public function MatchWildcardPattern( text: String; pattern: String ): Boolean; Parameters text The input string to match. pattern The wildcard pattern. See Also PreValidation Class | PreValidation Members | C1.Win.C1Input Namespace

PreValidation.MatchWildcardPatterns Method
Returns True if the input text matches at least one of the wildcard patterns specified in PatternString.

PreValidation.Reset Method 309

[Visual Basic] Public Function MatchWildcardPatterns( _ ByVal text As String, _ ByVal errorInfo As ErrorInfo _ ) As Boolean [C#] public bool MatchWildcardPatterns( string text, ErrorInfo errorInfo ); [Delphi] public function MatchWildcardPatterns( text: String; errorInfo: ErrorInfo ): Boolean; Parameters text The input string to match. errorInfo Error information filled in case of failure. See Also PreValidation Class | PreValidation Members | C1.Win.C1Input Namespace

PreValidation.Reset Method
Resets whole PreValidation property of base control [Visual Basic] Public Sub Reset() [C#] public void Reset() [Delphi] public procedure Reset(); See Also PreValidation Class | PreValidation Members | C1.Win.C1Input Namespace

PreValidation.Validate Method
Returns True if the text successfully passes validation using the current settings of the PreValidation object. [Visual Basic] Public Function Validate( _ ByVal text As String, _ ByVal errorInfo As ErrorInfo _ ) As Boolean

310 C1.Win.C1Input Namespace

[C#] public bool Validate( string text, ErrorInfo errorInfo ); [Delphi] public function Validate( text: String; errorInfo: ErrorInfo ): Boolean; Parameters text The input string to validate. errorInfo Error information filled in case of failure. See Also PreValidation Class | PreValidation Members | C1.Win.C1Input Namespace

UIStrings Class
For a list of all members of this type, see UIStrings Members. System.Object C1.Win.C1Input.UIStrings [Visual Basic] Public Class UIStrings [C#] public class UIStrings [Delphi] type UIStrings = class; Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also UIStrings Members | C1.Win.C1Input Namespace

UIStrings Members
UIStrings overview Public Properties Count Item Returns the number of elements contained in the collection. Gets or sets the string value for the specified key.

UIStrings Properties 311

Public Methods Add AddInOrder GetDescription GetKeyAt GetValueAt IsDefault Reset SetValueAt ShouldSerialize Public Events CollectionChanged ItemAdded ItemChanged See Also UIStrings Class | C1.Win.C1Input Namespace Occurs when the collection has been changed. Occurs when a new item added to the collection. Occurs when an item changed in the collection. Overloaded. Adds a string to the collection, specifying the ordinal. Adds a string to the collection, preserving the order. Returns the item description. Returns the key of an item with the specified index. Gets the string by its index. Returns True if the string is equal to its default value. Overloaded. Sets all strings in collection to their default values. Sets the string by its index. Returns True if there is any non-default string in the collection.

UIStrings Properties
The properties of the UIStrings class are listed here. For a complete list of UIStrings class members, see the UIStrings Members topic. Public Properties Count Item See Also UIStrings Class | C1.Win.C1Input Namespace Returns the number of elements contained in the collection. Gets or sets the string value for the specified key.

UIStrings.Count Property
Returns the number of elements contained in the collection. [Visual Basic] Public ReadOnly Property Count As Integer [C#] public int Count {get;} [Delphi] public property Count: Int32 read get_Count;

312 C1.Win.C1Input Namespace

See Also UIStrings Class | UIStrings Members | C1.Win.C1Input Namespace

UIStrings.Item Property
Gets or sets the string value for the specified key. [Visual Basic] Public Default Property Item( _ ByVal key As Object _ ) As String [C#] public string this[ object key ] {get;set;} [Delphi] public property Item[ key: Object ]: String read get_Item write set_Item; See Also UIStrings Class | UIStrings Members | C1.Win.C1Input Namespace

UIStrings Methods
The methods of the UIStrings class are listed here. For a complete list of UIStrings class members, see the UIStrings Members topic. Public Methods Add AddInOrder GetDescription GetKeyAt GetValueAt IsDefault Reset SetValueAt ShouldSerialize See Also UIStrings Class | C1.Win.C1Input Namespace Overloaded. Adds a string to the collection, specifying the ordinal. Adds a string to the collection, preserving the order. Returns the item description. Returns the key of an item with the specified index. Gets the string by its index. Returns True if the string is equal to its default value. Overloaded. Sets all strings in collection to their default values. Sets the string by its index. Returns True if there is any non-default string in the collection.

UIStrings.Add Method 313

UIStrings.Add Method
Overload List Adds a string to the collection, specifying the ordinal. [Visual Basic] Overloads Public Sub Add(Object, Integer, String, String) [C#] public void Add(object, int, string, string); [Delphi] public procedure Add(Object; Int32; String; String); overload; Adds a string to the collection in alphabetical order. [Visual Basic] Overloads Public Sub Add(Object, String, String) [C#] public void Add(object, string, string); [Delphi] public procedure Add(Object; String; String); overload; See Also UIStrings Class | UIStrings Members | C1.Win.C1Input Namespace

UIStrings.Add Method (Object, Int32, String, String)


Adds a string to the collection, specifying the ordinal. [Visual Basic] Overloads Public Sub Add( _ ByVal key As Object, _ ByVal ordinal As Integer, _ ByVal value As String, _ ByVal description As String _ ) [C#] public void Add( object key, int ordinal, string value, string description ); [Delphi] public procedure Add( key: Object; ordinal: Int32; value: String; description: String ); overload; See Also UIStrings Class | UIStrings Members | C1.Win.C1Input Namespace | UIStrings.Add Overload List

UIStrings.Add Method (Object, String, String)


Adds a string to the collection in alphabetical order.

314 C1.Win.C1Input Namespace

[Visual Basic] Overloads Public Sub Add( _ ByVal key As Object, _ ByVal value As String, _ ByVal description As String _ ) [C#] public void Add( object key, string value, string description ); [Delphi] public procedure Add( key: Object; value: String; description: String ); overload; See Also UIStrings Class | UIStrings Members | C1.Win.C1Input Namespace | UIStrings.Add Overload List

UIStrings.AddInOrder Method
Adds a string to the collection, preserving the order. [Visual Basic] Public Sub AddInOrder( _ ByVal key As Object, _ ByVal value As String, _ ByVal description As String _ ) [C#] public void AddInOrder( object key, string value, string description ); [Delphi] public procedure AddInOrder( key: Object; value: String; description: String ); See Also UIStrings Class | UIStrings Members | C1.Win.C1Input Namespace

UIStrings.GetDescription Method 315

UIStrings.GetDescription Method
Returns the item description. [Visual Basic] Public Function GetDescription( _ ByVal key As Object _ ) As String [C#] public string GetDescription( object key ); [Delphi] public function GetDescription( key: Object ): String; See Also UIStrings Class | UIStrings Members | C1.Win.C1Input Namespace

UIStrings.GetKeyAt Method
Returns the key of an item with the specified index. [Visual Basic] Public Function GetKeyAt( _ ByVal index As Integer _ ) As Object [C#] public object GetKeyAt( int index ); [Delphi] public function GetKeyAt( index: Int32 ): Object; See Also UIStrings Class | UIStrings Members | C1.Win.C1Input Namespace

UIStrings.GetValueAt Method
Gets the string by its index. [Visual Basic] Public Function GetValueAt( _ ByVal index As Integer _ ) As String

316 C1.Win.C1Input Namespace

[C#] public string GetValueAt( int index ); [Delphi] public function GetValueAt( index: Int32 ): String; See Also UIStrings Class | UIStrings Members | C1.Win.C1Input Namespace

UIStrings.IsDefault Method
Returns True if the string is equal to its default value. [Visual Basic] Public Function IsDefault( _ ByVal key As Object _ ) As Boolean [C#] public bool IsDefault( object key ); [Delphi] public function IsDefault( key: Object ): Boolean; See Also UIStrings Class | UIStrings Members | C1.Win.C1Input Namespace

UIStrings.Reset Method
Overload List Sets all strings in collection to their default values. [Visual Basic] Overloads Public Sub Reset() [C#] public void Reset(); [Delphi] public procedure Reset(); overload; Sets the string to its default value. [Visual Basic] Overloads Public Sub Reset(Object) [C#] public void Reset(object); [Delphi] public procedure Reset(Object); overload; See Also UIStrings Class | UIStrings Members | C1.Win.C1Input Namespace

UIStrings.SetValueAt Method 317

UIStrings.Reset Method ()
Sets all strings in collection to their default values. [Visual Basic] Overloads Public Sub Reset() [C#] public void Reset() [Delphi] public procedure Reset(); overload; See Also UIStrings Class | UIStrings Members | C1.Win.C1Input Namespace | UIStrings.Reset Overload List

UIStrings.Reset Method (Object)


Sets the string to its default value. [Visual Basic] Overloads Public Sub Reset( _ ByVal key As Object _ ) [C#] public void Reset( object key ); [Delphi] public procedure Reset( key: Object ); overload; See Also UIStrings Class | UIStrings Members | C1.Win.C1Input Namespace | UIStrings.Reset Overload List

UIStrings.SetValueAt Method
Sets the string by its index. [Visual Basic] Public Sub SetValueAt( _ ByVal index As Integer, _ ByVal value As String _ ) [C#] public void SetValueAt( int index, string value );

318 C1.Win.C1Input Namespace

[Delphi] public procedure SetValueAt( index: Int32; value: String ); See Also UIStrings Class | UIStrings Members | C1.Win.C1Input Namespace

UIStrings.ShouldSerialize Method
Returns True if there is any non-default string in the collection. [Visual Basic] Public Function ShouldSerialize() As Boolean [C#] public bool ShouldSerialize() [Delphi] public function ShouldSerialize(): Boolean; See Also UIStrings Class | UIStrings Members | C1.Win.C1Input Namespace

UIStrings Events
The events of the UIStrings class are listed here. For a complete list of UIStrings class members, see the UIStrings Members topic. Public Events CollectionChanged ItemAdded ItemChanged See Also UIStrings Class | C1.Win.C1Input Namespace Occurs when the collection has been changed. Occurs when a new item added to the collection. Occurs when an item changed in the collection.

UIStrings.CollectionChanged Event
Occurs when the collection has been changed. [Visual Basic] Public Event CollectionChanged AsEventHandlerEventHandler [C#] public eventEventHandlerEventHandler CollectionChanged [Delphi] public property CollectionChanged: EventHandler read remove_CollectionChanged write add_CollectionChanged;

UIStrings.ItemAdded Event 319

See Also UIStrings Class | UIStrings Members | C1.Win.C1Input Namespace

UIStrings.ItemAdded Event
Occurs when a new item added to the collection. [Visual Basic] Public Event ItemAdded AsUIStringsItemEventHandlerUIStringsItemEventHandler [C#] public eventUIStringsItemEventHandlerUIStringsItemEventHandler ItemAdded [Delphi] public property ItemAdded: UIStringsItemEventHandler read remove_ItemAdded write add_ItemAdded; See Also UIStrings Class | UIStrings Members | C1.Win.C1Input Namespace

UIStrings.ItemChanged Event
Occurs when an item changed in the collection. [Visual Basic] Public Event ItemChanged AsUIStringsItemEventHandlerUIStringsItemEventHandler [C#] public eventUIStringsItemEventHandlerUIStringsItemEventHandler ItemChanged [Delphi] public property ItemChanged: UIStringsItemEventHandler read remove_ItemChanged write add_ItemChanged; See Also UIStrings Class | UIStrings Members | C1.Win.C1Input Namespace

UIStringsItemEventArgs Class
For a list of all members of this type, see UIStringsItemEventArgs Members. System.Object System.EventArgs C1.Win.C1Input.UIStringsItemEventArgs [Visual Basic] Public Class UIStringsItemEventArgs InheritsEventArgsEventArgs [C#] public class UIStringsItemEventArgs :EventArgsEventArgs

320 C1.Win.C1Input Namespace

[Delphi] type UIStringsItemEventArgs = class (EventArgsEventArgs);(EventArgsEventArgs); Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also UIStringsItemEventArgs Members | C1.Win.C1Input Namespace

UIStringsItemEventArgs Members
UIStringsItemEventArgs overview Public Properties Description IsDefault Key Value See Also UIStringsItemEventArgs Class | C1.Win.C1Input Namespace The description provided for the item. True if the value is equal to the default string. The key of the item being added or changed. The new string value.

UIStringsItemEventArgs Properties
The properties of the UIStringsItemEventArgs class are listed here. For a complete list of UIStringsItemEventArgs class members, see the UIStringsItemEventArgs Members topic. Public Properties Description IsDefault Key Value See Also UIStringsItemEventArgs Class | C1.Win.C1Input Namespace The description provided for the item. True if the value is equal to the default string. The key of the item being added or changed. The new string value.

UIStringsItemEventArgs.Description Property
The description provided for the item. [Visual Basic] Public ReadOnly Property Description As String [C#] public string Description {get;} [Delphi] public property Description: String read get_Description;

UIStringsItemEventArgs.IsDefault Property 321

See Also UIStringsItemEventArgs Class | UIStringsItemEventArgs Members | C1.Win.C1Input Namespace

UIStringsItemEventArgs.IsDefault Property
True if the value is equal to the default string. [Visual Basic] Public ReadOnly Property IsDefault As Boolean [C#] public bool IsDefault {get;} [Delphi] public property IsDefault: Boolean read get_IsDefault; See Also UIStringsItemEventArgs Class | UIStringsItemEventArgs Members | C1.Win.C1Input Namespace

UIStringsItemEventArgs.Key Property
The key of the item being added or changed. [Visual Basic] Public ReadOnly Property Key As Object [C#] public object Key {get;} [Delphi] public property Key: Object read get_Key; See Also UIStringsItemEventArgs Class | UIStringsItemEventArgs Members | C1.Win.C1Input Namespace

UIStringsItemEventArgs.Value Property
The new string value. [Visual Basic] Public ReadOnly Property Value As String [C#] public string Value {get;} [Delphi] public property Value: String read get_Value; See Also UIStringsItemEventArgs Class | UIStringsItemEventArgs Members | C1.Win.C1Input Namespace

322 C1.Win.C1Input Namespace

ValueInterval Class
An interval in a collection of intervals of possible values used in post-validation. For a list of all members of this type, see ValueInterval Members. System.Object C1.Win.C1Input.ValueInterval [Visual Basic] Public Class ValueInterval ImplementsICloneableICloneable,ISerializableISerializable [C#] public class ValueInterval :ICloneableICloneable,ISerializableISerializable [Delphi] type ValueInterval = class (TObject,(TObject,ICloneableICloneable,ISerializableISerializable); Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also ValueInterval Members | C1.Win.C1Input Namespace

ValueInterval Members
ValueInterval overview Public Properties IncludeMax IncludeMin MaxValue MinValue UseMaxValue UseMinValue See Also ValueInterval Class | C1.Win.C1Input Namespace If True (default), the upper bound is included. If True (default), the lower bound is included. Upper bound. Lower bound. If False (default), the upper bound is positive infinity. If False (default), the lower bound is negative infinity.

ValueInterval Properties
The properties of the ValueInterval class are listed here. For a complete list of ValueInterval class members, see the ValueInterval Members topic.

Public Properties IncludeMax If True (default), the upper bound is included.

ValueInterval.IncludeMax Property 323

IncludeMin MaxValue MinValue UseMaxValue UseMinValue See Also ValueInterval Class | C1.Win.C1Input Namespace

If True (default), the lower bound is included. Upper bound. Lower bound. If False (default), the upper bound is positive infinity. If False (default), the lower bound is negative infinity.

ValueInterval.IncludeMax Property
If True (default), the upper bound is included. [Visual Basic] Public Property IncludeMax As Boolean [C#] public bool IncludeMax {get;set;} [Delphi] public property IncludeMax: Boolean read get_IncludeMax write set_IncludeMax; See Also ValueInterval Class | ValueInterval Members | C1.Win.C1Input Namespace

ValueInterval.IncludeMin Property
If True (default), the lower bound is included. [Visual Basic] Public Property IncludeMin As Boolean [C#] public bool IncludeMin {get;set;} [Delphi] public property IncludeMin: Boolean read get_IncludeMin write set_IncludeMin; See Also ValueInterval Class | ValueInterval Members | C1.Win.C1Input Namespace

ValueInterval.MaxValue Property
Upper bound. [Visual Basic] Public Property MaxValue As Object [C#] public object MaxValue {get;set;}

324 C1.Win.C1Input Namespace

[Delphi] public property MaxValue: Object read get_MaxValue write set_MaxValue; See Also ValueInterval Class | ValueInterval Members | C1.Win.C1Input Namespace

ValueInterval.MinValue Property
Lower bound. [Visual Basic] Public Property MinValue As Object [C#] public object MinValue {get;set;} [Delphi] public property MinValue: Object read get_MinValue write set_MinValue; See Also ValueInterval Class | ValueInterval Members | C1.Win.C1Input Namespace

ValueInterval.UseMaxValue Property
If False (default), the upper bound is positive infinity. [Visual Basic] Public Property UseMaxValue As Boolean [C#] public bool UseMaxValue {get;set;} [Delphi] public property UseMaxValue: Boolean read get_UseMaxValue write set_UseMaxValue; See Also ValueInterval Class | ValueInterval Members | C1.Win.C1Input Namespace

ValueInterval.UseMinValue Property
If False (default), the lower bound is negative infinity. [Visual Basic] Public Property UseMinValue As Boolean [C#] public bool UseMinValue {get;set;} [Delphi] public property UseMinValue: Boolean read get_UseMinValue write set_UseMinValue;

ValueIntervalCollection Class 325

See Also ValueInterval Class | ValueInterval Members | C1.Win.C1Input Namespace

ValueIntervalCollection Class
A collection of ValueInterval objects used by a PostValidation object. The collection is used if the Validation = PostValidationTypeEnum.ValuesAndIntervals or if the user calls the ValidateValuesAndIntervals method. For a list of all members of this type, see ValueIntervalCollection Members. System.Object System.Collections.CollectionBase C1.Win.C1Input.ValueIntervalCollection [Visual Basic] Public Class ValueIntervalCollection InheritsCollectionBaseCollectionBase [C#] public class ValueIntervalCollection :CollectionBaseCollectionBase [Delphi] type ValueIntervalCollection = class (CollectionBaseCollectionBase);(CollectionBaseCollectionBase); Namespace: C1.Win.C1Input Assembly: C1.Win.C1Input.2 (in C1.Win.C1Input.2.dll) See Also ValueIntervalCollection Members | C1.Win.C1Input Namespace

ValueIntervalCollection Members
ValueIntervalCollection overview Public Properties Item Public Methods Add AddRange Contains CopyTo IndexOf Insert Adds a new value interval to the collection. Adds the elements of an array to the end of the collection. Returns True if the collection contains the specific value interval, False otherwise. Copies elements of the collection to an array starting at a particular array index. Determines the index of a specific value interval in the collection, return -1 if this item not found. Inserts a new value interval to the collection at the specified position. Gets the collection element at the specified index.

326 C1.Win.C1Input Namespace

Remove See Also

Removes a specific value interval from the collection.

ValueIntervalCollection Class | C1.Win.C1Input Namespace

ValueIntervalCollection Properties
The properties of the ValueIntervalCollection class are listed here. For a complete list of ValueIntervalCollection class members, see the ValueIntervalCollection Members topic. Public Properties Item See Also ValueIntervalCollection Class | C1.Win.C1Input Namespace Gets the collection element at the specified index.

ValueIntervalCollection.Item Property
Gets the collection element at the specified index. [Visual Basic] Public Default ReadOnly Property Item( _ ByVal index As Integer _ ) As ValueInterval [C#] public ValueInterval this[ int index ] {get;} [Delphi] public property Item[ index: Int32 ]: ValueInterval read get_Item; Parameters index See Also ValueIntervalCollection Class | ValueIntervalCollection Members | C1.Win.C1Input Namespace

ValueIntervalCollection Methods
The methods of the ValueIntervalCollection class are listed here. For a complete list of ValueIntervalCollection class members, see the ValueIntervalCollection Members topic. Public Methods Add AddRange Contains Adds a new value interval to the collection. Adds the elements of an array to the end of the collection. Returns True if the collection contains the specific value interval, False otherwise.

ValueIntervalCollection.Add Method 327

CopyTo IndexOf Insert Remove See Also

Copies elements of the collection to an array starting at a particular array index. Determines the index of a specific value interval in the collection, return -1 if this item not found. Inserts a new value interval to the collection at the specified position. Removes a specific value interval from the collection.

ValueIntervalCollection Class | C1.Win.C1Input Namespace

ValueIntervalCollection.Add Method
Adds a new value interval to the collection. [Visual Basic] Public Sub Add( _ ByVal vi As ValueInterval _ ) [C#] public void Add( ValueInterval vi ); [Delphi] public procedure Add( vi: ValueInterval ); Parameters vi The ValueInterval to add. See Also ValueIntervalCollection Class | ValueIntervalCollection Members | C1.Win.C1Input Namespace

ValueIntervalCollection.AddRange Method
Adds the elements of an array to the end of the collection. [Visual Basic] Public Sub AddRange( _ ByVal c As ValueInterval() _ ) [C#] public void AddRange( ValueInterval[] c );

328 C1.Win.C1Input Namespace

[Delphi] public procedure AddRange( c: ValueInterval() ); Parameters c The array whose elements should be added to the end of the collection. See Also ValueIntervalCollection Class | ValueIntervalCollection Members | C1.Win.C1Input Namespace

ValueIntervalCollection.Contains Method
Returns True if the collection contains the specific value interval, False otherwise. [Visual Basic] Public Function Contains( _ ByVal vi As ValueInterval _ ) As Boolean [C#] public bool Contains( ValueInterval vi ); [Delphi] public function Contains( vi: ValueInterval ): Boolean; Parameters vi The ValueInterval to locate in the collection. See Also ValueIntervalCollection Class | ValueIntervalCollection Members | C1.Win.C1Input Namespace

ValueIntervalCollection.CopyTo Method
Copies elements of the collection to an array starting at a particular array index. [Visual Basic] Public Sub CopyTo( _ ByVal array As ValueInterval(), _ ByVal index As Integer _ ) [C#] public void CopyTo( ValueInterval[] array, int index );

ValueIntervalCollection.IndexOf Method 329

[Delphi] public procedure CopyTo( array: ValueInterval(); index: Int32 ); Parameters array The one-array that is the destination of the elements copied from the collection. index The zero-based index in array at which copying begins. See Also ValueIntervalCollection Class | ValueIntervalCollection Members | C1.Win.C1Input Namespace

ValueIntervalCollection.IndexOf Method
Determines the index of a specific value interval in the collection, return -1 if this item not found. [Visual Basic] Public Function IndexOf( _ ByVal vi As ValueInterval _ ) As Integer [C#] public int IndexOf( ValueInterval vi ); [Delphi] public function IndexOf( vi: ValueInterval ): Int32; Parameters vi The ValueInterval to locate in the collection. See Also ValueIntervalCollection Class | ValueIntervalCollection Members | C1.Win.C1Input Namespace

ValueIntervalCollection.Insert Method
Inserts a new value interval to the collection at the specified position. [Visual Basic] Public Sub Insert( _ ByVal index As Integer, _ ByVal vi As ValueInterval _ )

330 C1.Win.C1Input Namespace

[C#] public void Insert( int index, ValueInterval vi ); [Delphi] public procedure Insert( index: Int32; vi: ValueInterval ); Parameters index The zero-based index at which ValueInterval should be inserted. vi The ValueInterval to insert. See Also ValueIntervalCollection Class | ValueIntervalCollection Members | C1.Win.C1Input Namespace

ValueIntervalCollection.Remove Method
Removes a specific value interval from the collection. [Visual Basic] Public Sub Remove( _ ByVal vi As ValueInterval _ ) [C#] public void Remove( ValueInterval vi ); [Delphi] public procedure Remove( vi: ValueInterval ); Parameters vi The ValueInterval to remove from the collection. See Also ValueIntervalCollection Class | ValueIntervalCollection Members | C1.Win.C1Input Namespace

Index 331

Index
2
2 assembly (C1.Win.C1Input) 109

A
AcceptsEscape property 191 AcceptsTab property 191 Add method 291, 313, 327 Adding event 132 AddInOrder method 314 AddRange method 327 AllowDbNull property 297 AutoChangePosition property 191 AutoTabWhenFilled property 267

B
BeepOnError property 249 BeforeAction event 132 BindingFormatting event 161, 180, 212 BindingParsing event 181, 213 BorderStyle property 121, 192, 243 Bottom property 261 ButtonClick event 133 ButtonCursor property 122, 140 ButtonCursorChanged event 133, 146 ButtonFlatStyle property 276 ButtonImages class 111, 112 about ButtonImages class 111 all members 112 properties 112 ButtonImages.DownImage property 112 ButtonImages.DropImage property 113 ButtonImages.ModalImage property 113 ButtonImages.UpImage property 113 ButtonSize property 122 ButtonStyle property 122 ButtonTextAlign property 123 ButtonTexts property 123 ButtonToolTips property 123 ButtonWidth property 141

C
C1DateEdit class 114 about C1DateEdit class 114 all members 114 events 117 properties 116

C1DateEdit.Calendar property 116 C1DateEdit.FormatType property 117 C1DbNavigator class 118 about C1DbNavigator class 118 all members 118 events 131 methods 130 properties 120 C1DbNavigator.Adding event 132 C1DbNavigator.BeforeAction event 132 C1DbNavigator.BorderStyle property 121 C1DbNavigator.ButtonClick event 133 C1DbNavigator.ButtonCursor property 122 C1DbNavigator.ButtonCursorChanged event 133 C1DbNavigator.ButtonSize property 122 C1DbNavigator.ButtonStyle property 122 C1DbNavigator.ButtonTextAlign property 123 C1DbNavigator.ButtonTexts property 123 C1DbNavigator.ButtonToolTips property 123 C1DbNavigator.CausesFormValidation property 123 C1DbNavigator.ClickButton method 130 C1DbNavigator.ColorButtons property 124 C1DbNavigator.ColorWhenHover property 124 C1DbNavigator.ConfirmDelete property 124 C1DbNavigator.CurrencyManager property 125 C1DbNavigator.DataMember property 125 C1DbNavigator.DataSource property 125 C1DbNavigator.Deleting event 133 C1DbNavigator.Editing event 134 C1DbNavigator.EnabledButtons property 126 C1DbNavigator.Error event 134 C1DbNavigator.ErrorProvider property 126 C1DbNavigator.HorizontalIndent property 126 C1DbNavigator.ImageList property 127 C1DbNavigator.ImageListHighlight property 127 C1DbNavigator.ItemChanged event 134 C1DbNavigator.MoveDelayFirst property 127 C1DbNavigator.MoveDelayNext property 128 C1DbNavigator.PageSize property 128 C1DbNavigator.PositionChanged event 135 C1DbNavigator.PositionVisible property 128 C1DbNavigator.RefreshData event 135 C1DbNavigator.SetDataBinding method 131 C1DbNavigator.ShowToolTips property 128 C1DbNavigator.UIStrings property 129 C1DbNavigator.UpdateData event 136 C1DbNavigator.VerticalAlign property 129 C1DbNavigator.VerticalIndent property 129 C1DbNavigator.VisibleButtons property 130 C1DropDownControl class 136, 137 about C1DropDownControl class 136 all members 137 events 146 methods 145 properties 139 C1DropDownControl.ButtonCursor property 140

332 Index

C1DropDownControl.ButtonCursorChanged event 146 C1DropDownControl.ButtonWidth property 141 C1DropDownControl.CloseDropDown method 145 C1DropDownControl.DefaultDropDownFormClassNa me property 141 C1DropDownControl.DropDownClosed event 147 C1DropDownControl.DropDownForm property 141 C1DropDownControl.DropDownFormAlign property 142 C1DropDownControl.DropDownFormAlignChanged event 147 C1DropDownControl.DropDownFormClassName property 142 C1DropDownControl.DropDownOpened event 147 C1DropDownControl.DroppedDown property 142 C1DropDownControl.GapHeight property 143 C1DropDownControl.InterceptArrowKeys property 143 C1DropDownControl.ModalButtonClick event 148 C1DropDownControl.MouseClickPassThrough property 143 C1DropDownControl.OpenDropDown method 145 C1DropDownControl.ShowDropDownButton property 144 C1DropDownControl.ShowModalButton property 144 C1DropDownControl.ShowUpDownButtons property 144 C1DropDownControl.UpDownButtonClick event 148 C1DropDownControl.VisibleButtons property 144 C1Input hierarchy (C1.Win) 110 C1Input namespace (C1.Win) 109 C1Label class 148, 149 about C1Label class 148 all members 149 events 161 properties 151 C1Label.BindingFormatting event 161 C1Label.CaseSensitive property 153 C1Label.Culture property 153 C1Label.CultureInfo property 153 C1Label.CultureInfoSetup event 161 C1Label.CultureName property 154 C1Label.CurrentTimeZone property 154 C1Label.CustomFormat property 154 C1Label.DataField property 155 C1Label.DataSource property 155 C1Label.DataType property 155 C1Label.DataTypeChanged event 162 C1Label.DaylightTimeAdjustment property 156 C1Label.EmptyAsNull property 156 C1Label.ErrorProvider property 156 C1Label.FormatError event 162 C1Label.FormatInfo property 156 C1Label.Formatted event 162 C1Label.Formatting event 163 C1Label.FormatType property 157

C1Label.GMTOffset property 157 C1Label.MaskInfo property 157 C1Label.NullText property 158 C1Label.Tag property 158 C1Label.TextDetached property 158 C1Label.TrimEnd property 159 C1Label.TrimStart property 159 C1Label.UseFieldStyle property 159 C1Label.UserCultureOverride property 160 C1Label.Value property 160 C1Label.ValueChanged event 163 C1Label.ValueIsDbNull property 160 C1NumericEdit class 163, 164 about C1NumericEdit class 163 all members 164 events 172 methods 172 properties 168 C1NumericEdit.Calculator property 170 C1NumericEdit.DataType property 171 C1NumericEdit.FormatType property 171 C1NumericEdit.Increment property 171 C1PictureBox class 173, 174 about C1PictureBox class 173 all members 174 events 179 methods 177 properties 175 C1PictureBox.BindingFormatting event 180 C1PictureBox.BindingParsing event 181 C1PictureBox.CopyImage method 178 C1PictureBox.DataField property 175 C1PictureBox.DataSource property 176 C1PictureBox.FocusOnClick property 176 C1PictureBox.Image property 176 C1PictureBox.ImageChanged event 182 C1PictureBox.ImageFromByteArray method 178 C1PictureBox.ImageToByteArray method 178 C1PictureBox.ImmediateUpdate property 177 C1PictureBox.PasteImage method 179 C1TextBox class 182, 183 about C1TextBox class 182 all members 183 events 211 methods 207 properties 187 C1TextBox.AcceptsEscape property 191 C1TextBox.AcceptsTab property 191 C1TextBox.AutoChangePosition property 191 C1TextBox.BindingFormatting event 212 C1TextBox.BindingParsing event 213 C1TextBox.BorderStyle property 192 C1TextBox.CaseSensitive property 192 C1TextBox.CausesValidation property 192 C1TextBox.CheckValidationResult method 208 C1TextBox.Culture property 193

Index 333

C1TextBox.CultureInfo property 193 C1TextBox.CultureInfoSetup event 215 C1TextBox.CultureName property 193 C1TextBox.CurrentTimeZone property 193 C1TextBox.CustomFormat property 194 C1TextBox.DataField property 194 C1TextBox.DataSource property 194 C1TextBox.DataType property 195 C1TextBox.DataTypeChanged event 215 C1TextBox.DateTimeInput property 195 C1TextBox.DaylightTimeAdjustment property 195 C1TextBox.DecDateTimeInput method 208 C1TextBox.DisableOnNoData property 196 C1TextBox.DisplayFormat property 196 C1TextBox.EditFormat property 196 C1TextBox.EditMask property 197 C1TextBox.EditMode property 197 C1TextBox.EmptyAsNull property 197 C1TextBox.ErrorInfo property 198 C1TextBox.FormatError event 215 C1TextBox.Formatted event 216 C1TextBox.Formatting event 216 C1TextBox.FormatType property 198 C1TextBox.GMTOffset property 198 C1TextBox.IncDateTimeInput method 209 C1TextBox.InitialSelection property 198 C1TextBox.Label property 199 C1TextBox.Lines property 199 C1TextBox.Margins property 199 C1TextBox.MarginsChanged event 216 C1TextBox.MaskInfo property 200 C1TextBox.MinShortYear property 200 C1TextBox.Modified property 200 C1TextBox.NullText property 201 C1TextBox.NumericInput property 201 C1TextBox.NumericInputKeys property 201 C1TextBox.ParseContent method 209 C1TextBox.Parsed event 217 C1TextBox.ParseInfo property 202 C1TextBox.Parsing event 217 C1TextBox.PostValidated event 217 C1TextBox.PostValidating event 218 C1TextBox.PostValidation property 202 C1TextBox.PreValidated event 218 C1TextBox.PreValidating event 218 C1TextBox.PreValidation property 202 C1TextBox.ResetText method 209 C1TextBox.SelectedText property 203 C1TextBox.SetProposedValue method 210 C1TextBox.ShowContextMenu property 203 C1TextBox.ShowFocusRectangle property 203 C1TextBox.SuspendNumericInput method 210 C1TextBox.Tag property 204 C1TextBox.Text property 204 C1TextBox.TextDetached property 204 C1TextBox.TrimEnd property 204

C1TextBox.TrimStart property 205 C1TextBox.UpdateValueWithCurrentText method 211 C1TextBox.UseColumnStyles property 205 C1TextBox.UserCultureOverride property 205 C1TextBox.ValidationError event 219 C1TextBox.Value property 206 C1TextBox.ValueChanged event 219 C1TextBox.ValueIsDbNull property 206 C1TextBox.VerticalAlign property 206 C1TextBox.VerticalAlignChanged event 220 C1TextBox.WrapDateTimeFields property 207 Calculator property 170 Calendar property 116 CancelChanges event 245 CanLoseFocus property 250 CaseSensitive property 153, 192, 222, 267, 280, 297, 303 CausesFormValidation property 123 CausesValidation property 192 CheckItemBeforeAdding method 292 CheckValidationResult method 208 ClearButtonClick event 227 ClearButtonVisibilityChanged event 227 ClickButton method 130 CloseDropDown method 145, 244 CollectionChanged event 318 ColorButtons property 124 ColorWhenHover property 124 ConfirmDelete property 124 Contains method 292, 328 CopyImage method 178 CopyTo method 292, 328 CopyWithLiterals property 268 Count property 311 Culture property 153, 193 CultureInfo property 153, 193 CultureInfoSetup event 161, 215 CultureName property 154, 193 CurrencyManager property 125 CurrentTimeZone property 154, 193 CustomFormat property 154, 194, 254, 281 CustomPlaceholder class 220, 221 about CustomPlaceholder class 220 all members 221 properties 221 CustomPlaceholder.CaseSensitive property 222 CustomPlaceholder.Excluding property 222 CustomPlaceholder.LookupChars property 222 CustomPlaceholder.Optional property 222 CustomPlaceholder.Placeholder property 223 CustomPlaceholders property 268, 303

D
DataField property 155, 175, 194 DataMember property 125

334 Index

DataSource property 125, 155, 176, 194 DataType property 155, 171, 195 DataTypeChanged event 162, 215 DateEditMonthCalendar class 223, 224 about DateEditMonthCalendar class 223 all members 224 events 227 properties 225 DateEditMonthCalendar.ClearButtonClick event 227 DateEditMonthCalendar.ClearButtonVisibilityChanged event 227 DateEditMonthCalendar.DateValueChanged event 228 DateEditMonthCalendar.DateValueSelected event 228 DateEditMonthCalendar.ShowClearButton property 226 DateEditMonthCalendar.ShowTodayButton property 226 DateEditMonthCalendar.TodayButtonClick event 229 DateEditMonthCalendar.TodayButtonVisibilityChange d event 229 DateEditMonthCalendar.UIStrings property 226 DateTimeInput property 195 DateTimeStyle property 281 DateValueChanged event 228 DateValueSelected event 228 DaylightTimeAdjustment property 156, 195 DecDateTimeInput method 208 DefaultDropDownFormClassName property 141 Deleting event 133 Description property 320 DisableOnNoData property 196 DisplayFormat property 196, 277 DownImage property 112 DropDownAlign property 243 DropDownCalculator class 229, 230 about DropDownCalculator class 229 all members 230 events 233 properties 232 DropDownCalendar class 234 about DropDownCalendar class 234 all members 234 events 237 properties 236 DropDownClosed event 147 DropDownForm class 238, 239 about DropDownForm class 238 all members 239 events 244 methods 244 properties 241 DropDownForm property 141 DropDownForm.BorderStyle property 243 DropDownForm.CancelChanges event 245 DropDownForm.CloseDropDown method 244 DropDownForm.DropDownAlign property 243

DropDownForm.FocusControl property 243 DropDownForm.Open event 246 DropDownForm.Options property 243 DropDownForm.OwnerControlTextChanged event 246 DropDownForm.OwnerControlValueChanged event 246 DropDownForm.PostChanges event 247 DropDownFormAlign property 142 DropDownFormAlignChanged event 147 DropDownFormClassName property 142 DropDownOpened event 147 DropImage property 113 DroppedDown property 142

E
EditFormat property 196 Editing event 134 EditMask property 197, 268 EditMode property 197 EmptyAsNull property 156, 197, 255, 269, 281 EnabledButtons property 126 Error event 134 ErrorAction property 250 ErrorInfo class 248 about ErrorInfo class 248 all members 248 methods 252 properties 249 ErrorInfo property 198 ErrorInfo.BeepOnError property 249 ErrorInfo.CanLoseFocus property 250 ErrorInfo.ErrorAction property 250 ErrorInfo.ErrorMessage property 250 ErrorInfo.ErrorMessageCaption property 251 ErrorInfo.ErrorProvider property 251 ErrorInfo.Reset method 252 ErrorInfo.ShowErrorMessage property 251 ErrorInfo.ValueOnError property 252 ErrorInfo.ValueOnErrorIsDbNull property 252 ErrorMessage property 250, 269, 282, 297, 304 ErrorMessageCaption property 251 ErrorProvider property 126, 156, 251 Excluding property 222

F
FocusControl property 243 FocusOnClick property 176 Format method 257 FormatError event 162, 215 FormatInfo class 253 about FormatInfo class 253 all members 253 methods 256 properties 254

Index 335

FormatInfo property 156 FormatInfo.CustomFormat property 254 FormatInfo.EmptyAsNull property 255 FormatInfo.Format method 257 FormatInfo.FormatType property 255 FormatInfo.Inherit property 255 FormatInfo.NullText property 256 FormatInfo.Reset method 257 FormatInfo.TrimEnd property 256 FormatInfo.TrimStart property 256 FormatOnClose property 277 Formatted event 162, 216 Formatting event 163, 216 FormatType property 117, 157, 171, 198, 255, 282

IsDefault property 321 IsMaskedMode method 274 IsTextDbNull method 284 IsValid method 274 Item property 312, 326 ItemAdded event 319 ItemChanged event 134, 319 ItemSeparator property 304

K
Key property 321

L
Label property 199 Left property 261 Lines property 199 LookupChars property 222

G
GapHeight property 143 GetContent method 272 GetDescription method 315 GetDisplayText method 273 GetItem method 293 GetKeyAt method 315 GetStoredText method 273 GetValueAt method 315 GMTOffset property 157, 198

M
Margins class 260 about Margins class 260 all members 260 methods 262 properties 261 Margins property 199 Margins.Bottom property 261 Margins.Left property 261 Margins.Reset method 263 Margins.Right property 262 Margins.Set method 263 Margins.ShouldSerialize method 264 Margins.Top property 262 MarginsChanged event 216 MaskInfo class 265 about MaskInfo class 265 all members 265 methods 271 properties 266 MaskInfo property 157, 200 MaskInfo.AutoTabWhenFilled property 267 MaskInfo.CaseSensitive property 267 MaskInfo.CopyWithLiterals property 268 MaskInfo.CustomPlaceholders property 268 MaskInfo.EditMask property 268 MaskInfo.EmptyAsNull property 269 MaskInfo.ErrorMessage property 269 MaskInfo.GetContent method 272 MaskInfo.GetDisplayText method 273 MaskInfo.GetStoredText method 273 MaskInfo.Inherit property 269 MaskInfo.IsMaskedMode method 274 MaskInfo.IsValid method 274 MaskInfo.PromptChar property 270

H
HighlightingToolBar class 257, 258 about HighlightingToolBar class 257 all members 258 events 260 properties 259 HorizontalIndent property 126

I
Image property 176 ImageChanged event 182 ImageFromByteArray method 178 ImageList property 127 ImageListHighlight property 127 ImageToByteArray method 178 ImmediateUpdate property 177 IncDateTimeInput method 209 IncludeMax property 323 IncludeMin property 323 Increment property 171 IndexOf method 294, 329 Inherit property 255, 269, 282, 298, 304 InitialSelection property 198 Insert method 294, 329 InterceptArrowKeys property 143 Intervals property 298 IsDefault method 316

336 Index

MaskInfo.Reset method 274 MaskInfo.ResetContent method 275 MaskInfo.SaveBlanks property 270 MaskInfo.SaveLiterals property 270 MaskInfo.ShowLiterals property 270 MaskInfo.SkipOptional property 271 MaskInfo.StoredEmptyChar property 271 MatchExactList method 307 MatchRegex method 307 MatchWildcardPattern method 308 MatchWildcardPatterns method 308 MaxValue property 323 MinShortYear property 200 MinValue property 324 ModalButtonClick event 148 ModalImage property 113 Modified property 200 MouseClickPassThrough property 143 MoveDelayFirst property 127 MoveDelayNext property 128

N
NullText property 158, 201, 256, 283 NumberStyle property 283 NumericEditCalculator class 275, 276 about NumericEditCalculator class 275 all members 276 properties 276 NumericEditCalculator.ButtonFlatStyle property 276 NumericEditCalculator.DisplayFormat property 277 NumericEditCalculator.FormatOnClose property 277 NumericEditCalculator.StoredFormat property 277 NumericEditCalculator.UIStrings property 278 NumericEditCalculator.UseStaticMemory property 278 NumericInput property 201 NumericInputKeys property 201

O
Open event 246 OpenDropDown method 145 Optional property 222 Options property 243 OwnerControlTextChanged event 246 OwnerControlValueChanged event 246

P
PageSize property 128 Parse method 285 ParseBoolean method 286 ParseContent method 209 Parsed event 217 ParseDateTime method 286 ParseFixed method 287

ParseFloat method 288 ParseInfo class 278, 279 about ParseInfo class 278 all members 279 methods 284 properties 280 ParseInfo property 202 ParseInfo.CaseSensitive property 280 ParseInfo.CustomFormat property 281 ParseInfo.DateTimeStyle property 281 ParseInfo.EmptyAsNull property 281 ParseInfo.ErrorMessage property 282 ParseInfo.FormatType property 282 ParseInfo.Inherit property 282 ParseInfo.IsTextDbNull method 284 ParseInfo.NullText property 283 ParseInfo.NumberStyle property 283 ParseInfo.Parse method 285 ParseInfo.ParseBoolean method 286 ParseInfo.ParseDateTime method 286 ParseInfo.ParseFixed method 287 ParseInfo.ParseFloat method 288 ParseInfo.ParseInteger method 289 ParseInfo.Reset method 289 ParseInfo.TrimEnd property 283 ParseInfo.TrimStart property 284 ParseInteger method 289 Parsing event 217 PasteImage method 179 PatternString property 305 Placeholder property 223 PlaceholderCollection class 290 about PlaceholderCollection class 290 all members 290 methods 291 PlaceholderCollection.Add method 291 PlaceholderCollection.CheckItemBeforeAdding method 292 PlaceholderCollection.Contains method 292 PlaceholderCollection.CopyTo method 292 PlaceholderCollection.GetItem method 293 PlaceholderCollection.IndexOf method 294 PlaceholderCollection.Insert method 294 PlaceholderCollection.Remove method 295 PositionChanged event 135 PositionVisible property 128 PostChanges event 247 PostValidated event 217 PostValidating event 218 PostValidation class 295, 296 about PostValidation class 295 all members 296 methods 299 properties 296 PostValidation property 202 PostValidation.AllowDbNull property 297

Index 337

PostValidation.CaseSensitive property 297 PostValidation.ErrorMessage property 297 PostValidation.Inherit property 298 PostValidation.Intervals property 298 PostValidation.Reset method 300 PostValidation.Validate method 300 PostValidation.ValidateValuesAndIntervals method 301 PostValidation.Validation property 298 PostValidation.Values property 299 PostValidation.ValuesExcluded property 299 PreValidated event 218 PreValidating event 218 PreValidation class 301, 302 about PreValidation class 301 all members 302 methods 306 properties 303 PreValidation property 202 PreValidation.CaseSensitive property 303 PreValidation.CustomPlaceholders property 303 PreValidation.ErrorMessage property 304 PreValidation.Inherit property 304 PreValidation.ItemSeparator property 304 PreValidation.MatchExactList method 307 PreValidation.MatchRegex method 307 PreValidation.MatchWildcardPattern method 308 PreValidation.MatchWildcardPatterns method 308 PreValidation.PatternString property 305 PreValidation.RegexOptions property 305 PreValidation.Reset method 309 PreValidation.TrimEnd property 305 PreValidation.TrimStart property 306 PreValidation.Validate method 309 PreValidation.Validation property 306 PromptChar property 270

ShouldSerialize method 264, 318 ShowClearButton property 226 ShowContextMenu property 203 ShowDropDownButton property 144 ShowErrorMessage property 251 ShowFocusRectangle property 203 ShowLiterals property 270 ShowModalButton property 144 ShowTodayButton property 226 ShowToolTips property 128 ShowUpDownButtons property 144 SkipOptional property 271 StoredEmptyChar property 271 StoredFormat property 277 SuspendNumericInput method 210

T
Tag property 158, 204 Text property 204 TextDetached property 158, 204 TodayButtonClick event 229 TodayButtonVisibilityChanged event 229 Top property 262 TrimEnd property 159, 204, 256, 283, 305 TrimStart property 159, 205, 256, 284, 306

U
UIStrings class 310 about UIStrings class 310 all members 310 events 318 methods 312 properties 311 UIStrings property 129, 226, 278 UIStrings.Add method 313 UIStrings.AddInOrder method 314 UIStrings.CollectionChanged event 318 UIStrings.Count property 311 UIStrings.GetDescription method 315 UIStrings.GetKeyAt method 315 UIStrings.GetValueAt method 315 UIStrings.IsDefault method 316 UIStrings.Item property 312 UIStrings.ItemAdded event 319 UIStrings.ItemChanged event 319 UIStrings.Reset method 316 UIStrings.SetValueAt method 317 UIStrings.ShouldSerialize method 318 UIStringsItemEventArgs class 319, 320 about UIStringsItemEventArgs class 319 all members 320 properties 320 UIStringsItemEventArgs.Description property 320 UIStringsItemEventArgs.IsDefault property 321

R
RefreshData event 135 RegexOptions property 305 Remove method 295, 330 Reset method 252, 257, 263, 274, 289, 300, 309, 316 ResetContent method 275 ResetText method 209 Right property 262

S
SaveBlanks property 270 SaveLiterals property 270 SelectedText property 203 Set method 263 SetDataBinding method 131 SetProposedValue method 210 SetValueAt method 317

338 Index

UIStringsItemEventArgs.Key property 321 UIStringsItemEventArgs.Value property 321 UpdateData event 136 UpdateValueWithCurrentText method 211 UpDownButtonClick event 148 UpImage property 113 UseColumnStyles property 205 UseFieldStyle property 159 UseMaxValue property 324 UseMinValue property 324 UserCultureOverride property 160, 205 UseStaticMemory property 278

W
WrapDateTimeFields property 207

V
Validate method 300, 309 ValidateValuesAndIntervals method 301 Validation property 298, 306 ValidationError event 219 Value property 160, 206, 321 ValueChanged event 163, 219 ValueInterval class 322 about ValueInterval class 322 all members 322 properties 322 ValueInterval.IncludeMax property 323 ValueInterval.IncludeMin property 323 ValueInterval.MaxValue property 323 ValueInterval.MinValue property 324 ValueInterval.UseMaxValue property 324 ValueInterval.UseMinValue property 324 ValueIntervalCollection class 325 about ValueIntervalCollection class 325 all members 325 methods 326 properties 326 ValueIntervalCollection.Add method 327 ValueIntervalCollection.AddRange method 327 ValueIntervalCollection.Contains method 328 ValueIntervalCollection.CopyTo method 328 ValueIntervalCollection.IndexOf method 329 ValueIntervalCollection.Insert method 329 ValueIntervalCollection.Item property 326 ValueIntervalCollection.Remove method 330 ValueIsDbNull property 160, 206 ValueOnError property 252 ValueOnErrorIsDbNull property 252 Values property 299 ValuesExcluded property 299 VerticalAlign property 129, 206 VerticalAlignChanged event 220 VerticalIndent property 129 VisibleButtons property 130, 144

S-ar putea să vă placă și