Tag

convert

  • Total Source Code 5
  • Total Page : 1
  • You currently on page number : 1

convert a color image to grayscale

  • 13 January 2014
  • 154
  • image,photo,glayscale,convert

uses Windows, Graphics; function ConvertBitmapToGrayscale1(const Bitmap: TBitmap): TBitmap; var i, j: Integer; Grayshade, Red, Green, Blue: Byte; PixelColor: Longint; begin with Bitmap do for i := 0 to Width - 1 do for j := 0 to Height - 1 do begin PixelColor := ColorToRGB(Canvas.Pixels[i, j]); Red := PixelColor; Green Read more


How to convert Short to Long filenames

  • 20 December 2013
  • 230
  • delphi,longname,path,convert

The Source Code   uses Shellapi; function GetLongFileName(const FileName: string): string; var SHFileInfo: TSHFileInfo; begin if SHGetFileInfo(PChar(FileName), 0, SHFileInfo, SizeOf(SHFileInfo), SHGFI_DISPLAYNAME) 0 then Result := string(SHFileInfo.szDisplayName) else Result := Read more


convert minutes in a days / hours / minutes format

  • 20 December 2013
  • 242
  • delphi,format,date,time,hour,day,minutes,convert

Use this source code to convert minutes in a  days / hours / minutes format   function MinutesToDaysHoursMinutes(AMinutes: Integer): string; const HOURSPERDAY = 8; // tentukan / specify the current day job var Days: Integer; Hours: Integer; Minutes: Integer; begin if (AMinutes 0) then begin Hours := AMinutes div 60; Minutes := AMinutes mod 60; Days Read more


Convert hexa to decimal

  • 30 December 2013
  • 168
  • hexa,decimal,convert

This is source to convert Hexa to Decimal format;   function HEX_to_DEC(Value: string): Int64; var Lunghezza, i : Byte; ValoreDEC: Int64; Value2 : string; begin Result := 0; for i := 1 to Length( Value ) do Value2 := Value[ i ] + Value2; Value := Value2; for Lunghezza := Length(Value) - 1 downto 0 do begin ValoreDEC := Pos(Value[Lunghezza Read more


Convert Decimal to Biner

  • 30 December 2013
  • 426
  • convert,decimal,biner

this is simple way to convert decimal to biner   //result 1100 //result Read more




Category