Finding Computer Name Using C#

This C# code snippet obtains the NetBIOS and DNS computer names of the local computer.

static string GetName ()
{
   string netBiosName = System.Environment.MachineName;

   //return netBiosName;
   // Following method is deprecated
   // string dnsName = 
   //     System.Net.Dns.GetHostByName("LocalHost").HostName;

   string dnsName = System.Net.Dns.GetHostName();
   return dnsName;
}

That's It.
Advertisements

167 responses to this post.

  1. I am actually eager of viewing humorous video lessons at youtube, and this video clip is genuinely so funny, hehehhe.

  2. I am curious to find out what blog system you happen to be using? I’m experiencing some minor security issues with my latest site and I’d like to find something more risk-free. Do you have any suggestions?

  3. If you plan was to attract related primates when using the same funky taste in hard liquor you succeeded beyond your wildest dreams with me, but if it was truly “to attract a disaffected audience with the same disjointed sense of humor” then I’m genuinely sorry, but you’ve failed miserably.

  4. Where does PCUSA get its financial support? Petro$ perhaps? Who knows!

  5. Loved the put up, tends to make me feel bad about how normal ours is. I’d be interested to see the CTR/Conversion rates from some of them.

  6. That Spartan Golf Club just one is incredible. Well done for the creative behind that.

  7. This really solved my problem, thank you!

  8. This is often a fantastic web site, could you be interested in going through an interview concerning just how you created it? If so e-mail me personally!

  9. Re: Whomever created the statement that this was a good site truly needs to possess their head evaluated.

  10. You should really control the remarks on this site

  11. Just discovered this site thru Bing, what a way to brighten up my week!

  12. Have you considered adding a few social bookmarking links to these blogs. At the very least for flickr.

  13. Strange , this post shows up with a black hue to it, what shade is the primary color on your web site?

  14. A lot of of the remarks on this particular blog page dont make sense.

  15. Brilliant, thank you, I will visit again now.

  16. How did you make a blog site look this sick. Email me if you can and share your wisdom. Id be appreciative!

  17. Do youve got a spam issue on this web site; I also am a blogger, and I was wondering your situation; weve created some nice strategies and were looking to trade solutions with other individuals, be positive to blast me an e-mail if interested.

  18. Weird , your site turns up with a black hue to it, what color is the primary color on your web-site?

  19. When I start your Rss feed it appears to be to be a lot of garbage, is the issue on my side?

  20. How come you do not have your web site viewable in mobile format? cant view anything in my iPad.

  21. After I open up your Feed it seems to be a ton of garbage, is the issue on my side?

  22. How did you make a blog look this sick! Email me if you can and share your wisdom. !

  23. Have you thought about adding some relevant links to the article? I think it will really enhance my understanding.

  24. I experimented with taking a look at your website on my new iphone 4 and the design does not seem to be right. Might want to check it out on WAP as well as it seems most mobile phone layouts are not working with your web site.

  25. You have mentioned very interesting details! ps nice internet site.

  26. I was basically wondering if you ever thought of switching the design of your site? Its well written; I love what you have got to state. But maybe you could include a a bit more in the way of written content so people might connect to it better. You have got an awful lot of text for only having one or two photos. Maybe you can space it out better?

  27. Rattling fantastic information can be found on this weblog.

  28. I like the blog site layout ! How was it made. It is so good.

  29. You have noted very interesting details! ps nice website.

  30. Very interesting info!Perfect just what I was searching for!

  31. I adored your rich post. super contribution. I hope you release others. I will continue subscribing

  32. Hi, i think that i noticed you visited my web site thus i came to “go back the favor”.I’m trying to in finding issues to enhance my site!I assume its adequate to use a few of your ideas!!

  33. Cool post ! Thanks for, commenting on this blog page dude. I shall email you again! I didnt realise that.

  34. I was wanting to know if you ever considered switching the layout of your site? It is very well written; I really like what you have got to state. But maybe you can include a little more in the way of written content so people could connect to it better. You have got a great deal of text for only having one or two photos. Maybe you could space it out better?

  35. I was just seeking this information for some time. After 6 hours of continuous Googleing, at last I got it in your website. I wonder what is the lack of Google strategy that don’t rank this type of informative sites in top of the list. Normally the top websites are full of garbage.

  36. Thanks for what you’ve got. This is the most effective post I’ve read

  37. Parece que desde que se han colado en este blog los espíritus errantes y algún que otro aparecido,los fallos comienzan a manifestarse y no me refiero concretamente a fallos técnicos o de manipulación habitual mecánica.Lo digo por los otros.Cuidaros

  38. Thanks! Will probably be nice to anyone who usess it, including myself. Sustain the nice work for positive ill take a look at extra posts.. Interesting article. Were did you got all the information from tremendous more please.

  39. Discover to write himself, the post from one more supply

  40. Hello, I just hopped over to your web site through StumbleUpon. Not somthing I might usually read, but I liked your thoughts none the less. Thank you for making some thing worthy of reading through.

  41. You could definitely see your enthusiasm within the paintings you write. The world hopes for even more passionate writers such as you who are not afraid to say how they believe. All the time follow your heart.

  42. Is it alright to put a portion of this on my personal website if I post a reference point to this web site?

  43. Even though I actually like this publish, I believe there was an punctuational error near towards the finish of the third sentence.

  44. Hola! I simply want to provide a substantial thumbs all the way up for that fantastic information you’ve here about this post. I’ll be returning to your site for additional rapidly. At the same time for everybody who is considering Digital Marketing, visit excellent web blog

  45. Hi! I simply want to provide a enormous thumbs all the way up for that terrific knowledge you’ve here about this post. I’ll be returning to your site for additional in the near future. However should you be keen on Internet Marketing, check out a web site

  46. Very interesting info!Perfect just what I was searching for!

  47. Between me and my husband we’ve owned more MP3 players over the years than I can count, including Sansas, iRivers, iPods (classic & touch), the Ibiza Rhapsody, etc. But, the last few years I’ve settled down to one line of players. London Olympics Medal Tally

  48. Many of the remarks on this webpage dont make sense.

  49. I have got 1 idea for your site. It seems like right now there are a handful of cascading stylesheet problems when launching a selection of webpages inside google chrome and firefox. It is operating fine in internet explorer. Perhaps you can double check that.

  50. I enjoy your wp template, where did you get a hold of it?

  51. This site has lots of extremely useful stuff on it. Thank you for sharing it with me.

  52. Good Stuff, do you have a flickr account?

  53. It sounds like youre generating troubles oneself by looking to solve this concern rather of looking at why their can be a problem in the first place

  54. The structure for your blog is a little bit off in Epiphany. Nevertheless I like your blog. I may have to install a “normal” web browser just to enjoy it.

  55. Is it alright to place a portion of this in my personal web site if I publish a reference point to this webpage?

  56. Odd , this post shows up with a black color to it, what shade is the primary color on your web-site?

  57. Oh man! This website is cool. How can I make it look this good .

  58. I enjoy your wordpress template, where did you get a hold of it?

  59. i really used to admire you as a film maker but after looking up ur comments on this pagei can only laugh at you

  60. Strange , this post turns up with a dark color to it, what color is the primary color on your site?

  61. Just discovered this site thru Google, what a pleasant surprise!

  62. Aw, this was a very nice post. In idea I would like to put in writing like this moreover – taking time and actual effort to make a very good article… however what can I say… I procrastinate alot and certainly not seem to get one thing done.

  63. very helpful stuff, overall I picture this is worthy of a bookmark, many thanks

  64. Is it alright to place part of this on my personal website if I post a reference point to this site?

  65. I’m buying a house soon so this is very helpful. Mortgages appear quite daunting but your post was straight to the point.

  66. Well writing for me. I like it. ^ ^ Please update your web generally. I’ll visit your blog yet again. beautylemon.com Bye ^_^

  67. Nice post on mortgages, it’s good to hear someone with straightforward mortgages information.

  68. This blog has inspired me to start writing on my own blog

  69. This was a realy good post i appriciate the share i will be sure to add you to my favorites for sure.

  70. […] Marathon 2010 Results: David Rutoh Triumphs in the MarathonKeen Observers[VIDEO] Baltimore Marathon 2010 ResultsCNM News NetworkWBAL Baltimore -Showbiz Gossips (press release) -Baltimore Sun (blog)all […]

  71. Your house is valueble for me. Thanks!…

  72. I am beginner in development field I seeking new social plugin you’ve got a wonderful collection of twitter plugins. Thanks Eric

  73. Squidoo, Hubpages and Infobarrel are terrific, i write articles or blog posts for them that links to my internet site. wonderful for promoting affiliate p.*~

  74. Unquestionably believe that which you said. Your favorite justification appeared to be on the web the simplest thing to be aware of. I say to you, I definitely get irked while people consider worries that they just do not know about. You managed to hit the nail upon the top as well as defined out the whole thing without having side-effects , people could take a signal. Will likely be back to get more. Thanks

  75. May (Lucky McKee, 2002) Carrie meets Frankenstein; May decides since she doesnt have friends, shell make one.

  76. I intended to send you the bit of note to be able to thank you very much yet again over the beautiful advice you’ve discussed on this website. It is quite seriously generous with people like you to allow unhampered precisely what a number of people might have marketed as an electronic book in making some dough on their own, and in particular seeing that you could possibly have done it in the event you decided. These principles also worked to be the fantastic way to comprehend most people have the identical passion the same as mine to figure out many more pertaining to this condition. I am sure there are numerous more fun occasions in the future for people who scan through your blog.

  77. I and my pals happened to be digesting the good advice located on your web blog and then came up with a terrible suspicion I never expressed respect to the website owner for those secrets. My women became so very interested to learn them and have now absolutely been enjoying them. We appreciate you being really accommodating and then for settling on these kinds of superior things millions of individuals are really eager to discover. My personal honest apologies for not expressing appreciation to sooner.

  78. I happen to be commenting to let you know what a extraordinary experience my cousin’s girl gained visiting your web page. She discovered lots of issues, which included what it’s like to have an ideal teaching spirit to have many others easily gain knowledge of certain tortuous matters. You actually did more than her desires. I appreciate you for delivering these essential, trusted, edifying and also cool tips about the topic to Lizeth.

  79. I like the helpful information you provide in your articles. I’ll bookmark your weblog and check again here frequently. I’m quite certain I will learn plenty of new stuff right here! Good luck for the next!

  80. I have been absent for a while, but now I remember why I used to love this website. Thanks , I will try and check back more frequently. How frequently you update your website?

  81. I dont usually reply to posts but I will in this case. WoW. amazing stuff thanx pleasing awesome great.

  82. I went back and re-read your book when I was doing the judging and I enjoyed it even more the second time around. I cant wait to see volume 2!

  83. Wow this definitely takes me back, a good quick read.

  84. I not to mention my buddies ended up studying the best helpful hints found on your web blog and so suddenly got an awful feeling I never thanked the web site owner for those techniques. The guys appeared to be certainly joyful to learn them and have now clearly been taking pleasure in those things. Thank you for genuinely very thoughtful and then for choosing such exceptional things most people are really needing to understand about. Our own sincere regret for not saying thanks to sooner.

  85. Wow, KG, we were right near you, maybe 1/4 to 1/3 of a mile further down the road.

  86. Glad to see that this site works well on my Blackberry Bold, everything I want to do is functional. Thanks for keeping it up to date with the latest.

  87. Heya i am for the first time here. I found this board and I find It really useful & it helped me out much. I hope to give something back and help others like you helped me.

  88. Love the blog here. Nice colors. I am definitely staying tuned to this one. Hope to see more.

  89. I loved as much as you will receive carried out right here. The sketch is tasteful, your authored material stylish. nonetheless, you command get bought an impatience over that you wish be delivering the following. unwell unquestionably come more formerly again as exactly the same nearly very often inside case you shield this increase.

  90. Dear Cris,

  91. […] Steve made a short and sweet WAD post about SARP and the awesome Dr. Wenzel […]

  92. One thing I have actually noticed is that there are plenty of misconceptions regarding the banking companies intentions if talking about home foreclosure. One delusion in particular is always that the bank prefers to have your house. Your banker wants your dollars, not your house. They want the cash they gave you with interest. Preventing the bank will undoubtedly draw a new foreclosed summary. Thanks for your post.

  93. Hi Amy, thanks a million for that! Yes, theres no reason that people, even with severe asthma, shouldnt exercise. I think I get a bigger emotional boost than a physical one, when I exercise or participate in a sport I like.

  94. Thanks… there seems to be a lot of shady information regarding mortgages. It’s nice to see someone with a truthful post about it sometimes.

  95. its almost 5pm. kakaexcite.

  96. Noticed your site on delicious right now and genuinely enjoyed it.. Hey, I just hopped over to your site via StumbleUpon. Not somthing I would usually browse, but I appreciated your views none the less. Thanks for creating something worthy of reading. great terrific awesome.

  97. I strongly recommend Christopher Hitchins book, God is not Great: How Religion Poisons Everything. Hitchens is an intelligent conservative, by the way.

  98. When it comes to no limit florida hold’em, I like to consider myself as a little an expert. I have been playing poker now for several years, and your website has taught me an awful lot. Many thanks for all you assistance, both in life, and at the poker table brother!

  99. I think another person wants to become v isited in h is sleep by the ghost of Paul Rand so he can see the error of h is tactics.

  100. Great piece of writing. Very interesting.

  101. Excellent beat ! I would like to apprentice while you amend your site, how can i subscribe for a blog site? The account helped me a acceptable deal. I had been a little bit acquainted of this your broadcast offered bright clear concept

  102. Hello there, You have done a great job. I’ll definitely digg it and personally suggest to my friends. I am confident they’ll be benefited from this website.

  103. weak erection cure weak erection treatment how to fix erection problems how to fix impotence how to get a bigger erection naturally over the counter impotence drugs best pills for erectile dysfunction difficulty getting an erection natural food for strong erection over the counter erection impotence treatments herbal natural male enhancement drugs strong erection exercises losing erection during foreplay reasons for lack of erection male enhancer products erectile dysfunction treatment injection treating erectile dysfunction tips how to maintain an erection men losing erection otc male enhancement pills which ed pill is the best problem with erection erection pills uk maintain erection long time i cannot maintain an erection impotence herbal remedy keep losing erection trouble getting full erection all natural male enhancement pills

  104. Netnews has existed to get a quite a while. Its even over the age of the globe wide web- just what most everyone knows because the

  105. Nntp has existed for the while. It truly is even more aged than the globe wide web- precisely what most everyone knows as being the

  106. I feel It may Be guidance all of you. Many thanks a whole lot for this magnificence Experiencing piece of writing with me. I’m appreciating it greatly! Wanting ahead to another superb post. Very good luck to your Author! All the greatest.

  107. […]usually posts some very interesting stuff like this. If you’re new to this site[…]…

  108. Nntp has been online for the quite a while. Its even more aged than the entire world wide web- just what most everyone knows since the

  109. Netnews has existed for any long time. It truly is even over the age of the planet wide web- precisely what nearly everyone knows because the

  110. @23, interesting story.

  111. Hello there, just became alert to your blog through Google, and found that it’s really informative. I’m gonna watch out for brussels. I’ll be grateful if you continue this in future. A lot of people will be benefited from your writing. Cheers!

  112. Nntp has existed for the quite a while. It truly is even more aged than the planet wide web- just what most everyone knows since the

  113. Nntp has been online for the long time. It really is even significantly older than the planet wide web- just what nearly everyone knows as being the

  114. Nntp has been online to get a quite a while. It really is even over the age of the planet wide web- exactly what most everyone knows as being the

  115. Netnews has existed to get a long time. It really is even more aged than the globe wide web- exactly what nearly everyone knows as being the

  116. This publication has inspired me to continue focusing on my own blog

  117. hey there and thank you for your info – I have definitely picked up something new from right here. I did however expertise several technical points using this website, as I experienced to reload the website a lot of times previous to I could get it to load correctly. I had been wondering if your web host is OK? Not that I’m complaining, but sluggish loading instances times will sometimes affect your placement in google and could damage your high quality score if advertising and marketing with Adwords. Anyway I am adding this RSS to my email and could look out for much more of your respective exciting content. Ensure that you update this again soon..

  118. Great story, Denise! Kevin and I love Jamaica and feel the same you do about it. Its our time to relax and just enjoy one another. Love it!

  119. Thanks so much for giving everyone an extremely wonderful opportunity to read critical reviews from this site. It’s always so excellent and also packed with a lot of fun for me and my office mates to visit your web site at least 3 times per week to read through the newest items you have got. And lastly, I am usually pleased with the terrific concepts served by you. Certain two ideas in this posting are rather the most effective I have had.

  120. Undeniably believe that which you said. Your favorite justification appeared to be on the net the easiest thing to be aware of. I say to you, I certainly get irked while people think about worries that they just don’t know about. You managed to hit the nail upon the top and defined out the whole thing without having side effect , people could take a signal. Will likely be back to get more. Thanks

  121. I just want to mention I am all new to blogging and site-building and truly savored your page. Probably I’m want to bookmark your blog . You actually have fantastic posts. Thanks a lot for sharing your webpage.

  122. Nntp has been online for the long time. Its even over the age of the globe wide web- exactly what most everyone knows as being the

  123. Netnews has been online to get a quite a while. It truly is even over the age of the entire world wide web- exactly what most everyone knows since the

  124. First, marriage is a legal contract defining property rights, and thus, is secular and has nothing to do with religion or god or anything in the fiction book called the bible. Secondly, our Constitution thru the establishment clause, prohibits any promotion of any religion, and thus sets the standard for humans to enjoy their freedom on a secular basis. And thirdly, the coursts interpret the law, and that is what we all have to live by. You may not be in favor of the ruling, but the community and the country avoid chaos thru the rule of law. I suggest the religious zealots get over themselves, and cease and desist from forcing their homophobia onto others.

  125. Ok, so I cant vote just yet. I ran Boston in April and it was amazing. I am running NYC on Sunday, so I will be sure to come back and vote! Only 3 days away now. Cheers!

  126. I have heard this transpire more than a few times to be honest, I think people today are best of picking a local freelancer or least 1 which resides in their own country, that way they are obeyed by the same regulations. No police will knock on a door of someone who lives in another country.

  127. Nntp has been online for any while. Its even more aged than the entire world wide web- just what most everyone knows because the

  128. Nntp has existed for the quite a while. It truly is even significantly older than the globe wide web- precisely what many people know because the

  129. Iv`e been a Yankee for 77 yrs. Top that

  130. Thanks for this good website. I’m trying to read through some more posts but I cant get your website to display properly in my Opera Browser. Thanks once again.

  131. Dar ei sunt cuceritori de peste 600 de ani, au tot incercat sa patrunda in Europa pe la hotarele din rasarit, acolo unde noi singuri, repet, singuri am tinut piept. Si ce am obtinut?

  132. Netnews ‘s been around for any quite a while. Its even more aged than the globe wide web- just what most everyone knows as being the

  133. Nntp has existed for any while. Its even significantly older than the globe wide web- just what many people know as being the

  134. Nntp has been online to get a while. It really is even over the age of the globe wide web- exactly what many people know since the

  135. Just wish to say your article is as astounding. The clarity in your post is simply cool and i could assume you are an expert on this subject. Well with your permission allow me to grab your RSS feed to keep updated with forthcoming post. Thanks a million and please keep up the gratifying work.

  136. Netnews has been online to get a while. It really is even significantly older than the planet wide web- just what many people know since the

  137. Netnews has existed for any while. Its even over the age of the planet wide web- just what nearly everyone knows since the

  138. 3.Top part bus, again the much larger or even sooner the laptop prominent size bus is the far better the computer can accomplish.

  139. I keep listening to the rumor lecture about getting boundless online grant applications so I have been looking around for the best site to get one. Could you advise me please, where could i find some?

  140. Some truly select content on this web site , saved to fav.

  141. Magnificent items from you, man. I’ve consider your stuff prior to and you are simply too fantastic. I actually like what you have received here, certainly like what you’re saying and the way through which you are saying it. You make it enjoyable and you still care for to stay it smart. I cant wait to read far more from you. That is really a terrific web site.

  142. Magnificent items from you, man. I’ve consider your stuff prior to and you are simply too fantastic. I actually like what you have received here, certainly like what you’re saying and the way through which you are saying it. You make it enjoyable and you still care for to stay it smart. I cant wait to read far more from you. That is really a terrific web site.

  143. Magnificent items from you, man. I’ve consider your stuff prior to and you are simply too fantastic. I actually like what you have received here, certainly like what you’re saying and the way through which you are saying it. You make it enjoyable and you still care for to stay it smart. I cant wait to read far more from you. That is really a terrific web site.

  144. Hello, i think that i noticed you visited my weblog so i got here to return the favor?.I am attempting to to find issues to enhance my web site!I assume its adequate to make use of some of your ideas!!

  145. I believe other site owners should take this website being an model, very clean and excellent user friendly design and style. “Democracy is. My answer is this simply because other systems are worse. by Jawaharlal Nehru.

  146. Hello, i think that i noticed you visited my weblog so i got here to return the favor?.I am attempting to to find issues to enhance my web site!I assume its adequate to make use of some of your ideas!!

  147. Hello, i think that i noticed you visited my weblog so i got here to return the choose?.I am attempting to to find issues to enhance my web site!I assume its adequate to make use of some of your ideas!!

  148. Thanks for the marvelous posting! I quite enjoyed reading it, you are a great author.I will make sure to bookmark your blog and will eventually come back later on. I want to encourage you to continue your great posts, have a nice afternoon!

  149. Write more, thats all I have to say. Literally, it seems as though you relied on the video to make your point. You clearly know what youre talking about, why waste your intelligence on just posting videos to your weblog when you could be giving us something enlightening to read?

  150. I’d have to check with you here. Which is not something I usually do! I enjoy reading a post that will make people think. Also, thanks for allowing me to comment!

  151. Nice blog! Is your theme custom made or did you download it from somewhere? A design like yours with a few simple tweeks would really make my blog jump out. Please let me know where you got your theme. Many thanks

  152. Wow that was unusual. I just wrote an incredibly long comment but after I clicked submit my comment didn’t appear. Grrrr… well I’m not writing all that over again. Anyway, just wanted to say superb blog!

  153. My husband and i ended up being very joyous when Emmanuel could finish up his investigation because of the ideas he grabbed through your weblog. It’s not at all simplistic just to possibly be giving away steps which the others have been making money from. And we know we now have the writer to be grateful to for that. The entire explanations you made, the easy web site navigation, the friendships you assist to create – it’s got many extraordinary, and it is leading our son in addition to us imagine that this issue is amusing, which is unbelievably pressing. Thank you for the whole thing!

  154. Youre so cool! I dont suppose Ive read anything like this before. So nice to find somebody with some original thoughts on this subject. realy thank you for starting this up. this website is something that is needed on the web, someone with a little originality. useful job for bringing something new to the internet!

  155. An interesting discussion is worth comment. I think that you should write more on this topic, it might not be a taboo subject but generally people are not enough to speak on such topics. To the next. Cheers

  156. I was reading some of your content on this website and I believe this website is very informative ! Retain putting up.

  157. Hey, you?re the goto expert. Thanks for haingng out here.

  158. Although web sites we backlink to below are considerably not connected to ours, we really feel they may be in fact really worth a go as a result of, so have a look.

  159. One of our guests recently suggested the following website.

  160. Here is a superb Blog You may Obtain Interesting that we Encourage You

Comments are closed.

%d bloggers like this: