To stop sharing a folder in Windows, please follow the instructions corresponding to your current operating system (in case you are not clear which operating system you are using, follow the guide here):
Stop folder sharing in Windows XP
Stop folder sharing in Windows 7
Stop folder sharing in Windows Vista
Stop folder sharing in Windows XP
To stop sharing a folder in Windows XP, follow the below steps:
Step 1: Open My Computer. On Menu bar, choose Tools/Folder Options…

Step 2: In Folder Options window, choose View, scroll to the end, check Use simple file sharing (Recommended) (see the following picture) then click OK

Step 3: Right-click on the folder to stop sharing, choose Sharing and Security…

Step 4: In the window appears afterward, uncheck box Share this folder on the network then click OK to finish.

Stop folder sharing in Windows 7
To stop sharing a folder in Windows 7, follow these below steps:
Step 1: Click Start in Search programs and files box

Type in "folder options" then press Enter
Step 2: In Folder Options window, click View, scroll down to the end, tick Use Sharing Wizard (Recommended), press OK

Step 3: Right click on the folder to stop sharing, choose Share with / Nobody

Step 4: When File Sharing window appears, choose Stop sharing

Stop folder sharing in Windows Vista
To stop sharing a folder in Windows Vista, follow these below steps:
Step 1: Open Computer. On Menu bar, choose Tools / Folder Options…

Step 2: In Folder Options window, choose View, scroll down to page end, check box Use Sharing Wizard (Recommended) (see picture below) then click OK

Step 3: Right click on the folder to stop sharing, choose Share…

Step 4: File Sharing window appears, choose Stop sharing

Step 5: If Windows UAC function is being turned on, User Account Control window will appear, click Continue (in case UAC is being turned off, continue with Step 6)

Step 6: Click Done to finish

Bkav