{"title":"TestAction.Invoke() Method","url":"https://jonas-paprotka.de/docs/dev-itpro/developer/methods-auto/testaction/testaction-invoke-method/","by":"JOP-AL","license":"Copyright (c) Microsoft Corporation. CC BY 4.0, https://creativecommons.org/licenses/by/4.0/; code samples MIT. From https://learn.microsoft.com/en-us/dynamics365/business-central/dev-itpro/developer/methods-auto/testaction/testaction-invoke-method, MicrosoftDocs/dynamics365smb-devitpro-pb at 828b6ee (2026-11-19). Changed: includes filled in, links to this site, and for agents shortened without dropping a fact.","credit":"Microsoft Corporation, CC BY 4.0","origin":"https://learn.microsoft.com/en-us/dynamics365/business-central/dev-itpro/developer/methods-auto/testaction/testaction-invoke-method","source":{"name":"Business Central developer and IT pro docs","repo":"https://github.com/MicrosoftDocs/dynamics365smb-devitpro-pb","commit":"828b6ee72fcd75755627cd6011f3d20899217ab2","date":"2026-11-19"},"checked":"2026-11-19","description":"Invokes an action on a test page.","date":"2026-10-01","meta":{"topic":"reference"},"outline":[{"level":2,"title":"Syntax","slug":"syntax","at":94,"chars":41},{"level":2,"title":"Parameters","slug":"parameters","at":135,"chars":103},{"level":2,"title":"Remarks","slug":"remarks","at":238,"chars":91},{"level":2,"title":"Example","slug":"example","at":329,"chars":316},{"level":2,"title":"Related information","slug":"related-information","at":645,"chars":169}],"text":"> Version: _Available or changed with runtime version 1.0._\nInvokes an action on a test page.\n## Syntax\n```al\n TestAction.Invoke()\n```\n## Parameters\nTestAction\nType: testaction-data-type\nAn instance of the testaction-data-type data type.\n## Remarks\nAll actions that are available on the page are also available on the test page.\n## Example\n```\nvar\n    InvtDocumentHeader: Record \"Invt. Document Header\";\n    InvtShipment: TestPage \"Invt. Shipment\";\nbegin\n    // Open Item Shipment page\n    InvtShipment.OpenEdit;\n    InvtShipment.GotoRecord(InvtDocumentHeader);\n\n    // Push \"Print\" on the page ribbon.\n    InvtShipment.Print.Invoke();\nend;\n```\n## Related information\ntestaction-data-type\n../testpage/testpage-no-method\nGet Started with AL<../../devenv-get-started>\nDeveloping Extensions<../../devenv-dev-overview>"}