1
I’m a beginner in C# and I’m opening a report on Access, but this report has criteria, that is, it depends on a numbering to open.
This numbering I have in a textbox and my doubt is how to pass the value of this textbox straight to the report of Access when it is opened.
Follow the code I use to open the report:
Microsoft.Office.Interop.Access.Application accessApp = new Microsoft.Office.Interop.Access.Application(); accessApp.OpenCurrentDatabase(@"E:\Desenvolvimento\C#\ReciboFácil\ReciboFácil\bin\Debug\ReciboFacil.mdb");
accessApp.DoCmd.OpenReport("ReciboServiço");
accessApp.CloseCurrentDatabase();
accessApp.DoCmd.Quit();
Mark as answered your question.
– Thiago Loureiro