Windows phone 7:How to obtain the MAC address?
I am having a Windows 7 phone with the all running features with the proper functionality. The wireless technology is also working fine. Now I would line is there any way to obtain the MAC ID of the windows 7 phone, which is I mainly used for the wireless access. The wifi connectivity is fine in the device. I am using the IEEE 802.11 wifi connectivity in my windows mobile. I know that in the Windows Mobile 6.0 the wifi MAC is can easily obtained but in the windows 7 phone, I don’t know. I information on the topic will be appreciated…
Re: Windows phone 7:How to obtain the MAC address?
I suggest you on the individual basis of the access of the wireless connectivity. Recommend you to generate the GUID in the connection and store it in the isolated storage location of the device. I totally got the result by the GUID in my windows 7 phone and this is works fine to detect me the MAC ID of the device from where I tried to access the wireless connection. The GUID will not require the log-in access of the connection. Try to work with this in appoint, you will definitely got the feedback of the service that I mentioned. It will ask you for the access period of the wireless connection through the MAC address of the device. The developer also recommend this one for the obtaining the MAC address s of the windows mobile whatever the operating system.
Re: Windows phone 7:How to obtain the MAC address?
It is basically very easy to recognize the MAC address of the device (Windows 7 phone). However the windows 7 phone will not give you the access of the MAC address in a very easy way. I am using the Linksys router for the wireless connectivity in the computer, and think that the structure is same as in the windows 7 mobile also. You first use the LAN connectivity of the device and log on to the router or the device page that you are using with the wireless facility. Go to the Administrator page of the device where you can found the setting for the wireless connection of the device or the router. One thing is important if you are trying to access the MAC code of the device through the computer them suggest you disable the MAC filter of the router. Save the setting in the router or the device (windows 7 phone). Now turn on the wireless connection of the windows 7 phone directly with the router by the help of your password, I hope you now able to make the connection. try this one it will work in the windows phone 7 as well as the computer.
Re: Windows phone 7:How to obtain the MAC address?
I suggest you to the simple solution to obtain the MAC address. Go to the LOG of the router or the device and then click on the VIEW LOG file of the device under the wireless connection. a list will appear in the window scroll down the list to look for the option DHCP CLIENT LOG, this option is present in both the computer and the window 7 phone. This is the Mac address of the device or the computer; it contains 12 digit format of the number. If your MAC filter is turned off then turn on it after fetching the MAC address of the windows 7 phone. Connect the wireless network and access the facility. This can also done by some of the third party software, but the problem is that the windows 7 phone will not allow you to download the software from the computer, also some of the software are not support in the windows phone.7.
Re: Windows phone 7:How to obtain the MAC address?
I used a VB script in my windows 7 phone to recognized the MAC address of the device. Recommend you to go through the script. It will help you to obtain the MAC address while you using the wireless connection. But the script that I mentioned I used it in the windows mobile with the Silverlight application, so I am not confused whether it works in the Windows 7 phone. I think that this is not the proper solution to detect the MAC address; try to ignore this, because some of the script are make some problem in the portable device.
Code:
strComputer = "."
Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set colItems = objWMIService.ExecQuery("Select MACAddress from Win32_NetworkAdapter where DeviceID=1")
For Each objItem in colItems
Wscript.Echo "MAC Address: " & objItem.MACAddress
Re: Windows phone 7:How to obtain the MAC address?
Any windows phone application supports the device extended properties, which is used for the determining the information about the system hardware and it also used for the tracking the wireless connectivity in the device. Some of the script with the code for the Get Value command will use to fetch the information. As per my suggest to get the MAC address of the windows 7 phone, you should try this one with the extended properties of the device. A class is requiring for the script to recognize the information or the ID of the device. The class inside the script also requires the device information capability. This means while the user make some operation on the device like the installation of any application or regarding your post access the wireless connectivity must make sure that to where to use the service of the device of the desire place. By the device extended properties you can able to get the device any part information in the external or the internal.
Re: Windows phone 7:How to obtain the MAC address?
Try with the script it will monitor the MAC address of the device. It will also helpful for the computer MAC address.
Code:
public partial class MainPage : PhoneApplicationPage
{
DispatcherTimer timer;
// Constructor
public MainPage()
{
InitializewirelessMACComponent();
timer = new DispatcherTimer();
timer.Interval = new TimeSpan(0,0,10);
timer.Tick += new EventHandler(timer_Tick);
timer.Start();
}
void timer_Tick(object sender, EventArgs e)
{
try
{
// These are TextBlock controls that are created in the page’s XAML file
MemoryTextBlock.Text = DeviceExtendedProperties.GetValue("ApplicationCurrentMemoryUsage").ToString();
PeakMemoryTextBlock.Text = DeviceExtendedProperties.GetValue("ApplicationPeakMemoryUsage").ToString();
}
catch (Exception ex)
{
MemoryTextBlock.Text = ex.Message;
}
}
}
Re: Windows phone 7:How to obtain the MAC address?
Quote:
Originally Posted by
deveritt
I used a VB script in my windows 7 phone to recognized the MAC address of the device. Recommend you to go through the script. It will help you to obtain the MAC address while you using the wireless connection. But the script that I mentioned I used it in the windows mobile with the Silverlight application, so I am not confused whether it works in the Windows 7 phone. I think that this is not the proper solution to detect the MAC address; try to ignore this, because some of the script are make some problem in the portable device.
Code:
strComputer = "."
Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set colItems = objWMIService.ExecQuery("Select MACAddress from Win32_NetworkAdapter where DeviceID=1")
For Each objItem in colItems
Wscript.Echo "MAC Address: " & objItem.MACAddress
Reply : Hi is this code to get MAC address on Windows Phone and is this code in vb , because i need the same code in C# , its not working for me , please i need your help... Thank You in advance
Re: Windows phone 7:How to obtain the MAC address?
Quote:
Originally Posted by
Nidhi Singh
Reply : Hi is this code to get MAC address on Windows Phone and is this code in vb , because i need the same code in C# , its not working for me , please i need your help... Thank You in advance
Have you checked the MSDN pages on this subject, not covering all of them but at least some which may be helpful for you:
http://msdn.microsoft.com/en-us/libr...=VS.92%29.aspx
http://msdn.microsoft.com/en-us/libr...=VS.92%29.aspx