I'm using StringGrid. My problem is to fill up cells with long strings. I don't know how to check which string is to long for the cell. In other words I don't know how to check string width. If somebody could help I would be very grateful.
You can use for it TBitBtn component. You must clear BitBtn caption, set BitBtn->Glyph->Canvas width and height to required size. Next draw on it using functions like TextOut or TextRect. By this you can make as much lines as you want. Other, easiest but not economic way is to write your text in...
If you are using Form->Handle you cannot flash taskbar icon. If you want do it you must use Application->Handle in parameter pf.hwnd. I think that for flashing both easiest way is to call out FlashWindowEx two times. One with Form1->Handle and second with Application->Handle.
Good luck!!
I was thinking about creating three labels and using central as link. It's very easy and you don't have any problems with seting up look of it. Of course if you want you can do it all in one label using GetFontMetrics function but it isn't working perfectly and changing look of one word to link...
As Supernat03 said there are better ways to resolve this problem. To send a mail you can use ShellOpen function. Just copy my code to label OnClick event and change font property to liken it to hyperlink.
//---------------------------------------------------------
String s...
I think that this code should solve your problem. I'm not sure is this what you want but you can always change that sample :)
int SelItem;
//---------------------------------------------------------------------------
void __fastcall TForm1::ListBox1MouseDown(TObject *Sender,
TMouseButton...
I'm developing a multi thread application and I don't know is there any other way to send params to thread than constructor. Can I send params to thread while he is working??
Below is a short sample. "this" is a pointer to the object for which the function is called.
TImage *im;
//-----------
void __fastcall TForm1::FormCreate(TObject *Sender)
{
im=new TImage(this);
}
//---------------------------------------------------------
void __fastcall...
I don't know what caused this problem but if you want to avoid it you must add at beginning of cpp file this:
#define NO_WIN32_LEAN_AND_MEAN
I'm sure it will work.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.