Library for Microsoft Access

Yusuf 791 Reputation points
2022-01-08T11:24:52.487+00:00

Is there any library or dll to make using Microsoft Access functions easier :

DSum("Credit", "TransactionsDetails", "TransactionsDetails!TransactionsID = " & Me.Parent!ID)

and make access to objects easier:

Forms!Mainform!Subform1.Form!ControlName.Enabled

or contains database and accounting functions

Thanks

Microsoft 365 and Office Access Development
Developer technologies C#
0 comments No comments
{count} votes

Accepted answer
  1. Jack J Jun 25,296 Reputation points
    2022-01-11T03:05:40.99+00:00

    @Yusuf , you could try the following steps to add the dll to use Microsoft Access functions easier.

    First, Please add nuget-package Microsoft.Office.Interop.Access.

    Second, you can use the namespace:

    using Access = Microsoft.Office.Interop.Access;

    Third, you could use the following code to use the Dsum function.

        Access.Application app=new Access.Application();  
        app.OpenAccessProject("path");  
        app.DSum("Credit", "TransactionsDetails", "TransactionsDetails!TransactionsID = " & Me.Parent!ID);  
    

    If the response is helpful, please click "Accept Answer" and upvote it.

    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    1 person found this answer helpful.
    0 comments No comments

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.