We have bought the TMS Component pack dto do a "facelift" on our apps.
I am trying to create a descendant of TAdvDateTimePicker to get its border and buttons draw according to what I want.
The border no problem - I made it for an TAdvEdit descendant and for the TAdvDateTimePicker was no problem (with the border).
But the buttons, what p...
Hi.
I just activated the themes in my Windows XP (usually I work using the classic Win9x look) and I have seen that two panels are pure black. Other panels are ok (color = clBtnFace).
What these 2 panels have in common is their parent. Both are placed directly on a TForm. If I move them to a different parent (another panel for example) t...
This is a continuation of a previous post: TPanel color is black no matter what
The problem is this: All TPanels that have a TForm as parent, turn black when I use a XPManifest. Anybody knows why?
...
With Delphi-6 there are two options: Build and Compile.
I know when I run a program it compiles only the files which have changed and uses the DCUs for those which haven't. When I click build apparently it rebuilds the DCUs.
What I have been wondering is, when I make a program for release (changing build settings, conditional variable...
This is my code... curX and curY are my current X and Y coordinates while tmpX and tmpY are relative X and Y values (how much the mouse has moved).
curX:= curX+tmpX;
curY:= curY+tmpY;
I use these values to move/control my cursor-shaped form.
How can I keep the cursors within the screen?
I tried limiting the values until Screen.Heigh...
I need to generate a report/printout programmatically.
My app currently uses FastReport to build a report, consisting of text, images, tables etc.
It does not bind to any database. Everything is built programmatically.
However, the finished report does not look the same in PDF and RTF, and the old code is generally very complicated.
...
I need to create a simple Delphi application, kiosk style.
It is a very simple thing, a single form where the user writes some personal info to register to an event. 4 TEdit and a TButton.
What I want to achieve is to avoid the user does any action different then typing in TEdit or clicking on the TButton. For example I don't want he d...
I have an application for storing many strings in a TStringList. The strings will be largely similar to one another and it occurs to me that one could compress them on the fly - i.e. store a given string in terms of a mixture of unique text fragments plus references to previously stored fragments. StringLists such as lists of fully-qua...
I am using context_info to simulate a global variable, I use it in this context.
I have scripts made up of several batches, I set a global variable at the beginning (123 in the example) and then after all the batches I use that number to populate a log table.
Now this works, but today it failed on one machine, I cannot figure why. Is t...
I need to run a script like
EXEC sp_dbcmptlevel AdventureWorks, 100;
GO
Now I'd like to have a generic version that uses the database I am connected to, is it possible in T-SQL?
Something like this, but this doesn't work:
EXEC sp_dbcmptlevel DBNAME(), 100;
GO
It doesn't work of course because a string is returned, I'd like to have...
I have an Application that is based on loaded test programs, saved as text-based files in a specific user data folder. All fine. A client has just commented that they would like to have full traceability of changes to such test programs (for ISO9001 etc) and it occured to me that I could provide some kind of checkout / commit mechanism a...
I'm using a listbox to display a simple list of filenames. I also have an edit component that allows me to search those items via a simple:
procedure TForm1.Edit1Change(Sender: TObject);
const
indexStart = -1;
var
search : array[0..256] of Char;
begin
if edit1.Text='' then exit;
StrPCopy(search, Edit1.Text) ;
ListBox1.ItemInde...
New to delphi and database programming in general but am curious if there is a better way to swap records in a TDataset? I have read through some help and cant find any obvious methods. Currently I have a procedure implemented to move records down the dataset until they hit the Eof marker. However I am getting some odd errors when I get ...
I want to create a game in Delphi
Is there any good game engine for Delphi?
based on directx 10 or OpenGL?
I need it for 3D games, or only I can do that with C++?
...
Hello everybody,
I'm having problems resizing a TPaintBox and drawing on it:
On my Form (named FMain) I dropped a TPaintBox (named DisplayImage), which I am trying to resize as the Form is resized.
To do that I wrote an OnResize() method for FMain (I confirmed that it's being called correctly) in which I try to resize the DisplayImage...
Tonight I tried to attempt an ExtPascal application. I am using Delphi 2009.
I followed all the steps in the Getting Started section and after some fights I was able to type
http://localhost/cgi-bin/ExtPascalSamples/
in the browser and see (almost) this effect (almost, last 3 panels had some display problems, the Show source code bu...
I have an app with a TPageControl on the main form. The pagecontrol has several tabs. The app can be minimized to a tray icon. Sometimes after running minimized for a while, when I restore the main window (via a right-mouse click on the tray icon), the tab that was last displayed is displayed, but I can't select any other tabs!
If I ...
I have these little cursor shaped forms that I need to be on Top of everything, all the time...
FormStyle is already fsStayOnTop
I use this code:
SetWindowPos(tempCursor.Handle, HWND_TOPMOST, 0, 0, 0, 0, SWP_NOMOVE or SWP_NOSIZE or SWP_NOACTIVATE );
and this (even though I don't exactly know what it does):
procedure TCursorFrm.Creat...
I've been using Delphi for a little over a month, but I still do not know the proper way of doing things.
If I have methods which I can use on a lot of projects should I put them on a Unit, Form or DataModule?
I have not used a unit (in itself), New-> Unit. Should I put my utility methods there? If so, is there an example I can look at,...
i got an error message type of expression my be boolean..how i want to solve this problem
function GetModeratedFormName(sSourceModuleName: String) : TForm;
begin
if AdditionalModerator(sSourceModuleName) then exit;
if sSourceModuleName = 'frmCI' then
RESULT := frmCI;
end;
...