Application179 drawgrid 에 그림 그리기. var a:TRect; begin a:=DrawCell.CellRect( ACol,ARow ); DrawCell.Canvas.Draw(a.left,a.top,Bitmap); end; if (ACol =0) and (ARow > 0) and (Cells[0, ARow]'') then begin Try CarStateBitmap := TBitmap.Create ; ImageList1.GetBitmap (StrToInt(Cells[0,ARow]), CarStateBitmap); Canvas.FillRect (Rect); nBitmapLeft := Trunc(Rect.Left + ((Rect.Right - Rect.Left)/2) - (CarStateBitmap.Width /2)); Canvas.Draw(nBi.. 2008. 8. 13. 레지스트리 쓰고 읽기 uses Registry 추가 procedure TForm1.Button3Click(Sender: TObject); Var Reg : TRegistry; strRegData : string; begin Reg := TRegistry.Create; try reg.Rootkey := HKEY_CURRENT_USER; //reg.OpenKey('\SOFTWARE\',TRUE) //Reg.KeyExists('GrsSystem') Reg.OpenKey('\SOFTWARE\GRSSYSTEM\',TRUE); Reg.WriteString('GrsDBConnectString',edit3.Text); finally reg.Free; end; end; procedure TForm1.Button2Click(Sender: TO.. 2008. 8. 13. string에 바이너리 파일 그대로 집어넣기 var data : String; fStream : TFileStream; mStream : TMemoryStream; sStream : TStringStream; begin try fStream := TFileStream.Create('파일이름', fmOpenRead); mStream := TMemoryStream.Create; sStream := TStringStream.Create(''); mStream.LoadFromStream(fStream); mStream.SaveToStream(sStream); data := sStream.DataString; finally sStream.Destroy; fStream.Destroy; mStream.Destroy; end; end; 2008. 8. 13. 시작 프로그램 등록 uses Registry; procedure ----------------- var Reg : TRegistry; begin Reg := TRegistry.Create; Reg.RootKey := HKEY_LOCAL_MACHINE; Reg.OpenKey('Software\Microsoft\Windows\CurrentVersion\Run', true); Reg.WriteString('Test', Application.ExeName); Reg.CloseKey; end; 레지스트리 'Software\Microsoft\Windows\CurrentVersion\Run 여기다가 등록시키면 될겁니다..허접의 답변입니다.. 2008. 8. 13. 이전 1 ··· 24 25 26 27 28 29 30 ··· 45 다음