Programming Tips for .NetUI

Slides:



Advertisements
Similar presentations
The New User Interface MEDITECH Training & Education.
Advertisements

Benchmark Series Microsoft Access 2010 Level 1
CS0004: Introduction to Programming Visual Studio 2010 and Controls.
Microsoft Word – Lesson 1
COMPUTER PROGRAMMING I Essential Standard 5.02 Understand Breakpoint, Watch Window, and Try And Catch to Find Errors.
Developing an Excel Application
Tutorial 8: Developing an Excel Application
CHAPTER TWO Creating Simple Visual Basic.NET Windows Applications.
A Guide to Oracle9i1 Creating an Integrated Database Application Chapter 8.
Technology Education and Information Design Copyright 2009 MediTech NUI: New User Interface Online Training.
Chapter 2: The Visual Studio.NET Development Environment Visual Basic.NET Programming: From Problem Analysis to Program Design.
EXCEL BASICS WELCOME  TODAY’S CLASS WILL COVER :  Moving Around Excel – CELLS  Highlighting, Editing, Formatting.
How to Get The Most Out of Outlook 2003 Michele Schwartzman Division of Customer Support Summer 2006.
Microsoft Office Word 2013 Core Microsoft Office Word 2013 Core Courseware # 3250 Lesson 8: Using Productivity Tools.
Microsoft Visual Basic 2010: Reloaded Fourth Edition Chapter One An Introduction to Visual Basic 2010.
Visual Basic Chapter 1 Mr. Wangler.
Please Don’t Do That! Common Programming Mistakes Tammy Lonsberry Sr. Programmer/Analyst Sungate Solutions, Inc.
Copyright 2007, Information Builders. Slide 1 Maintain & JavaScript: Two Great Tools that Work Great Together Mark Derwin and Mark Rawls Information Builders.
XP New Perspectives on Microsoft Office Access 2003 Tutorial 11 1 Microsoft Office Access 2003 Tutorial 11 – Using and Writing Visual Basic for Applications.
XP Chapter 7 Succeeding in Business with Microsoft Office Access 2003: A Problem-Solving Approach 1 Enhancing User Interaction Through Programming Chapter.
Copyright 2007, Paradigm Publishing Inc. EXCEL 2007 Chapter 7 BACKNEXTEND 7-1 LINKS TO OBJECTIVES Record & run a macro Record & run a macro Save as a macro-
Enhancing User Interaction Through Programming
Developing Workflows with SharePoint Designer David Coe Application Development Consultant Microsoft Corporation.
Introduction to Visual Basic. Quick Links Windows Application Programming Event-Driven Application Becoming familiar with VB Control Objects Saving and.
IE 411/511: Visual Programming for Industrial Applications
CHAPTER TWO Creating Simple Visual Basic.NET Windows Applications.
Automating Database Processing Chapter 6. Chapter Introduction Design and implement user-friendly menu – Called navigation form Macros – Automate repetitive.
Clearly Visual Basic: Programming with Visual Basic 2008 Chapter 4 I Need a Tour Guide.
1 COMPANY CONFIDENTIAL Model-N Training Session and Q&A.
FireRMS NEMSIS (Part 2) Presented by Laura Small FireRMS Quality Assurance.
 The World Wide Web is a collection of electronic documents linked together like a spider web.  These documents are stored on computers called servers.
1 Lesson 7 Getting Started with Word Essentials Computer Literacy BASICS: A Comprehensive Guide to IC 3, 3 rd Edition Morrison / Wells.
Program Design and Coding
Microsoft Visual Basic 2012 CHAPTER THREE Program Design and Coding.
Microsoft Visual Basic 2010 CHAPTER THREE Program Design and Coding.
University of Sunderland COM 220 Lecture Six Slide 1 Building Interactive Forms Applications using Oracle.
Lesson 11: Looking at Files and Folders what a file or folder is on the computer how to recognize a file or folder on the desktop how to recognize the.
1 Κατανεμημένες Διαδικτυακές Εφαρμογές Πολυμέσων Γιάννης Πετράκης.
Using Microsoft Visual Studio 2005 Original by Suma Rao Revised by John G. McMahon ( 9/6/2008 )
Visual Basic.NET Comprehensive Concepts and Techniques Chapter 8 Debugging, Creating Executable Files, and Distributing a Windows Application.
Copyright 2007, Paradigm Publishing Inc. ACCESS 2007 Chapter 3 BACKNEXTEND 3-1 LINKS TO OBJECTIVES Modify a Table – Add, Delete, Move Fields Modify a Table.
Lesson 2: Manipulating Text Courseware #: 3240
© 2010 Pearson Education, Inc. | Publishing as Prentice Hall1 Computer Literacy for IC 3 Unit 2: Using Productivity Software Chapter 1: Starting with Microsoft.
By Felixberto Dominic B. Eruela.  Using a computer to create, edit, and print documents. Of all computer applications, word processing is the most common.
User Interface Components Lecture # 5 From: interface-elements.html.
Copyright © 2015 Pearson Education, Inc. Publishing as Pearson Addison-Wesley C H A P T E R 13 GUI Programming.
Visual Basic for Application - Microsoft Access 2003 Programming applications using Objects.
What’s New in QAD’s.NET UI? Browse Updates, Guide Me, and more! Stacy Elwood, BravePoint MWUG September 2010.
Lesson 4.  After a table has been created, you may need to modify it. You can make many changes to a table—or other database object—using its property.
Introduction to KE EMu Unit objectives: Introduction to Windows Use the keyboard and mouse Use the desktop Open, move and resize a.
Introduction to KE EMu Unit objectives: Introduction to Windows Use the keyboard and mouse Use the desktop Open, move and resize a.
Overview Find Information quickly and easily Fully customisable Regular (subscriber selected) updates Comprehensive support (7 days)
Microsoft Visual Basic 2008: Reloaded Third Edition Chapter One An Introduction to Visual Basic 2008.
Debugging tools in Flash CIS 126. Debugging Flash provides several tools for testing ActionScript in your SWF files. –The Debugger, lets you find errors.
IE 411/511: Visual Programming for Industrial Applications Lecture Notes #2 Introduction to the Visual Basic Express 2010 Integrated Development Environment.
Banner 6.x Fundamentals: Navigation and Forms. n Name n Organization n Title/function n Job responsibilities n SCT Banner Experience n Expectations Introductions.
Basic Navigation in Oracle R12 BY: Muhammad Irfan.
 2002 Prentice Hall. All rights reserved. 1 Introduction to the Visual Studio.NET IDE Outline Introduction Visual Studio.NET Integrated Development Environment.
Microsoft Visual Basic 2012: Reloaded Fifth Edition Chapter One An Introduction to Visual Basic 2012.
 You won’t write a single line of program code.  Instead, you’ll use visual programming techniques.  Visual Studio processes your actions (such as mouse.
The New User Interface MEDITECH Training & Education.
QAD Browses.
Computer Programming I
DB Implementation: MS Access Forms
Chapter 2 – Introduction to the Visual Studio .NET IDE
CIS16 Application Development Programming with Visual Basic
WEB PROGRAMMING JavaScript.
DB Implementation: MS Access Forms
Manual Water Ski Directory
Chapter 4 Enhancing the Graphical User Interface
Presentation transcript:

Programming Tips for .NetUI Tammy Lonsberry Sr. Programmer/Analyst Sungate Solutions, Inc.

About me Tailoring and customizing Progress 4GL code for QAD users since 1995 Most versions (Mfg/Pro 7.3 – QAD EA 2013 SE) All User Interfaces (CHUI, GUI, Desktop, .NetUI) Progress and Oracle db’s Active PEG member Long time consultant with exposure to many different environments, processes, protocols … and lots of really smart people

Agenda About .NetUI Data Setup Programming Do’s and Don’ts Frame Design Considerations Coding Tips and Common Fixes Summary Questions

About .NetUI

About .NetUI Same 4GL code under the covers Screens get rendered as HTML-style forms

Browser-like navigation Back, Next buttons Toggle/check boxes for logical fields Mouse clicks, not function keys

Seems simple enough, but… More than just a different look or screen appearance CHUI: Tightly integrated and responsive to keyboard events .NetUI: Stateless, no interaction at the field navigation or keystroke level .NetUI can detect (and therefore respond to) frame events and database events Can: Next button - end of frame or update statement Cannot: Tab, function keys, other navigational keystrokes

Data Setup

Data setup specific to the UI 36.3.21.1 Program Information Maintenance Determines which method will be used to display your program

Same program, before & after Without any code changes

Programming Do’s and Don’ts

Programming Do’s and Don’ts Not an all-inclusive list, but possibly the most common Biggest offenders; program code that must be changed Without these changes: Program may not function properly or at all Screen may not be displayed correctly or completely Program may hang or crash with no error visible to the user

Do not use; not visible in .NetUI Pause User will not see “Press spare bar to continue” “Processing….” and program appears to hang Can use “pause 0” but not “pause 0 before hide” QAD STD-0039 Can use gpwait.i to pause for display-only frames QAD STD-0300 Help phrase Can display informational text on the screen … more on that later

Do not use; not visible in .NetUI Validate phrase Wrong: Right: update part validate (can-find (pt_mstr where pt_domain = global_domain and pt_part = part), “Item Number does not exist”) with frame a. update part with frame a. if not can-find(pt_mstr where pt_domain = global_domain and pt_part = part) then do: /*ITEM NUMBER DOES NOT EXIST*/ {pxmsg.i &MSGNUM=16 &ERRORLEVEL=3} undo, retry. end.

Messages Do not use Progress “message” statement Do not use Alert-box Do not use mfmsg.i or its variations (mfmsg01.i, mfmsg02.i, etc) Do not use hard-coded message text Always use pxmsg.i (QAD STD-0277) {pxmsg.i &MSGNUM=123 &ERRORLEVEL=3} Always use msg_mstr

Field Lookups Do not use scrolling windows Ex: window.i, sw*.i Do use browses and lookups as created by Browse Maintenance (36.20.13) Browse Maintenance is entirely new in .NetUI Do not use 36.20.13 in Chui – always use the .NetUI version Browses can be developed on one database, exported and imported into other db’s Browse export/import will include supporting data Labels, Program Info, etc.

Keyboard actions Keystrokes and other cursor movement is not detectable in .NetUI Program logic cannot be based on keystrokes or frame fields Do not use: Keycode, Keyfunction Cursor-left, cursor-right, cursor-up, cursor-down Status default, ststatus Hard-coded “F4” or other keys Can use database trigger events On assign, create, write, etc.

Frame Design Considerations

Frame considerations Text displayed in frame statements will not appear in .NetUI Field labels will be displayed but not other informational or hard-coded text Watch for “no-label” phrase – this may indicate a frame made entirely of text.

Sample frame – classic CHUI

Sample frame code form skip(1) "Here is some informational text" at 3 code colon 11 code1 colon 46 label {t001.i} name colon 11 name1 colon 46 label {t001.i} sort-by colon 20 format '9' "1) Customer Number" at 26 "2) Customer Name" at 26 skip with frame a side-labels width 80.

Result before code change Text is missing

To display text: Step 1 Define character variables They will be used to store the text define variable form-text1 as char no-undo. define variable form-text2 as char no-undo. define variable form-text3 as char no-undo.  

To display text: Step 2 Place the variables in the frame form skip(1) form-text1 at 3 format 'x(40)' no-label code colon 11 code1 colon 46 label {t001.i} name colon 11 name1 colon 46 label {t001.i} sort-by colon 20 format '9' form-text2 at 26 format 'x(20)' no-label form-text3 at 26 format 'x(20)' no-label skip with frame a side-labels width 80.

To display text: Step 3 Assign text to the variables form-text1 = "Here is some informational text" form-text2 = "1) Customer Number" form-text3 = "2) Customer Name" . Can also use Label Master or Master Comments to store frame text. Allows for language translation.

To display text: Step 4 Display variables with frame a display form-text1 form-text2 form-text3 with frame a.

Result after code change

Coding Tips and Common Fixes

Determining the run-time mode {gpiswrap.i} Returns a logical True = .NetUI mode False = Terminal/CHUI mode if {gpiswrap.i} then do: /* Some code here for .Net UI */ end. else do: /* Running in Terminal Mode */

“Quick List” for common fixes To update your existing CHUI custom code and enable for .NetUI, search for these commonly used words These aren’t all indicative of a problem, but will give you a quick jump-start towards finding possible offenders Alert-box Cursor F2, F4 Frame Help Keycode Keyfunction Label Message mfmsg Pause Validate

Follow QAD’s coding style 3 types of programs; very specific structure & flow of control Maintenance, Inquiry, Report Follow the recommended program structure for consistent behavior Utilize standard .i include files as much as possible K.I.S.S. – don’t reinvent the wheel or get needlessly “creative”

http://www.qad.com/erp/Support/ Get a login, it’s free! Click on: General Reference Development Standards Review these periodically – refreshers are good; we all forget things over time 

Summary

Summary Write code for application functionality, not the user’s keystrokes 36.3.21.1 Program Information Maintenance Use “Quick List” for quick conversion of existing custom code Use QAD’s development standards As the application has evolved, it has continually become more and more important to follow these rules Follow the “When in Rome” principle

Questions?

Contact information For further information or a copy of this presentation: Tammy Lonsberry (847) 628-4796 tlonsberry@sungate-solutions.com