I have a layered window created using the UpdatedLayeredWindow windows function. I'm alpha blending a bitmap to achieve a nice smooth border around the window.

Whenever the window opens, all the controls are invisible. They're still there as I can cause button events to still trigger but you can't see them.

Any ideas whats wrong or how to solve this? I've tried changing the form event at which UpdateLayeredWindow is called and repainting the form at runtime, nothing seems to make the controls visible again.

I created a form as form1
I placed two buttons as button1 and button2
button1

procedure TForm1.Button1Click(Sender: TObject);
begin
form1.AlphaBlend:=True;
end;

and the button2

procedure TForm1.Button2Click(Sender: TObject);
begin
form1.AlphaBlend:=False;
end;
{
of course my form1.AlphaBlendValue set to 100 to make the window transparent
}

and it is working,when I push the button1 then the window(form1) is translucent,and after pressing button2 every controls are seeable and working

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.