VCL 如何加载Gif图片和Png图片

加上头文件#include

<Vcl.Imaging.GIFImg.hpp>

#include <Vcl.Imaging.pngimage.hpp>

Image1->Picture->LoadFromFile("001.gif");
((TGIFImage*) Image1->Picture->Graphic)->Animate = true;//开始播放
((TGIFImage*) Image1->Picture->Graphic)->Animate = false;//停止播放

Image2->Picture->LoadFromFile("001.png");

原文地址:https://www.cnblogs.com/mypsq/p/5130447.html