Using Visual Studio 2022, I created a custom action in C# using
https://www.advancedinstaller.com/user- ... et-ca.html
However, when I try to run this custom action in the Finish Dialogs Stage, it fails.
The log file shows the error: "File not found: 'C:\UsersADMINI~1\AppData\Local\Temp1\CustomAction1.dll'".
Interestingly, I was able to successfully run the PowerShell inline script custom action in the Finish Dialogs Stage.
How do I run a custom action that I created in C# in the Finish Dialogs Stage?
Previously, I created a custom action in Advanced Installer V15.9 using the following method
https://www.advancedinstaller.com/user- ... rp-ca.html
I registered a custom action with "Call a function from the included native DLL".
However, this method has been deprecated, so this time I created a custom action using the above method.
**Attachments:**.
- Advanced Installer 21.3.1 project file.
- A set of custom action files created in Visual Studio 2022.
- Installer runtime log files.
**Create Installer:**.
1. **Create Installer:**.
- Start Advanced Installer 21.3.1 and create a project file using the installer project template.
- Add files to Files and Folders as needed.
- Add the custom action DLL file that you saved in step 2 to the Windows VolumeTemporary folder.
- .NET Runtime 8.0.0x64 to the [Prerequisites].
- The custom action created in step 2 has been incorporated into the custom action by "Calling a method from a .Net assembly".
- Build the installer.
2. **To create a custom action file:**.
- Install the Advanced Installer for Visual Studio 2022 extension to Visual Studio 2022.
- Create a project using the C# Custom Action template.
- Set the target framework to .NET8.0 in the CustomAction1 project file.
- Create the x64 platform in Configuration Manager.
- Select Publish from the context menu of the CustomAction1 project in Solution Explorer and set the following before publishing
- Configuration Release|x64
- Target Framework: net8.0-windows10.0.17763.0
- Deployment Mode: Framework Dependent
- Target Runtime: win-x64
I would be grateful for your advice.
Thank you in advance.