Hello All,
Am a Novice to Ms Access. I have a doubt regarding a project. I have seen a form which have a button. If we click on a button in a form then a ppt is opened.
I have seen a code for that backend process and it's bit difficult for the beginners like me to understand it. The code is used for copying the data from Excel to ppt and then displaying the ppt with the excel data.
They have used the code like
Option Compare Database
Option Explicit
Private Sub TotalReport_Click()
DoCmd.SetWarnings False
DoCmd.OutputTo acOutputQuery, "Months", "ExcelWorkbook(*.xlsx)", "D:\Files\Database\Excel\Monthstime.xlsx", False, "", , acExportQualityPrint
DoCmd.OutputTo acOutputQuery, "Quarters", "ExcelWorkbook(*.xlsx)", "D:\Files\Database\Excel\Quarterstime.xlsx", False, "", , acExportQualityPrint
MsgBox "Success!!", vbInformation, ""
DoCmd.SetWarnings True
FollowHyperlink "D:\Personal\NewFolder\PPT\TotalPresentation.pptx"
Like the code continues..................
My Doubt (as an alternative):
We can just insert the excel data into ppt's via manually and then Instead of writing that code, I think we can just link with the hyperlink of the ppt to that button right?
Is there any logical difference between these two? Writing up a code or simply setting the hyperlink address in the background.
Could anyone of you can clarify my doubt please?
Am a Novice to Ms Access. I have a doubt regarding a project. I have seen a form which have a button. If we click on a button in a form then a ppt is opened.
I have seen a code for that backend process and it's bit difficult for the beginners like me to understand it. The code is used for copying the data from Excel to ppt and then displaying the ppt with the excel data.
They have used the code like
Option Compare Database
Option Explicit
Private Sub TotalReport_Click()
DoCmd.SetWarnings False
DoCmd.OutputTo acOutputQuery, "Months", "ExcelWorkbook(*.xlsx)", "D:\Files\Database\Excel\Monthstime.xlsx", False, "", , acExportQualityPrint
DoCmd.OutputTo acOutputQuery, "Quarters", "ExcelWorkbook(*.xlsx)", "D:\Files\Database\Excel\Quarterstime.xlsx", False, "", , acExportQualityPrint
MsgBox "Success!!", vbInformation, ""
DoCmd.SetWarnings True
FollowHyperlink "D:\Personal\NewFolder\PPT\TotalPresentation.pptx"
Like the code continues..................
My Doubt (as an alternative):
We can just insert the excel data into ppt's via manually and then Instead of writing that code, I think we can just link with the hyperlink of the ppt to that button right?
Is there any logical difference between these two? Writing up a code or simply setting the hyperlink address in the background.
Could anyone of you can clarify my doubt please?