1) there should be .iso file of windows (7 or 8)
2) install virtual dvd drive software e.g magic iso or power iso
3) mount the windows 7 .iso image to virtual dvd drive
4) open cmd as administrator
5) TYPE COMMAND
LIST DISK
SELECT DISK # /* where # is the your flash drive
CLEAN
CREATE PARTITION PRIMARY
SELECT PARTITION
ASSIGN
FORMAT FS=NTFS QUICK
ACTIVE
EXIT
XCOPY /S/E/F S:\*.* D:\ /* after /s/e/f S is your source drive (virtual drive)
D is your flash drive