How do I get the Emulator on the same network as my PC?

余生长醉 提交于 2019-12-19 22:12:51

问题


I've created some Web API methods in .NET 4 / Visual Studio 2010 (and have now ported it to VS 2013 RC).

I want to consume them from a Windows CE / Compact Framework app using RestSharp.

Regardless of how I call these methods, though, I need to know the IP Address to use for the app running the Web API methods. I can access it from a browser using "localhost" and the port number Visual Studio displays when running the View for the Web API project in the browser (works fine, returns XML in Chrome).

But: how can I call it from my Windows CE / Compact Framework app? The emulator in which I run it doesn't believe that it and localhost are really on the same machine, so I can't use that, nor the machine's actual IP address as, again, it is delusional about who/where it is.

So: what is the workaround? How can I test this?

More details about this can be seen here: RFC on HttpWebRequest vs RESTSharp from Windows CE / Compact Framework 3.5

UPDATE

Vasily, my guess was that you meant for me to do this:

...but that led to this:

Note: I get the same when I choose the other option from the dropdown asociated with the "Enable NE2000 PCMCIA network adapter and bind to:" czechbox, namely "Intel(R) 82579LM Gigabit Network Connection".

And trying to install http://go.microsoft.com/fwlink/?linkid=46859 (both the 64-bit and the 32-bit flavors) slapped me with:

So tell me, I implore: Is there balm in Gilead, so that there may be joy in Mudville tonight?

UPDATE 2

In step 6 (bullet 6), I did this:

...which got me first a message that the software didn't install correctly, with the option to retry or assert that, no, everything is really fine (I chose the latter), but then this:

...IOW, I don't make it to step/bullet point 7

Then again, this Peek cat did warn, "Note that this is very much a “works on my machine” experience. If it burns your house down, don’t hold me responsible."

My house didn't burn down (I don't think - I'm not there right now), but the process to extract the file did fail ignominiously.


回答1:


You can use workstation network card by the emulator. Todo it you have to select "Use installed network card" checkbox and select the card from the list. after that you can use the workstation ip.




回答2:


This was helpful for me:

Windows Virtual PC and the Microsoft Device Emulator

I've had to use it more than a couple of times.

I saved the file as a PDF to my network folder, so it took me a while to find the link.



来源:https://stackoverflow.com/questions/19260075/how-do-i-get-the-emulator-on-the-same-network-as-my-pc

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!