If you are interested in creating true antivirus with real time scanning, you must have capability to know how to use language capable of core level functions. C++ ASM for example.
If you wish to create a file scanner, you can read for example all files in a folder and search for them for special virus signatures. The problem here is how to get the virus signatures. Antivirus programs always secure their own signatures, so that they do not get tampered with.
Other method is to use something called heuristic analysis. You search possibly malicious code sequences from executables without knowing if the file itself contains any specific virus signatures.
Reference
Link-[how can i make an antivirus][
^]
There are lots of question in CP Titled Create Anti virus in C#. take a look at given CP question for getting perfect and expert answer
learning to build an antivirus[
^]
Internet Security or antivirus development[
^]
For more Information take a look
there[
^]