Wednesday, 9 January 2013

Ceil function in VB6

VB Code:
  1. Function Ceiling(n As Double) As Long
  2.     If Not Int(n) = n Then
  3.         Ceiling = Int(n) + 1
  4.     Else
  5.         Ceiling = n
  6.     End If
  7. End Function

Tuesday, 18 December 2012

Remove autorun.inf file

Remove autorun.inf file


1) Going to the first step, Please Disable CD or DVD/USB autorun in the windows


2) Open the Winrar.exe ( start > Programs >Winrar> Winrar.exe )
                                       

3) Now browse the infected file through the Winrar application


4) We can watch the hidden files for the particular drive using Winrar now.


5) Look for the file autorun.inf and open by using Notepad


6) When you open, We can find a >exe file in that.It is the main danger .


7) Note this .exe file and close the autorun.inf file


8) Now look for that .Exe file in the Drive (e.g d:/ ) ,Now delete the autorun.inf file and .exe file together


9) Restart your system, now there is no virus in your system.

Saturday, 1 September 2012

reset userdata to developer

"C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE\devenv.exe" /resetuserdata 

Wednesday, 27 June 2012

sum of hours between two dates in sql

SELECT
    CONVERT(VARCHAR(6), DATEDIFF(SECOND, '2012-06-26 03:00:00.000', '2012-06-27 23:30:00.000')/3600) + ':'
    + RIGHT('0' + CONVERT(VARCHAR(2), (DATEDIFF(SECOND, '2012-06-26 03:00:00.000', '2012-06-27 23:30:00.000') % 3600) / 60), 2) + ':'
    + RIGHT('0' + CONVERT(VARCHAR(2), DATEDIFF(SECOND, '2012-06-26 03:00:00.000', '2012-06-27 23:30:00.000') % 60), 2)

courtesy Mr.Vanthiya Thevan

Tuesday, 19 June 2012

mouse wheel working in VB6 IDE

http://support.microsoft.com/kb/837910
Download the VB6 Mouse Wheel.exe file that includes the add-in DLL and the code that is used to create the add-in DLL.
  1. Download the VB6 Mouse Wheel.exe file. The following file is available for download from the Microsoft Download Center:
    Download
    download dll
    For more information about how to download Microsoft support files, click the following article number to view the article in the Microsoft Knowledge Base:
    119591  How to obtain Microsoft support files from online services
    Microsoft scanned this file for viruses. Microsoft used the most current virus-detection software that was available on the date that the file was posted. The file is stored on security-enhanced servers that help prevent any unauthorized changes to the file.
  2. Click Start, click Run, type regsvr32 <path>\VB6IDEMouseWheelAddin.dll, and then click OK.
  3. Start Visual Basic 6.0.
  4. Click Add-Ins, and then click Add-in Manager.
  5. In the Add-in Manager list, click MouseWheel Fix.
  6. Click to select the Loaded/Unloaded check box, and then click to select the Load on Startup check box.
  7. Click OK.
Try it your own risk...

Monday, 18 June 2012

To find which installer you have installed in windows

go to c:\windows\system32 and locate the file msi.dll right click on that file-properties-version thats it.

start - run- msiexec press enter key.

kill a process using name and id

Just run it like this to use the process name.
TASKKILL /F /IM "notepad.exe"
Or this to kill it based on the process ID:
TASKKILL /F /PID 1234

start->run-> c:\> TASKKILL /F /IM "notepad.exe" press enter

the task will terminate.