Skip to main content

Notifications

Announcements

No record found.

Business Central forum
Answered

What is property access syntax?

Posted on by 2
The note /This method can be invoked using property access syntax/ appears on many pages in the Business Central for files found in the BC Dev Documentation.
 
What does it mean? 
 
What is property access syntax?
 
What other ways can methods be invoked?
 
What are examples on methods that cannot be invoked using property access syntax?
 
What is the point of this note?
 
 
 
Categories:
  • Verified answer
    Judy Profile Picture
    Judy Microsoft Employee on at
    What is property access syntax?
    Hi,
     
    When it is mentioned that a method can be invoked using property access syntax, it means that the method can be called or accessed using the syntax typically used for accessing properties. Instead of using traditional method invocation syntax with parentheses, you can use the dot notation to access the method as if it were a property.
    For example, instead of calling a method like this:
    Database.UserId();
    You can also use property access syntax like this without parentheses:
    User := UserId;
     
    The reference document:
     
    Best Regards,
    Judy

Helpful resources

Quick Links

Dynamics 365 Community Update – Sep 9th

Welcome to the next edition of the Community Platform Update. This is a weekly…

Announcing Our 2024 Season 2 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 290,277 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 228,135 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,148

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans