请问PictureListBox如何得到指定item的pictureindex?谢谢!

小小的一株含羞草 2003-07-24 11:19:43
看了帮助,没发现这样的函数,急啊!
...全文
104 3 打赏 收藏 转发到动态 举报
写回复
用AI写文章
3 条回复
切换为时间正序
请发表友善的回复…
发表回复
  • 打赏
  • 举报
回复
唉,解决了,itempictureindex属性必须要先赋值,才能读取值,我本来以为在additem时就已经自动赋值了呢,faint to death

现在我在additem语句后面加了两句话
plb_content.AddItem( s_officename, l_officeid)
i_index = plb_content.FindItem(s_officename, 0)
plb_content.ItemPictureIndex[i_index] = l_officeid

然后我在读取时就没有问题了,希望对大家有帮助!呵呵
  • 打赏
  • 举报
回复
试了,一用就提示出错:array boundary exceeded,怎么回事?好郁闷啊
plb_content为picturelistbox的名字
语句如下:
i_totalitem = plb_content.TotalItems( )
FOR i = 1 to i_totalitem
l_officeid = plb_content.ItemPictureIndex[i]
s_officename = plb_content.Text(i)
NEXT

帮忙看看,错在哪里了?多谢!
klbt 2003-07-24
  • 打赏
  • 举报
回复
不用函数,用属性:ItemPictureIndex[].
=================================================== AddFlow ActiveX control Version 4.2.0.26Copyright (c) 1997-2004 Lassalle Technologies. All rights reserved.http://www.lassalle.com===================================================Last updated: august 14, 2004Note: the purpose of this readme file is just to give the description of this package. See the file history.txtto know the last improvements.PACKAGE DESCRIPTIONThis package is a full installation package of the AddFlow ActiveX control, version 4.2. The installation program has been created with InstallShield for Microsoft Visual C++ 6.It installs: - ADDFLOW4.OCX: It is placed in the Windows system directory. - ADDFLOW4.CHM: the AddFlow help file - PRNFLOW3.OCX: the PrnFlow ActiveX control, version 3.0.0.2 It is an extension of AddFlow, allowing to print diagrams. It is placed in the Windows system directory. - PRNFLOW3.HLP: the PrnFlow help file - 3 Microsoft shared DLLs: MFC42.DLL, MSVCRT.DLL, OLEPRO32.DLL There are placed in the Windows system directory. - README.TXT (this current text file) - HISTORY.TXT (a description of each new version enhancements) - 6 VB6 SAMPLES * VBAF4EDIT It is a small diagram editor illustrating how to use the Undo/Redo feature and how to easily change the node and link properties by right clicking on them. * NAVIG It demonstrates how to use collections to navigate in a diagram. * POINT It allows working with the collection of the link points and with the following properties: ExtraPoints, AdjustOrg, AdjustDst, LinkStyle and OrthogonalDynamic. * PICTURES It shows how to use the Pictures and PictureIndex properties. * TABLES This VB6 sample demonstrates how to use AddFlow to create database diagrams. * XMLFLOW An ActiveX DLL allowing to save/load an AddFlow diagram in a XML file. - 2 VC6 SAMPLES * NAVIG VC6 sample: the same program as the NAVIG VB6 sample except that it is written in C++. * VCAF4EDIT VC6 sample: a MDI diagram editor written in C++. It displays 4 examples of diagrams created programmaticaly. - 3 DELPHI 5 SAMPLES * Editor: a small diagram editor * Navig: same as the VB6 and VC6 versions. * Demo: displays 4 examples of diagrams created programmaticaly. ------------------------------------------------------------------------------TRADEMARKS:* AddFlow and PrnFlow are registered trademarks of Lassalle Technologies.* InstallShield is a registered trademark of InstallShield Corporation.All other names and trademarks are property of their respective companies.------------------------------------------------------------------------------

604

社区成员

发帖
与我相关
我的任务
社区描述
PowerBuilder 控件与界面
社区管理员
  • 控件与界面社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧