C
C#17mo ago
Aljo_M

✅ How to make installer for .net framework 4.7.2

Hello, I am building a WPF plugin for AutoCAD. When i build solution i get 5 dlls, the main dll is called GUI and you can use "netload" command in autocad to load it and start using it. What i want to do is create some kind of installer, exe or whatever that user can simply run and it would do the following: 1. Find if autocad is installed and copy 5 dlls into that folder 2. Edit a specific file that autocad installs "example.lisp" and add one line of code to that file 3. Optionally create uninstaller What is best way? Should i use program like inno setup or create my own cs script? I am using Rider IDE and .net framework 4.7.2 (it is the latest supported version that autocad uses, i cant use other)
11 Replies
HimmDawg
HimmDawg17mo ago
This sounds like a simple console application to me. I wouln't go all out and create a gui for this. But I am minimalistic, so that depends on what you want for the user Also, if you have your DLLs already at hand, the installer doesn't need to be .NET Framework 4.7.2
Aljo_M
Aljo_MOP17mo ago
Okay so how can i create installer? I would still like the gui for a client to simplify the process
HimmDawg
HimmDawg17mo ago
Well, it's just an app with a GUI, so WPF, Avalonia, MAUI, even WinForms will do it. If cross-plattform is a concern, then I'd recommend Avalonia + .NET7
Aljo_M
Aljo_MOP17mo ago
So if i just create desktop wpf app it is the same as if creating installer with inno setup? What do i need to be careful abou? Also how to create uninstaller and how is it with permissions, do i have to manually ask for permission to copy files in the specific folder?
HimmDawg
HimmDawg17mo ago
I haven't used InnoSetup yet. But the main thing that app/installer/whatever is doing is "find autocad directory, copy 5 files and edit another file". It's a small task overall, so it doesn't really matter if you have a WPF app or InnoSetup. It's up to you.
Aljo_M
Aljo_MOP17mo ago
Okay thank you for you help :)
jcotton42
jcotton4217mo ago
I would use Inno for this actually @himmdawg @aljo_m Because it handles all the other installer things Like rolling back if you hit cancel, registering to appear in Add or Remove Programs etc
Aljo_M
Aljo_MOP17mo ago
okay, but how to use it to edit the .lisp file in the way i want?
jcotton42
jcotton4217mo ago
you'll have to look at their docs
Aljo_M
Aljo_MOP17mo ago
okay thanks
Accord
Accord17mo ago
Was this issue resolved? If so, run /close - otherwise I will mark this as stale and this post will be archived until there is new activity.
Want results from more Discord servers?
Add your server