목록Programming/Delphi (18)
C#,Delphi,Oracle,MSSQL 개발자블로그
General Keyboard Shortcuts Shortcut Menu Action F1 Opens the help topic on a selected item. Ctrl+F11 File > Open Project Opens a project file using the Open Project dialog. Ctrl+S File > Save Saves only the module that is currently open in the IDE (and any associated header files). Shift+Ctrl+S File > Save All Saves all the files for the current project. Alt+F11 File > Use Unit Opens the Use Uni..
1. 개요 특정 프로그램이 실행 중인지 여부를 판단하기 위한 두가지 방법 2. 프로그램 실행 파일명을 이용한 실행여부 판단 ? 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 uses TlHelp32; function processExists(exeFileName: string): Boolean; var ContinueLoop: BOOL; FSnapshotHandle: THandle; FProcessEntry32: TProcessEntry32; begin FSnapshotHandle := CreateToolhelp32Snapshot(TH32CS_SNAPPROCESS, 0); FProcessEntry..
TButton은 가장 기본적이고, glyph 설정이 힘든 컨트롤이다. TBitBtn은 TButton의 모든 특징을 갖고 있으며, glyph 설정을 할 수 있다. TSpeedButton은 TButton, TBitBtn과 다르게 탭 포커스를 갖지 않는다. 즉, TSpeendButton을 눌러도 포커스가 변화하지 않는다. 출처 : http://www.chami.com/tips/delphi/020597D.html
본문 TEdit를 비롯하여 EDIT 컨트롤에 숫자만 입력받도록 하는 방법은? 여러가지가 있겠지만 간단히 GWL_STYLE을 변경해주므로 가능합니다. 가끔 필요한데 생각이 나지 않아서 찾아야 하는데.. 찾는 수고를 덜기 위해서 여기에 .... @C++Builder에서 void __fastcall TDLG_MANAGE::FormCreate(TObject *Sender) { SetWindowLong(Edit1->Handle,GWL_STYLE,GetWindowLong(Edit1->Handle,GWL_STYLE)|ES_NUMBER); } @ Delphi 에서 procedure TForm1.FormCreate(Sender: TObject); begin SetWindowLong(Edit1.Handle,GWL_STYL..
델파이 프로그램 실행 과정 프로그램실행 시작 과정 프로그램이 실행되면 application객체게 생성되면서 application객체의 componentcount속성의 갯수만큼 폼객체가 생성되고 폼이 생성될때마다 폼객체의 componentcount의 갯수만큼 컴포넌트가 생성됩니다. 프로그램실행 종료 과정 application객체의 componentcount의 갯수만큼 폼을 차례대로 종료합니다. 각각의 폼은 componentcount의 갯수만큼 컴포넌트를 하나씩 종료하고 다종료되면 form도 종료됩니다. 이후에도 application의 갯수만큼 form이 차례로 종료됩니다. ※ 수동 생성시 인자로 application,self의 입력 .create(application); //application객체에 포함..
RAD Studio(Delphi, C++빌더) 단축키 입니다. (엠바카데로 문서 자동 번역 후 일부 보정했습니다.) 컴파일 시 여러건의 오류를 이동하는 단축키를 묻는 분이 있어 찾아보니 Alt + F7, Alt + F8이 있었네요.(저도 모르고 여지껏 마우스로 클릭했네요.^^) 다양한 단축키 알아두시면 개발도 빠르게 하고, 디버깅도 빠르게 할 수 있겠네요. 바로 가기 작업 Alt + [ 해당 구분 기호를 찾습니다 (앞으로). Alt + ] 해당 구분 기호를 찾습니다 (역방향). Alt + ← Alt + ↑ 또는 Ctrl + 클릭 (선언 부로 이동) 작업 이전 위치로 돌아갑니다. Alt + F7 Messages View에 표시되기 전에 오류 또는 메시지의 위치로 이동합니다. Alt + F8 Messages..
* DLL에서 읽을 함수.(testMessage.dll) function MSG(s:string) : string; export; begin s := '[' + s + ']'; Result := s; end; 1. 핸들러를 이용하여 동적으로 사용하기. uses windows procedure TForm1.Button1Click(Sender: TObject); type TFunc = function(s:string) : string; var Handle : THandle; MyFunc : TFunc; begin Handle := LoadLibrary('testMessage.dll'); if Handle 0 then begin @MyFunc := GetProcAddress(Handle, 'MSG'); if ..
1. File -> New -> Other 에서 DLL Wizard를 선택한다. 2. 예제소스 uses SysUtils, Classes, Dialogs; {$R *.res} /// /// 문자열 반환 테스트 /// function MSG(s:string) : string; export; begin s := '[' + s + ']'; Result := s; end; /// /// 메세지박스 테스트 /// procedure MessageBoxBox; export; begin ShowMessage('message test'); end; exports MSG, MessageBoxBox; begin end.