I have Bass component from http://www.un4seen.com/bass.html. I load mp3 and triying to change the format to PCM but it wont do nothing?
or any suggestion will be appreciated.
I'm using a form with an IdTCPServer on it managing strings from the client with a AThread.connection.readln/writeln system. The string handling works and that isn't the problem.
The thing is, the form with the server on it hangs and will not load, but it still managed all the clients connected to it so it IS running but it just doesn't work as…
I need to convert a binary file (a zip file) into hexadecimal representation, to then send it to sql-server as a varbinary(max) function parameter.
A full example (using a very small file!) is:
1) my file contains the following bits 000011110000111
2) I need a procedure to QUICKLY convert it to 0F0F
3) I will call a sql server function…
I have an app that opens a non-modal form from the main form. The non-modal form has a TMemo on it. The main form menu uses "space" as one of its accelerator characters.
When the non-modal form is open and the memo has focus, every time I try to enter a space into the memo on the non-modal form, the main form event for the "space"…
I'm working with a TMemo component to display some text in a limited space. Currently it's using a truetype font which doesn't ship with windows and is installed by the app when it runs.
On my PC (Running Windows XP), the spacing between each line of text seems to be about eight pixels. On a different PC running Windows 7, the line…
Hi!
Many times we experienced after Windows 98 era that some dialogs are lost their Z-Order, and moved back to prior form.
For example:
Dialog1.ShowModal;
Dialog1.OnClickButton() : ShowMessage('anything');
When MessageBox appears, sometimes not got focus, it is moved under Dialog1.
The users confused on it, because they are…
Ok, this, I'm sure is something simple that is easy to do.
The problem :
I've inherited scary spaghetti code and am slowly trying to better it when new features need adding - generally when a refactor makes adding the new feature neater.
I've got a bunch of code I'm packing into a single unit which, in different places in…
I can only translate my application to my language using TcxLocalizer at runtime, but I need this working also in design-time.
Does anyone has some suggestion?
Thanks in advance
For performance tests I need a way to measure the time needed for a form to load its definition from the DFM. All existing forms inherit a custom form class.
To capture the current time, this base class needs overriden methods as "extension points":
start of the deserialization process
after the deserialization (can be…
For performance tests I need a way to measure the time needed for a form to load its definition from the DFM. All existing forms inherit a custom form class.
To capture the current time, this base class needs overriden methods as "extension points":
before the beginning of the deserialization process
after the…
I've got a report that's supposed to take a grid control and produce HTML output. One of the columns in the grid can display any of a number of values, or <Any>. When this gets output to HTML, of course, it ends up blank.
I could probably write up some routine to use StringReplace to turn that into…
Good day,
I had tried to make recurrent function to return a TValue as a n-dimensional. matrix(2D, 3D, 4D...)
for example, this procedure will show a n-dimensional matrix(it will list all elements from a n-dimensional matrix as TValue variable):
Procedure Show(X:TValue);
var i:integer;
begin
if…
i have a method:
procedure Frob(Sender: TObject);
that i want to call when i click a menu item.
The method comes to me though an interface:
animal: IAnimal;
IAnimal = interface
procedure Frob(Sender: TObject);
end;
The question revolves around what to assign to the OnClick event handler of…
I am using Stretched=True on a TBitmap with a 256x256 image. This gets scaled down by 1,2,4 or 8. As expected, text on the bitmap gets more horrible the more I depart from '1'.
I notice though that Windows 7 explorer renders a scaled down version of the bitmap 'softer' and more pleasing. Is it…
I'm having trouble getting my dll to work when using explicit linking. Using implicit linking it works fine. Would someone google me a solution? :) No, just kidding, here's my code:
This code works fine:
function CountChars(_s: Pchar): integer; StdCall; external 'sample_dll.dll';
procedure…
I have read a text file (of names) into an array and I need how to sort those names into alphabetical order and display that in a rich edit?
Please give me the code from this point onwards:
readln(myfile,arr[i]);
'myfile' is the text file and 'arr' is the array of string.
Also, I have…
I'm reading a component from a stream, and want to be able to specify the Owner property.
var TComponent : comp;
stream.Seek(0, soFromBeginning);
comp := stream.ReadComponent(nil);
Who owns comp, and how can I change it? I'd hoped the parameter to readComponent would be the…
This seems like a no-brainer but I couldn't find anything on it.
How do I detect if a date variant in Outlook is "empty"? For example TaskItem.DueDate - the duedate is not necessarily filled.
If it's not filled Outlook returns "4501.01.01." - I can test for this value, but this…
Hello all,
my question is stated in the title. How exactly do I do that?
I have an open connection and I want to "hijack" it and send my custom messages through it. From my understanding that is done with sockets and their handlers.
Any language would do but C#.NET is…
Is there a way to get a localized description of a shortcut like Ctrl+Z so that I get "Ctrl+Z" if the app runs on an English system and "Strg+Z" on a German system?
The VCL function ShortCutToText isn't internationalized. The API function GetKeyNameText is a bit better…