I don’t want to have my messages to the user stored in the application, or in a resource file.
By message I mean, those difficult strings that we have to write to tell the user what is going on or wrong in the application at the precise time.
Is there a simple message generator?
Simple stuff, but as to handle singular/plural and femin...
Hello,
I was told more than once that Delphi handles dynamic classes better than static.Thereby using the following:
type Tsomeclass=class(TObject)
private procedure proc1;
public
someint:integer;
procedure proc2;
end;
var someclass:TSomeclass;
implementation
...
initialization
someclass:=TSomeclass.Create;
finalizat...
On my Windows 7 system, the GetVersionEx Windows API function returns "6.0", indicating Windows Vista, when it should return "6.1".
If it matters, I used the following Delphi code:
function winver: string;
var
ver: TOSVersionInfo;
begin
ver.dwOSVersionInfoSize := SizeOf(ver);
if GetVersionEx(ver) then
with ver do
result...
Hey guys. I have a problem with StandardColorMap and MainMenu. I need to create ColorMap in one submenu. How to do it?
P.S.
I am programming with delphi 2007
...
I had code that worked fine when running in the context of the main VCL thread. This code allocated it's own WndProc() in order to handle SendMessage() calls. I am now trying to move it to a background thread because I am concerned that the SendMessage() traffic is affecting the main VCL thread adversely. So I created a worker thread ...
I want to make a Task Manager program that displays this information:
Image name
memory usage
PID
How can I do this?
...
In classic Delphi database application we have a form, a set of data-aware visual controls connected to TDataSets via TDataSources. If one wants to design database application using MVC model, where to place TDataSet components? Should they stay on form and therefore be a part of View? Or should they be encapsulated inside some Model obj...
I have a code, that checks the current date when a form is loaded, performs a simple calculation, and appends a SQL in Delphi. It works on Windows 7 with Delphi 7, and on another computer with Xp, but doesn't on 3 other computers with Xp. When the form is loaded it shows a "Type mismatch in expression", and points to the line after the a...
I have an application that uses tabs like the Chrome browser. Now I want to be able to open more forms and not be limited to only one form. These forms should act the same but if I close main form all forms are closed. How can I make all forms be equal, so no matter which form I close it only closes that form and not exit application bef...
Hi,
I just discovered this component and started working with it.
I understand that the whole concept of it is to initialize nodes on the go as they are needed but I need all of them to initialize instantly.
What is the smart way to do it?
The only thing I came up with is to use GetLast() after adding nodes.
I believe, there is a bett...
Can someone tell me how to set file permissions in Delphi 2006? I am using TINIFile.Create to create INI files in my application. The problem is that if I create the file while logged onto Windows as an administrator and then try to run the application as just a standard user and overwrite the INI file, I do not have permission to do s...
I can ask Delphi to build all configurations at once - by clicking on "Build configurations" and invoking "Make" command:
This will build all configurations, one after another.
The problem is that we have an IDE expert, which must react on compilation events. We register IOTAIDENotifier80 to hook events. There are BeforeBuild and Aft...
I have a DLL which provided a decoding function, as follows:
function MyDecode (Source: PChar; SourceLen: Integer; var Dest: PChar; DestLen: Integer): Boolean; stdcall;
The HostApp call "MyDecode", and transfer into the Source, SourceLen and Dest parameters, the DLL returns decoded Dest and DestLen.
The problem is: The HostApp impo...
We have a Windows desktop application written in Delphi that works fine on Windows 7, except that the icon of the main form looks blurry in Windows' new taskbar. As long as the application has not been started the icon looks fine (i.e. when it's pinned to the taskbar). Once it has been started Windows uses the icon of the main form (ins...
I get selection range like this:
var
Range: IHTMLTxtRange;
begin
if Supports((Document as IHTMLDocument2).selection.createRange,
IHTMLTxtRange, Range)
end;
TWebBrowser in editing. I need get position of cursor. How I can get its?
...
Can anyone recommend a cryptographically-secure pseudo random number generator library for Delphi (Win32)?
Can be free or commercial, but will ideally be an active project. I'd like it to include source code.
...
i profiled a portion of my application using the Delphi Sampling Profiler. Like most people, i see a majority of the time spent inside ntdll.dll.
Note: i turned on the options to ignore Application.Idle time, and calls from System.pas. So it
isn't inside ntdll because the
application is idle:
After multiple runs, multiple...
Hello all,
I'm trying to find a Delphi function that will split an input string into an array of strings based on a delimiter. I've found a lot on Google, but all seem to have their own issues and I haven't been able to get any of them to work.
I just need to split a string like:
"word:doc,txt,docx" into an array based on ':'. The res...
i am looking for an Delphi component to connect to an ORACLE database server in an direct way without install the oracle client.
i knew the Oracle Data Access (ODAC) from DevArt. there are any other component with this capability?
ODAC offers two connection modes to
the Oracle server: connection through
the Oracle Call Interface...
I have two files, one with webservice description (wsdl), second with data structures used in webservice (xsd). I have nothing more, webservice doesn't work yet. I need to merge them into one, because Delphi 7 WSDL Importer doesn't handle included xsd files to well. Where can I find tool to do it?
EDIT
I copied xsd content into <types>...