Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error CS0103: The name 'HttpUtility' does not exist in the current context #158

Open
SavedByZero opened this issue Mar 7, 2023 · 4 comments

Comments

@SavedByZero
Copy link

Sorry to dump a bunch of stuff on you, but I am getting this compile error with the current library code:
Assets\Plugins\CountlySDK\Helpers\StorageAndMigrationHelper.cs(195,54): error CS0103: The name 'HttpUtility' does not exist in the current context

I have this set to .Net Framework in Unity 2021. That's when I started seeing this.

@ArtursKadikis
Copy link
Member

Hello, could you be please more specific about the specific setup at which you are running it? Could you please tell me these things:

  • Which Countly SDK version are you using?
  • which editor version you are using?
  • on which platfom (Mac, Windows, Linux) are you running this? And what is the platforms version?
  • For which target platform are you creating this build?
  • Were you trying to run/build it in the editor?
  • What scripting backend had you selected? Mono? IL2CPP?
  • any other points of interest that might describe your build
  • Did this happen when you were running the example integration or when integrating it into your project?
  • If you added the SDK into your project, how did you add it?

If you had not done it, could you please clone this repo and run the example integration?

I tried running our latest SDK version (22.06.0) on the Unity editor latest LTS version 2021.3.15f1 on Windows 10 and I couldn't reproduce the issue. The target platform I used was the "default" - "Windows, Mac, Linux". I tried also all combinations of the scripting backends and API compatability levels.

@SavedByZero
Copy link
Author

SDK: 22.06.0
Unity 2021.3.19f1
Android Platform
minimum API level 22, picks highest installed
Yes, tried in the editor
Mono Backend with .NET Framework selected, this was previously labeled as .Net 4.X, but according to Unity, it's the same thing.
This happened before I added anything as a compiler error, as soon as I switched from .Net 2.0 to .NET Framework. When I switch to .Net 2.0, the error goes away.
Note: I WAS able to get it to compile by adding a crc.rsp file with System.Web.dll

@ArtursKadikis
Copy link
Member

Hello,
It was not possible for me to reproduce the described issue with the configuration options that you laid out, or even with different variations on them

@ajeets1978
Copy link

Yes I had the same issue.

You can replicate it if you are using .Net Framework, but it works when I changed it to .Net Framework Standard 2.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants