✅ #pragma warning disable 246 not working
So i am trying to compile and i get CS0246 error. i don't care to fix it because that file is not used i just need it included so i can modify it. it is used by another program. i tried to add on the whole file #pragma warning disable CS0246,2046,246/#pragma warning restore 246 any version does not seems to have any effect. not even adding it on project properties. any suggestion, ideas ?
4 Replies
You can't ignore that error
It's a compile error
If you want to include a
.cs
file without compiling it, iirc you can add <Compile Remove="YourFile.cs"/>
to the project file to prevent it from being compiledthank you this was a fine solution 😄
Unknown User•12mo ago
Message Not Public
Sign In & Join Server To View
Use the /close command to mark a forum thread as answered