Yes you can, you can either define the ip address and such yourself or let windows do all the hard work either by using the cable directly into one pc to the other or over a router.
last time I did this one computer was hard wired into a router and my laptop was done over wifi and windows did the rest, info showed up under networked pcs, you then need to ensure that both pcs have a username and password and that the folders you wish to share are being shared and then the connected computers come up under the network bit in xplorer, it will then ask you to log on to the pc as you would do if you were using it and it will then display the shared files, then copy and paste, the desired files.
I cant believe this has slipped my mind exactly how to do it defining the ip address and I havent got a way to test it, but I think it is coming back to me, improved networking in windows makes it easy to be lazy lol.
I am not sure if this method works if you just use a cable from one computer into the other, it should do tbh, but the other way is to define the IP address.
Go to network connections and choose the desired adapter and then right click and choose properties and then ipv4 and then configure.
On one computer set the ip as something like 192.168.1.5.
One the other set the IP as 192.168.1.6.
both computers need to have the same subnet which should automatically come up as 255.255.255.0 and leave the default gateway and dns servers blank as they are not relevent unless you want to share and internet connection.
You need to ensure netbios over tcp/ip is enabled, which I think it is in win 7 by default, that is under the wins tab as shown in this ss.
then same as above computer should show up on the network and you need to access it and ensure your files are shared, last time I did this I found it really helpful if both computers had a password as well as a username, ie you need to type a password in to logon to your computer.
Should show up where it says network here.