I use scp which is a secure copy over SSH. First get SSH installed and running on the Linux machine.
On the Windows machine install WinSCP
once thats connected it's almost as simple as drag and drop to transfer files using a a nice split screen for files.
But a script would be a little more challenging...off hand I know of a way with FTP but then you'd have to set up the Windows machine as a FTP server. I think we need more details on what you are trying to do, like does the Windows machine have any open shares or anything that we can use?
I am new to this forum, I want to write a script which will transfer files from linux to windows,
on my Linux server ftp is disabled,
On your Linux machine create a script that will use smbclient to transfer your file which might look something like this:
======================= CAUTION : UNTESTED!!! =====================
I just wrote this on the fly...
====================== USE AT YOUR OWN RISK!!! ====================
# Transfer a file to a windows machine using smbclient
# Script by hardwyrd (c) 2008
# cp2win switch host-folder file remote-username remote-password
# cp2win nologin \\\\myserver\myshare myfile.txt
# cp2win \\\\myserver\myshare myfile.txt myuser mypassword
# nologin - turns on using login credential
# host-folder: must be in the format \\\\machine\folder