JustAnswer > Computer
Ask A Question|Register|Login|Help
JustAnswer

Computer

Ask a Computer Question, Get an Answer ASAP!

Have your own Computer question?

18 Tech Support Specialists are Online Now
characters left:
Not a Computer Question?

Related Computer Topics:

  • Fix
  • ,
  • Run
  • ,
  • Set
  • ,
  • Blog
  • ,
  • Pass
  • ,
  • User
  • ,
  • Type
  • ,
  • Work
  • ,
  • Click
  • ,
  • Fixed
Bookmark and Share

Question

how can I change the network location on my windows 7 lan from public to work? The option is not available in the standard fashion.

Submitted: 27 days and 16 hours ago.
Category: Computer
Value: $18
Status: CLOSED
+
Read More

Optional Information

Computer OS: Windows 7
Browser: IE

Already Tried:
everything

Posted by Claws224 27 days and 16 hours ago.

Answer

Hi,

 

Can you copy the following script then paste it into a notepad and save it as ChangeCategory.ps1 to the C drive

 

 

//
// Name: ChangeCategory.ps1
// Copyright: Microsoft 2009
// Revision: 1.0
//
// This script can be used to change the network category of
// an 'Unidentified' network to Private to allow common network
// activity. This script should only be run when connected to
// a network that is trusted since it will also affect the
// firewall profile used.
// This script is provided as-is and Microsoft does not assume any
// liability. This script may be redistributed as long as the file
// contains these terms of use unmodified.
//
// Usage:
// Start an elevated Powershell command window and execute
// ChangeCategory.ps1
//
$NLMType = [Type]::GetTypeFromCLSID(‘DCB00C01-570F-4A9B-8D69-199FDBA5723B')
$INetworkListManager = [Activator]::CreateInstance($NLMType)

$NLM_ENUM_NETWORK_CONNECTED = 1
$NLM_NETWORK_CATEGORY_PUBLIC = 0x00
$NLM_NETWORK_CATEGORY_PRIVATE = 0x01
$UNIDENTIFIED = "Unidentified network"

$INetworks = $INetworkListManager.GetNetworks($NLM_ENUM_NETWORK_CONNECTED)

foreach ($INetwork in $INetworks)
{
$Name = $INetwork.GetName()
$Category = $INetwork.GetCategory()

if ($INetwork.IsConnected -and ($Category -eq $NLM_NETWORK_CATEGORY_PUBLIC) -and ($Name -eq $UNIDENTIFIED))
{
$INetwork.SetCategory($NLM_NETWORK_CATEGORY_PRIVATE)
}
}

 

 

 

Onnce you have the file saved can you then open a Command window by opening My Computer then clicking on the C drive to select it then hold the Shift key down and right click the drive and choose Open Command Window here.

 

once the commad prompt opens can you type the following command without the quotes and hit enter "c:\ChangeCategory.ps1"

 

Once that is doen let me know if the network changes to Work

 

Thanks

Eric

27 days and 16 hours ago.

Reply

I followed your advice and when I typed the command it just opened the ChangeCategory.ps1 file in a new window. It did not change any network settings that I can tell.

Posted by Claws224 27 days and 16 hours ago.

Answer

Ok,

 

We might have to change your view options as the file may have not been saved in the correct format.

 

Can you open the Control Panel then click Folder Options and Select the view tab, From there can you remove the check from Hide extensions for known file types then hit OK.

 

Once that is doene can you go back to the ChangeCategory file and make sure it is named ChangeCategory.ps1 as I suspect it is called something like ChangeCategory.ps1.txt

 

Let me know


Thanks

 

Eric

27 days and 16 hours ago.

Reply

The file was saved with the correct extension. I changed the save as type to all files and typed the extension myself. Plus explorer lists it as a .ps1 file and the icon is different than a standard .txt file. I don't know if it matters but I have a laptop which I just upgraded from vista x64 to win7 x64. The laptop connects to my desktop through a switch, the desktop has win7 x64 but I also had the network set up before uprgading my laptop to win7 and it has only been since the upgrade that I cannot change the network type on my laptop. The desktop is set to home network which is what I want to set the laptop for.

Posted by Claws224 27 days and 15 hours ago.

Answer

Ok,

 

Can we try removing the connection then re setting it up by opening the control panel then selecting Network and Internet and opening the Network and Sharing Center.


from there can you click Manage Network Connections and find your network then single click it and hit delete to remove it from the list.

 

Once it is removed can you then reboot your machine then try setting the connection up again and let me know if you can choose Work.

 

Thanks

Eric

27 days and 15 hours ago.

Reply

Thats one thing I have tried but I cannot seem to find the network connections so that I can delete it. Your instructions for finding the network connection would work on vista but win7 does not have a "manage network connections" option but if you select the "change adapter settings" you get a list of connections. Even after I unplug the cable it says "You cannot delete the selected connection". Oh the powershell script would not run partly because in win7 scripts are restricted so I changed the setting to unrestricted but it would not run properly and appeared to have errors while trying to execute.

Posted by Claws224 27 days and 15 hours ago.

Answer

Ok,

 

Sorry, I had a blonde moment as I have been working with Vista all night.

 

Can you right click on the Network Status icon in the system tray and choose Network and sharing center then when it opens can you double click on the Public network and hopefully a window will open up, when it opens you should then be able to change the profile to work.

 

If that does not work can you try going to start then in the search box can you type secpol.msc and hit enter.


When the window opens can you look under the Network List Manager Policies and double click Unidentified Networks then change Location Type to Work and see if it will reset the connection for you after you reboot.

 

Let me know if that does not work

 

Thanks


Eric

27 days and 14 hours ago.

Reply

Sorry when I typed my original question I meant to say that I need to change it to a "Home" location. Your instructions did change it to "work", but I still cannot change the location normally or discover any other computers or devices on my home lan.

Posted by Claws224 27 days and 14 hours ago.

Answer

Ok,

 

Can you tell me what make and model your router is?

 

Then can you go back in and change the Location Type to Home for Unidentified Networks.

 

Thanks

27 days and 14 hours ago.

Reply

It is not a router, I'm using a Linksys EZXS55W 10\100 5 port switch and network cable. In the secpol.msc I can change Unidentified networks to Private and Public but not Home, Work, etc. I did choose the "Let user change location" option but it made no difference.

Posted by Claws224 27 days and 14 hours ago.

Info Request

Ok,

 

What type of device is controling your network and handing out IP addresses?

 

Is it a cable modem or a dsl modem?


Thanks

27 days and 7 hours ago.

Reply

Well for an internet connection I have an aircard on my laptop wich is in an express card slot, and I share it over my wired lan with my desktop. I had the IP's set manually but changed it to automatic to try and solve the problem. But currently the switch is the only hardware other than the computers and their respective network adapters.

Posted by Claws224 27 days and 1 hours ago.

Answer

Ok,

 

Would it be possible for you to change the IP range that is being used to share the connection, So instead of the default 192.168.0.1 etc change it on the laptops Network card to 192.168.2.1 for the gateway etc then connect the desktop so it will see it as a new network and then allow you to select your location.

 

Let me know.


Thanks

 

Eric

26 days and 21 hours ago.

Reply

I tried to change the IP's manually just throught the connection properties window and it worked on my desktop, I can change the network location, but on my laptop it didn't make any difference.

Posted by Claws224 26 days and 21 hours ago.

Info Request

Ok,

 

did it change the ip address the network is showing on the Laptop?

 

Thanks

26 days and 20 hours ago.

Reply

when I changed the ip on the laptop it had to reidentify the network, but with the same results unfortunately. I set my laptop to 192.168.137.1 and the desktop was 192.168.137.2

Posted by Claws224 26 days and 19 hours ago.

Info Request

Ok,

 

And it would not let you choose Home?

 

If so what did it set it to?

 

Thanks

26 days and 19 hours ago.

Reply

since we edited the secpol.msc and set it to assign unidentified networks to private, it set it as a work network. Before editing the security policy it assigned it a public location. Even though I chose the "allow user to change location" option in secpol.msc I still cannot change the option. It's just annoying me because it works fine on my desktop without any editing of the secpol.msc

Accepted Answer

Ok,

 

Can we try the Powershell script I gave you again?

 

This tie can you open the command prompt and type

"set-executionpolicy remotesigned" without the quotes then hit enter and then type

 

"c:\ChangeCategory.ps1" without the quotes and hit enter

 

Let me know if that helps or not


Thanks


Eric

Picture
Expert: Claws224
Pos. Feedback: 99.5 %
Accepts: 
Answered: 10/27/2009

IEEE Network Engineer, Microsoft

approx 20 years of experience from software to hardware design

26 days and 19 hours ago.

Reply

I'm sorry either I have the script incorrect or something because it doesn't even run. Not from a cmd prompt or in powershell.

Posted by Claws224 26 days and 19 hours ago.

Info Request

Ok,

 

In that case I am going to have to opt out as we have tried everything I can possibly think of.

 

I will pass this over to another expert and see if they can step inhere and help

 

Thanks

Eric

26 days and 19 hours ago.

Reply

thanks for all you help. I'm just going to leave it as is for now im tired of messing with it.

Posted by Claws224 26 days and 18 hours ago.

Info Request

Ok,

 

I am sorry I was not able to get this sorted for you, However I am very sure this will be fixed in an update within the next 14 days as Microsoft are VERY aware of this issue.

 

I spoke to one of my Microsoft support specialist at the MS Small Business group and he has told me this is a big bug they are working on

 

Thanks

Eric

25 days and 5 hours ago.

Reply

I had hoped they already had an update for it but at least their working on it. Thanks

Accepted Answer

No problem,

 

I just got this from a technet blog and I dont know if it will work, However I thought it may be worth a try.

 

  • DISABLE ALL NETWORK ADAPTERS
  • ENABLE THE ADAPTER THAT'S ONLY SHOWING UP THE UNCHANGEABLE PUBLIC NETWORK
  • IN THE NETWORK AND SHARING CENTER, SELECT "CHOOSE HOMEGROUP AND SHARING OPTIONS"
  • CLICK ON "WHAT IS THIS LOCATION?"
  • SELECT HOME/WORK
  • RE-ENABLE ALL OTHER ADAPTERS
  •  

    Let me know if you have any luck


    Thanks

    Eric

    Picture
    Expert: Claws224
    Pos. Feedback: 99.5 %
    Accepts: 
    Answered: 10/28/2009

    IEEE Network Engineer, Microsoft

    approx 20 years of experience from software to hardware design

    24 days and 22 hours ago.

    Reply

    That worked, partially. I now have it set to a home location but still can't change the option in the standard fashion. It'll do though until MS gets a fix for it.
    Thanks!

    Posted by Claws224 24 days and 22 hours ago.

    Info Request

    Thanks for letting me know

     

     

    +
    Read More

    Related Computer Questions

    • Had a power outage while connect to aol, when power came bac...



    Disclaimer: Information in questions, answers, and other posts on this site ("Posts") comes from individual users, not JustAnswer; JustAnswer is not responsible for Posts. Posts are for general information, are not intended to substitute for informed professional advice (medical, legal, veterinary, financial, etc.), or to establish a professional-client relationship. The site and services are provided "as is" with no warranty or representations by JustAnswer regarding the qualifications of Experts. To see what credentials have been verified by a third-party service, please click on the "Verified" symbol in some Experts' profiles. JustAnswer is not intended or designed for EMERGENCY questions which should be directed immediately by telephone or in-person to qualified professionals.
    Question List | Become an Expert | Terms of Service | Security & Privacy | About Us
    © 2003-2009 JustAnswer Corp.