procedure TForm1.Button8Click(Sender: TObject);
var
image:tgpimage;
guid:tguid;
I,J : Integer;
begin
J:=0;
for k:=0 to Listbox1.Items.Count - 1 do
begin
ListBox1.ItemIndex := k;
form1.Refresh;
if k <> -1 then
begin
image:=tgpbitmap.create(ListBox1.Items.Strings[k]);
image.getframedimensionslist(@guid, 1);//得到多帧tif文件的页数
i:=image.getframecount(guid); end;
ListBox1.Items.Strings[k]:= ListBox1.Items.Strings[k]+'----------'+inttostr(i)+'页' ;
J:=I+J;
end;
y:=j;
edit1.text:='共搜索到TIF文件'+inttostr(listbox1.Items.Count)+'个!---统计页数总计:'+inttostr(j)+'页!';
messageBox(0,PChar('统计完成!总计页数'+inttostr(j)+'页!'),PChar('计算完成'),0);
end;
超过2000+条后,i值都为0,还出现EOUTOFRESOURCES “UNABLE TO INSERT A LINE”,求大虾帮助!谢谢
var
image:tgpimage;
guid:tguid;
I,J : Integer;
begin
J:=0;
for k:=0 to Listbox1.Items.Count - 1 do
begin
ListBox1.ItemIndex := k;
form1.Refresh;
if k <> -1 then
begin
image:=tgpbitmap.create(ListBox1.Items.Strings[k]);
image.getframedimensionslist(@guid, 1);//得到多帧tif文件的页数
i:=image.getframecount(guid); end;
ListBox1.Items.Strings[k]:= ListBox1.Items.Strings[k]+'----------'+inttostr(i)+'页' ;
J:=I+J;
end;
y:=j;
edit1.text:='共搜索到TIF文件'+inttostr(listbox1.Items.Count)+'个!---统计页数总计:'+inttostr(j)+'页!';
messageBox(0,PChar('统计完成!总计页数'+inttostr(j)+'页!'),PChar('计算完成'),0);
end;
超过2000+条后,i值都为0,还出现EOUTOFRESOURCES “UNABLE TO INSERT A LINE”,求大虾帮助!谢谢
解决方案 »
- 如何在Calendar控件的单元格中写入数据?
- 关于SOCKET编程的书籍
- 求查询及操作ARP表的源代码.
- TQRRichText 可以设置行间距了,为什么TQRDBRichText就不可以哦????
- FastReport 怎么快速入门??原来用QR的,最简单的就好,怎么做?能几分钟内会吗?
- RichEdit如何在指定的位置打印RichEdit框内的内容, 并且保持所有字符的字体不变,每行的字数不变(不输入回车键)?
- 过了四级,散分!
- 如果要将DELPHI程序员分类,大家认为应该如何分类呢?分类依据是什么?
- 如何用DELPHI得到一个文件的版本等信息?
- delphi没救了!改学C++吧。
- 关于修改的dbgrideh中内容的问题
- ACReport中国式报表控件2010版(含文档和demo)
begin
image:=tgpbitmap.create(ListBox1.Items.Strings[k]);
image.getframedimensionslist(@guid, 1);//得到多帧tif文件的页数
i:=image.getframecount(guid);
// LABEL2.Caption:=INTTOSTR(I);
// if i=0 then
//edit1.text:= ListBox1.Items.Strings[k];
end;
// ListBox1.Items.Strings[k]:= ListBox1.Items.Strings[k]+'----------'+ListBox1.Items.Strings[k]+'页' ;
J:=I+J;
Y:=Y+1;
if i=0 then BEGIN
LABEL2.Caption:=INTTOSTR(Y);
edit1.text:='共搜索到TIF文件'+inttostr(listbox1.Items.Count)+'个!---统计页数总计:'+inttostr(j)+'页!';
messageBox(0,PChar('统计完成!总计页数'+inttostr(j)+'页!'),PChar('计算完成'),0);
END;
END;
end;添加判断后测试1523条后,I值都为0
i是从这来的,继续跟啊
跟踪了一下内存,坑爹啊!谢谢bdmh