Alternatives To Custom Dialog Box

Similar documents
IFA/QFN VBA Tutorial Notes prepared by Keith Wong

Excel & Visual Basic for Applications (VBA)

Agenda. First Example 24/09/2009 INTRODUCTION TO VBA PROGRAMMING. First Example. The world s simplest calculator...

MICROSOFT EXCEL 2000 LEVEL 5 VBA PROGRAMMING INTRODUCTION

Contents. Some Basics Simple VBA Procedure (Macro) To Execute The Procedure Recording A Macro About Macro Recorder VBA Objects Reference

Work more efficiently by learning how to automate recurring tasks and create user applications

variables programming statements

MS Excel VBA Class Goals

Excel Formulas & Functions I CS101

Training Guide. Microsoft Excel 2010 Advanced 1 Using Conditional and Custom Formats. Applying Conditional Formatting

Excel Macro Record and VBA Editor. Presented by Wayne Wilmeth

Understanding the MsgBox command in Visual Basic

Introduction... 1 Part I: Getting Started with Excel VBA Programming Part II: How VBA Works with Excel... 31

3 IN THIS CHAPTER. Understanding Program Variables

Click File on the menu bar to view the individual menu items and their associated icons on the File menu.

Configuring Microsoft Outlook to Connect to Hosted Exchange Service

Topic 4D: Import and Export Contacts

Delivering training since 1996

Microsoft Access 2010

Microsoft Access 2013

Microsoft Access 2013

Using Templates. 5.4 Using Templates

Oracle SQL. murach s. and PL/SQL TRAINING & REFERENCE. (Chapter 2)

BRIEFCASES & TASKS ZIMBRA. Briefcase can be used to share and manage documents. Documents can be shared, edited, and created using Briefcases.

Creating If/Then/Else Routines

3. (1.0 point) To quickly switch to the Visual Basic Editor, press on your keyboard. a. Esc + F1 b. Ctrl + F7 c. Alt + F11 d.

DOWNLOAD PDF EXCEL MACRO TO PRINT WORKSHEET TO

Viewing Attachments in GroupWise on a Macintosh FAQ

This is the preferred method when combining documents that are finished and not expected to change.

Sort, Filter, Pivot Table

1. Introduction Features Operating Environment Machine Data...6

Outline. Midterm Review. Using Excel. Midterm Review: Excel Basics. Using VBA. Sample Exam Question. Midterm Review April 4, 2014

Quick Reference Guide: SAP CONNECT

Excel VLOOKUP. An EMIS Coordinator s Friend

A Back-End Link Checker for Your Access Database

Tutorial 3 - Performing a Change-Point Analysis in Excel

Microsoft Access 2010

SMART Recorder. Record. Pause. Stop

MgtOp 470 Business Modeling with Spreadsheets Sample Midterm Exam. 1. Spreadsheets are known as the of business analysis.

MICROSOFT EXCEL VISUAL BASIC FOR APPLICATIONS INTERMEDIATE

Phone NTP Reference Configuration

The American University in Cairo. Academic Computing Services. Excel prepared by. Maha Amer

Excel for Engineers Part 2

To complete this database, you will need the following file:

Microsoft Office Outlook 2007: Intermediate Course 01 Customizing Outlook

Excel QuickGuide 1 The AVERAGE Function

Excel Reports: Formulas or PivotTables

Microsoft Excel 2007

PowerScheduler Course Tally Worksheet instructions.

Microsoft Access 2013

UNIT ONE: The Worksheet. Workbook Window Excel Worksheet Fill handle Automatic fill Column widths Opening a file Saving a file

MODULE VI: MORE FUNCTIONS

Dealing with Event Viewer

USING the IEDATA add-in FROM THE SPREADSHEET MENU

IFA/QFN VBA Tutorial Notes prepared by Keith Wong

Copyright. Trademarks Attachmate Corporation. All rights reserved. USA Patents Pending. WRQ ReflectionVisual Basic User Guide

Read Me First (Excel 2007)

Accessing Help You can access Help by using the drop-down Options menu, or by pressing F1 from within any field on any screen to launch a helpfile.

Creating a Dynamo with VBA Scripts

Quick Reference Guide SharePoint Quick Reference Guide

Exchange Address Book Order

Server Manager User and Permissions Setup

Excel Working with Formulas and Functions. Using Relative References. Engineering Staff College of India

Enterprise Architect. User Guide Series. Model Wizard

Corporate essentials

BASIC MACROINSTRUCTIONS (MACROS)

Introduction to Microsoft Access 2016

Intermediate Excel 2016

Ms Excel Vba Continue Loop Through Worksheets By Name

Recommended GUI Design Standards

Excel The primary replacement for menus and toolbars in Office Excel 2007 is the Ribbon. Designed for easy browsing, the

Getting Started with IBM Cognos 10 Reports

Unit 23 Creating Conditional Content

Upgrading your QuickBooks Company File Once per file only

DATABASE AUTOMATION USING VBA (ADVANCED MICROSOFT ACCESS, X405.6)

AlignSizeSpaceRow GMS For CorelDRAW Installation, Setup and Usage Document

Computer Basics. Logging onto Windows

VBA Collections A Group of Similar Objects that Share Common Properties, Methods and

Generating a Custom Bill of Materials

Microsoft OneDrive. How to login to OneDrive:

Hiding or Discarding Insignificant Rows in a Report Template

Phone NTP Reference Configuration

MICROSOFT ONEDRIVE FOR WINDOWS

Microsoft Excel Lookup Functions - Reference Guide

Working with Basic Functions. Basic Functions. Excel 2010 Working with Basic Functions. The Parts of a Function. Page 1

Use PrimoPDF To Print Jobs That Include Attached External Documents (PowerDB Version or later)

Excel 2016: Formulas & Functions

Starting Kidspiration. To start Kidspiration on a Macintosh: Open the Kidspiration 3 folder and double-click the Kidspiration icon.

The QuickCalc BASIC User Interface

Completing Baseline s Site Survey Request Form

Formulas, LookUp Tables and PivotTables Prepared for Aero Controlex

Formulas and Functions

Become strong in Excel (2.0) - 5 Tips To Rock A Spreadsheet!

IDENTIFYING UNIQUE VALUES IN AN ARRAY OR RANGE (VBA)

Microsoft How to Series

Excel Tip: How to sum a column based on multiple conditions or criteria in other columns

CHEMICAL SAFETY EMS SOFTWARE. Accumulation Inventory

Creating Visual Basic Macros that Use Microsoft Excel Solver

MAILMERGE WORD MESSAGES

An InputBox( ) function will display an input Box window where the user can enter a value or a text. The format is

Transcription:

Alternatives To Custom Dialog Box

Contents VBA Input Box Syntax & Function The Excel InputBox method Syntax The VBA MsgBox Function The Excel GetOpenFilename Method The Excel GetSaveAsFilename Method Reference

VBA Input Box An input box is a simple dialog box that allows the user to make a single entry. For example, you can use an input box to let the user enter text or a number or even select a range. You can generate an InputBox in two ways: by using a VBA function and by using a method of the Application object.

Syntax & Function InputBox(prompt[,title][,default][,xpos][,ypos][, helpfile, context]) prompt: Required. The text displayed in the InputBox. title: Optional. The caption of the InputBox window. default: Optional. The default value to be displayed in the dialog box. xpos, ypos: Optional. The screen coordinates of the upper-left corner of the window. helpfile, context: Optional. The help file and help topic. The InputBox function prompts the user for a single piece of information. The function always returns a string, so your code may need to convert the results to a value.

The Excel InputBox method Advantages of Excel InputBox over VBA s InputBox: You can specify the data type returned. The user can specify a worksheet range by dragging in the worksheet. Input validation is performed automatically.

Syntax InputBox(Prompt[,Title][,Default][,Left][,To p][,helpfile, HelpContextID][,Type]) Prompt: Required. The text displayed in the input box. Title: Optional. The caption in the input box window. Default: Optional. The default value to be returned by the function if the user enters nothing. Left, Top: Optional. The screen coordinates of the upper-left corner of the window. HelpFile, HelpContextID: Optional. The Help file and Help topic. Type: Optional. A code for the data type returned

The VBA MsgBox Function VBA s MsgBox function is an easy way to display a message to the user or to get a simple response (such as OK or Cancel). Syntax:MsgBox(prompt[,buttons][,title][,helpfil e, context]) prompt: Required. The text displayed in the message box. buttons: Optional. A numeric expression that determines which buttons and icon are displayed in the message box. title: Optional. The caption in the message box window. helpfile, context: Optional. The helpfile and Help topic.

The Excel GetOpenFilename Method If your application needs to ask the user for a filename, you can use the InputBox function. But this approach is tedious and error-prone because the user must type the filename (with no browsing ability). A better approach is to use the GetOpenFilename method of the Application object, which ensures that your application gets a valid filename (as well as its complete path). Syntax: ApplicationGetOpenFilename(FileFilter, FilterIndex, Title, ButtonText, MultiSelect) FileFilter: Optional. A string specifying file-filtering criteria. FilterIndex: Optional. The index number of the default file-filtering criteria. Title: Optional. The title of the dialog box. If omitted, the title is Open. ButtonText: For Macintosh only. MultiSelect: Optional. If True, you can select multiple filenames. The default value is False.

The Excel GetSaveAsFilename Method The GetSaveAsFilename method is very similar to the GetOpenFilename method. It displays a Save As dialog box and lets the user select (or specify) a file. It returns a filename and path but doesn t take any action. Like the GetOpenFilename method, all of the GetSaveAsFilename method s arguments are optional. Syntax:Application.GetSaveAsFilename(InitialFilena me, FileFilter, FilterIndex, Title, ButtonText) The arguments are: InitialFilename: Optional. Specifies the suggested filename. FileFilter: Optional. A string specifying file-filtering criteria. FilterIndex: Optional. The index number of the default filefiltering criteria. Title: Optional. The title of the dialog box. ButtonText: For Macintosh only.

Reference Excel 2010 Power Programming with VBA by John Walkenbach.

THANK YOU