CitraTest advanced OCR for automated testing - select, verify, and read dynamic UI text when bitmaps alone are not enough.
Direct answer: Object-tree selectors and static bitmaps both hit walls when the screen shows values that change every run. CitraTest® automates from the glass with real mouse and keyboard, syncs with WaitForImage, and uses Advanced OCR to click, verify, and read dynamic text that cannot be a baseline bitmap. Same visual model for functional automation, CitraTest APM, and CitraTest VU.
Enterprise UI automation still splits into two brittle habits. One side chases DOM, accessibility trees, or proprietary object models - until Citrix HDX, RDS, a thick client, or an emulator paints pixels with no useful tree. The other side captures only static bitmaps - until the order number, patient MRN, list item, or confirmation string is different every playback.
Neither habit matches how a real user works. A user sees the desktop, waits for the next screen, clicks the right label, and reads the result. That is the CitraTest model: visual cues (bitmap images + OCR text recognition) plus real mouse and keyboard actions on any Windows desktop presentation of the application.
The problem: selectors and bitmap-only scripts both fail on dynamic text
Object-based tools assume a stable control hierarchy. Pixel-delivery paths (Citrix, Microsoft RDS / RemoteApp, AVD, many legacy terminals) do not expose that hierarchy to the client. Bitmap-only scripts fix the "no object tree" problem for static icons and buttons, but they cannot represent tomorrow's invoice ID or a CSV-driven list selection as a fixed .bmp.
How CitraTest uses images and OCR together
Per the CitraTest Quick Start ("How CitraTest Uses Images and OCR") and User Guide guidance:
- ClickOnImage replicates end-user mouse clicks on icons, buttons, menus, and other visual targets.
- WaitForImage synchronizes and verifies expected application responses before the script continues.
- OCR selects, validates, and reads dynamic text that cannot be predefined as a baseline bitmap.
- StartTimer / StopTimer measure on-screen response between initiating an action and confirming completion (typically after WaitForImage).
Architecture-agnostic coverage on a Windows desktop includes local thick clients, any browser, applications via Citrix and Remote Desktop Services, and Windows desktop emulator clients (mainframe, Linux, and similar). Scripts see what the user sees.
Product guidance is explicit: prefer bitmaps when text is static; reserve OCR for values that are unknown ahead of time. OCR is a precision tool for dynamic fields - not a substitute for image sync.
Advanced OCR capabilities (grounded in product docs)
Release Notes and User Guide notes distinguish OCR layers so sales and engineering do not conflate them:
| Layer | Role (documented) |
| Classic OCR | Font-set based path; later extended for smoothed fonts and color tables. Still relevant for older scripts. |
| Advanced / Enhanced OCR (optional add-on from Rel Notes [871b1]) | ClickOnTextOCR, VerifyTextOCR, ReadTextOCR - no need for predefined font sets; documented support for standard, grey-scale smoothed, and ClearType text. |
| Basic OCR (Rel Notes [880a1]) | Packaged basic engine relative to optional Advanced OCR for supported VB script eras. |
| VU OCR Engine (Rel Notes [878a1]) | Shared CitraTestVUOCREngine on the VU load server for concurrent sessions, with image caching. |
Concrete Advanced OCR script actions (User Guide / Quick Start text-function model):
- Click / select -
ClickOnText / ClickOnTextOCR for unknown or dynamic strings (for example a script input parameter that changes per run).
- Verify -
VerifyText / VerifyTextOCR to assert an expected string in a field (parameter-driven or produced by earlier steps).
- Read / extract -
ReadText / ReadTextOCR (and related line/space helpers) into TextRead* results for reporting or downstream script logic.
Advanced OCR options documented in User Guide notes include engine thresholds, character-class filters (INCLUDE_ALPHAS / NUMERICS / MISC), and case match. Search areas (fixed, relative, or advanced) limit image and OCR focus; advanced areas can combine image and/or OCR text anchors for grids and fields that move or resize. Optional OCR cache (OCRParameters.UseCache) can reuse prior processing for repeated regions. Textbox utilities (VerifyTextBoxText / ReadTextBoxText) cover some cases without OCR when appropriate.
Tevron has shipped proprietary OCR as part of the CitraTest story since early product releases (including the 2001 CitraTest 3.0 OCR announcement on tevron.com news archives): read text, evaluate text, and click text strings while remaining a client-side, non-invasive approach that does not modify the OS of the system under test.
Where Advanced OCR helps in automated testing
- Data-driven functional and regression scripts - The installed Advanced Tutorial (Customer Tracker) pattern uses external CSV input plus OCR text functions to verify dynamic results. Static Account Tracker-style tutorials stay on bitmaps; advanced paths add OCR when results vary.
- Citrix / RDS / VDI / published apps - When the client only receives pixels, OCR plus images is how you select list items and assert field values the way a user would.
- Browsers and thick clients on the same license story - One glass model across delivery modes reduces "different tool per channel" drift.
- Forms, grids, and PDF field work - Documented wizards use text anchors, search areas, regex, and optional OCR (including PDF field read/set paths that do not require displaying the PDF GUI).
- APM and VU reuse - The same class of glass script can move from IDE playback to scheduled APM monitoring and to VU load. Under VU, OCR is consolidated through the load-server OCR engine so concurrent sessions share OCR work and can skip duplicate regions via cache.
Operational rules that keep OCR reliable
These are product rules, not slogans:
- Sync with images first. Under VU OCR, function calls do not use a timeout as a wait: a text-area bitmap is sent once and the result returned. Do not treat OCR as WaitForImage. Confirm the application is ready with image functions, then OCR.
- No full-screen OCR and no OCR-based Advanced Areas on the VU OCR path. Keep text areas within engine max height/width settings.
- Prefer static bitmaps for unchanging cues; OCR only for dynamic values.
- Where practical, reduce font-smoothing / ClearType inconsistency for classic OCR paths; Advanced OCR is documented as ClearType-capable - still design tight search areas.
- Place StartTimer immediately after the initiating action and StopTimer after WaitForImage (or equivalent image confirmation) proves the on-screen moment of truth - then use OCR to read or assert dynamic content if needed.
Related reading: The Front Door Is Not the Farm (glass-level VU and VU OCR callout), What is CitraTest VU?, Director Watches Brokers. APM Watches the Screen.
Closing: automate what the user can read
Advanced OCR does not replace on-the-glass image automation. It completes it. Bitmaps tell the script the screen is ready. Advanced OCR tells the script what the changing text says - so data-driven clicks, verifications, and extractions stay honest on Citrix, RDS, browsers, and thick clients alike.
Build functional coverage that way, then reuse the same visual definition of success in APM and VU. That is how automated testing stays aligned with real end-user experience instead of inventing a parallel object universe.
FAQ
When should automated tests use OCR instead of bitmap images?
Prefer bitmap images when the UI cue is static and can be captured as a baseline. Use CitraTest OCR when the selection, verification string, or result is dynamic and cannot be predefined as a static bitmap.
What can CitraTest Advanced OCR do in a script?
Advanced OCR APIs such as ClickOnTextOCR, VerifyTextOCR, and ReadTextOCR let scripts click, assert, and extract dynamic on-screen text. Search areas (fixed, relative, or advanced) limit where OCR looks.
Can OCR be used as a wait or sync under CitraTest VU load?
No. Under the VU OCR Engine path, OCR calls are not wait/sync points. Confirm readiness with image functions first (WaitForImage, ClickOnImage), then call OCR.
Does CitraTest OCR work for Citrix, RDS, and browsers?
Yes. CitraTest follows visual cues on the Windows desktop - thick clients, any browser, Citrix and Remote Desktop Services, and emulator clients - using real mouse and keyboard plus images and OCR.
How does OCR relate to CitraTest APM and VU?
The same glass scripting model - images for sync, OCR for dynamic text, timers for response - can be used in functional automation, scheduled APM monitoring, and VU load. VU consolidates OCR through CitraTestVUOCREngine on the load server with image caching.
Contact Tevron
Tevron LLC
402 Amherst Street, Nashua, NH 03060
Phone: 866.788.3650
Email: sales@tevron.com
Web: www.tevron.com
Product: CitraTest - automated testing · CitraTest VU · CitraTest APM
Citrix, HDX, Microsoft, Remote Desktop Services, Azure Virtual Desktop, and related marks are trademarks of their respective owners. Tevron is not affiliated with Citrix or Microsoft. Names are used for identification only. CitraTest®, CitraTest VU®, and CitraTest APM® are Tevron products.