Software informational articles

Corel wordperfect 7 macro encoding case - software


Case study:
A escritoire using Corel WordPerfect 7 is often necessary to carry out calculations and add the ideals into invoices or other documents.

She does this by incoming calculations into also a real calculator and transcribing the answer, or the Microsoft calculator and doubling-up then beating the conclusion into the document. Doing this affects her productivity as this course increases the time taken to absolute work and wastes time in correcting inevitable errors that occur.

A escritoire has asked for software to be in black and white which enables her to do calculations and, if required, alter average information to principles of currency as a down-to-earth act contained by Corel WordPerfect 7.

Feasibility study:
Having analysed the conundrum outlined above this business is ideally appropriate for automation. A blend based on a macro would be advisable to the offered methods in place. The cutback in time and amplified productivity makes the planned approach a convenient and helpful choice to the in progress guide system.

User Requirements:
The user needs to enter calculations into a new or offered article at assorted stages all through the construction of the text. The user also requires that the macro does not alteration the formatting of the certificate in any way.

The user requires the capability to choice the next options for formatting the output: 1) Displaying a sum in banner information or currency.
2) Displaying a sum using a minus sign or brackets to show depressing figures.
3) Non-compulsory use of commas where required.

Applications software to be used: Corel WordPerfect 7.

Purposes of using macro: Calculate the sum of any geometric data one by the user.

Data to be embedded in macro: Any geometric data entered by the user.

Use of macro: Accelerate dealing out of data consequently ever-increasing productivity, by bitter out the bonus keystrokes looked-for to run the answer manually.

A macro that uses the table article in Corel WordPerfect 7 to carry out the necessary arithmetic operations then append the answer in place of a adding up entered as a formula. This blend will take among one to three seconds to absolute any operation, consecutively on a acceptably configured and fully operational classification of the depiction one below.

Design of the system
Taking into consequence the needs of the user and the income free in the execution of the macro in this environment. I have derivative an algorithm that meets all the rations outlined above. The specification for the stand alone programmable classification desirable is as follows:

Typical configurations required:
16 Megabytes of RAM.
Microsoft attuned mouse.
Corel WordPerfect 7.
The macro file.
155 MHZ Pentium processor.
1 Gbyte hard disk aptitude or Windows 98.
Microsoft fitting keyboard.
DOS 6. 0 or better.
Windows 95

Method of input:
Keyboard, arithmetic font or key pad. Capture method: Transfer to clipboard. Input data: Any geometric data entered by the user. Output data: The sum of a computation in arithmetical form.

Method of output: To VDU at the point of input data.

Using this specification I have in print an algorithm that makes effective use of the income obtainable in Corel WordPerfect 7.

Algorithm for applications software macro:
[1] Check for input.
[a] Exit if none found.
[2] Choice formula.
[3] Construct a one cell table.
[4] Add an equals sign already the formula.
[5] Analyze the table.
[6] Verify that consequence is not invade.
[a] Exit if error found (=5+6e).
[7] Ask for user input (formatting).
[a] Exit at user appeal (presses cancel).
[b] Revert operations & clean up.
[8] Arrange the output:
[a] Banner numeric.
[b] Currency.
[c] Use commas.
[d] Use destructive format.
[8] Erase the table leave-taking the answer in place of the first entered formula. Software development

The elucidation to the algorithm affirmed above in the form of a macro that meets all the rations identified in the chemical analysis is as follows:

Macro script:
// Macro: Automath. wcm // On paper in: Absolute Script // Purpose: Compute the sum of arithmetical data // Compiled: 5/09/04 // 1998 Michael Hart //================================================= // Categorize compiler, claim to use Application (A1; "WordPerfect"; Default; "UK")

If (?DocBlank) Clause executed if certificate blank // Go to subroutine oninput go(oninput) endif

// Decide on data block left of insertion point Selectwordprevious () // Circumstance executed if no data found If (?SelectedText="") // Go to subroutine error go(error) endif // Change select data block to a table Tableconvertfrom (type: tabularcolumns!) // Set duck table style TableCellNumberFormat (FormatType: General!) // Turn off Fill in connected charts option Tableupdateassociatedcharts (state: off!) // Addition an equal sign left of data block Type (text: "=") Tablecalculate () // Determine formula ideals in the table

// If formula sentence structure is null go to else If(?CellFormula) // Demonstrate menu dialog box DialogShow(5001;"WordPerfect") // Clause executed if user presses cancel If(MacroDialogResult = 2) // Revert the last operations Undo(1) // Move insertion point to end of data bock PosWordNext () // Go to subroutine end Go(end) Endif

// Circumstance executed if currency is defined If(currency) // Detail arrange data as currency [00. 00] TableCellNumberFormat (FormatType: Currency!) TableCellNumberNegativeNumber (NegDisplayType: Minus!) Endif

// Circumstance executed if negatives defined If(negatives) // Give denial arrange [(9)] Tablecellnumbernegativenumber (negdisplaytype: parentheses!) Endif

// Denote commas are not used TableCellNumberUseCommas (State: No!)

// Clause executed if commas defined If(commas) // Enumerate arrangement data using commas [2,000] TableCellNumberUseCommas (State: Yes!) Endif

// Decide on the table. Tableselecton (selectionmode: table!) // Choice all cells in the contemporary table Selecttable () // Cancel table change stuffing to document Tabledeletetable (delwhat: converttotabs!) // Move insertion point to end of data bock PosWordNext () // Go to subroutine end Go(end) // If formula grammar is unacceptable then Else endif

// Associate the subroutine error Label(error) // Ceremony error communication box in event of null formula MessageBox (; "AUTOMATH Incapable TO COMPLY"; "Invalid data exists in formula. Classification terminated. "; IconStop!) // Erase table change inside to document Tabledeletetable (delwhat: converttotabs!) // Cross out appeal right of the insertion point DeleteCharNext () // Go to subroutine end Go(end)

// Classify subroutine oninput. Label(oninput) // Demonstrate error idea box in event of blank document MessageBox (; "AUTOMATH Incapable TO COMPLY"; "No input provided! Classification terminated. "; IconStop!)

// Categorize the subroutine end Label (end) // End macro Quit //====================================================

Preliminary diagnostics: After consecutively the macro on a coordination of the same specification to that of the approach it is anticipated to be implemented, the preliminary diagnostic tests show the operational time to continue in the range predicted at some point in the analysis.

The subsequent tests were performed to authenticate that the macro meets all of the necessities under real conditions.

Tests to be applied: Test # one of basic macro: 1) Find an being that knows nil about this macro.

2) Celebration of this creature doing the following:

[a] By far using the instructions.

[b] Load Corel WordPerfect 7.

[c] Enter valid arithmetical data.

[d] Approach the macro file.

[e] Run the macro.

[f] Go over steps [c] to [e] using all doable combinations of the options. Ideally, the creature ought to be able to do the above with no assistance.

3) Comment of the macro in a row as anticipated in all conditions.

Basic test conditions: Valid Input: Output: Invalid Input: output: [a] 5-5 0 [a][nothing] Error [b] 2+2 4 [b] qwerty Error [c] 2-4 -2 [c] 2gh+32 Error [d] 100*200 20000 [d] !"$% Error [e] 50/1 50 [e] 1+4-1$ Error [f] 1+2-3*4/5 0. 6 [f] one*two Error [g] 12345 12,345. 00 [g] a1-d3 Error (??)

Test # two of debugged version:

1) Delivery the software on the LINK communiqu? board coordination (run by Legalease) for evaluation by it's users. (the LINK is a exceptional complex for lawyers who often need maths functions in in print work).

2) Amass commentary from the associates agreeable to help.

3) Inspect and instigate any changes or revisions necessary.

Commas act in principles of currency anyway of the settings. This bug has been effectively corrected.

I am the website executive of the Wandle developed museum (http://www. wandle. org). Conventional in 1983 by local citizens to guarantee that the description of the valley was no longer neglected but enhanced awareness its heritage for the use and reimbursement of the community.

Developed by:
home | site map © 2018