Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by Uriel_96 · Dec 23, 2010 at 12:25 AM · errorwindowsemail

Send an email C# error

OK here is my problem I copy a code that it was canceled as a question that is: http://answers.unity3d.com/questions/18952/system-net-mail-smtpclient-send-closed but my problem wasn't all that kind of things that he put like an error, actually its clear of does errors but I get an error that says

Assets/mail.cs(3,14): error CS0234: The type or namespace name Windows' does not exist in the namespace System'. Are you missing an assembly reference?

So maybe this is not the correct form to put it, but I try clearing that part but I get more errors about MessageBox.

Also and very important, I got another error that says

SocketException: No such host is known System.Net.Dns.GetHostByName (System.String hostName) System.Net.Sockets.TcpClient.Connect (System.String hostname, Int32 port) System.Net.Sockets.TcpClient..ctor (System.String hostname, Int32 port)

and the error is founded in Client.Send(Email);

So, Please answer, I need an answer of what is rong in this line of Client.Send(Email);.

Thanks... in advance.

Comment
Add comment · Show 1
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Peter G · Feb 10, 2011 at 02:26 AM 0
Share

Unfortunately, the Unity does not include every namespace in the Unity engine. I'm almost positive that System.Windows is one of them not included. This is to save build size, but for some things like you mention it is a hindrance.

2 Replies

· Add your reply
  • Sort: 
avatar image
1
Best Answer

Answer by Fanboy · Feb 10, 2011 at 02:50 AM

usually this is because the DNS query returned two IP addresses (an ipv4 and an ipv6), the ipv6 was first in the list, and ipv6 is not enabled somewhere. You can solve it by manually resolving the host, and selecting the ipv4 address.

IPHostEntry hostInfo = Dns.GetHostByName(hostString);
foreach(IPAddress ip in hostInfo.AddressList)
{
  if (ip.AddressFamily == ProtocolFamily.InterNetwork)
  {
    // this is the ipv4
  }
}
Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image YuHeLong · May 15, 2018 at 09:37 AM 0
Share

sometimes that will give you more that one IP, make sure you check the result to get the one you wanted

avatar image
0

Answer by boymeetsrobot · Dec 23, 2010 at 12:35 AM

Your question isn't entirely clear, but I think you may be trying to use Microsoft.NET namespaces. Monodevelop is an alternative IDE for multi-platform .net development and as such, you may have to use alternative namespaces in some instances. I suggest looking at the Monodevelop documentation to broaden your understanding: http://monodevelop.com/Documentation

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

1 Person is following this question.

avatar image

Related Questions

How to fix Unity compiler error when building WP8.1 game? 2 Answers

Send Log file with email? ( IOException: Sharing violation on path) HELP 0 Answers

windows 8.1, won't export out to win8 1 Answer

SpeechRecognitionEngine.InstalledRecognizers() returns null within Unity. 3 Answers

Game not working after build 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges