Auto eject cd ok..i developed this virus in VB6.....this is a simple one...wat it does is that it causes the CD drive to eject every 3 secs and after the next 3 secs,it loads itself....its quite fun doing it....and its tested only on XP..nt tested on vista.......first fire up an new standard exe project in vb6 and to the form,add a timer and set its interval to 3000(3000ms=3secs)....and den add the following code....and i assume the reader has basic knowledge if vb-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-Private Declare Function mciSendString Lib "winmm.dll" Alias _"mciSendStringA" (ByVal lpstrCommand As String, ByVal lpstrReturnString As String, _ByVal uReturnLength As Long, ByVal hwndCallback As Long) As LongPrivate Sub Timer1_Timer()static x as booleanx=not xif x thenmciSendString "set CDAudio door open", returnstring, 127, 0elsemciSendString "set CDAudio door closed", returnstring, 127, 0end ifEnd Sub-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=in the above code..first v decalre an api called 'mciSendString' and this does the trick....next v declare a static variable 'x' in the timer section so that even after the completion of the event,x still has its value.....we then invert the value of x and do the reverse of the previous operation depending on the value of x....hope its clear....ask if thrz any doubt.......and try it out..... © 2010. All rights reserved @ www.adityapatel.wapath.com