Print Page | Close Window

ListBox Text property error (bug?)

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Suite Pro
Forum Description: Topics Related to Codejock Suite Pro
URL: http://forum.codejock.com/forum_posts.asp?TID=16443
Printed Date: 16 November 2024 at 5:55am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: ListBox Text property error (bug?)
Posted By: gibra
Subject: ListBox Text property error (bug?)
Date Posted: 14 March 2010 at 3:02pm
Why the Text property of ListBox is read-only?
 
I don't understand because Description say that we can Gets or sets, while Property Type say Read-only
The help file report:

Description

Gets or sets the text associated with this control.

Property type

Read-only property

 
This property should be read and write, for compatibility with VB.ListBox control.
Many times need to select a ListBox item we use the Text property and is a sample way to select the item, without know the Index.
 
I.e., if we don't know the Index property, the Codejock ListBox force us to do extra work to search for all items to compare Text with us string, then set item using ListIndex.
So, if anyone would to migrate from VB.ListBox to XtremeSuiteControls.ListBox, must re-code all reading of Text property!
 
Using VB.ListBox:
List1.Text = "MyItem"   <--- this not work XtremeSuiteControls.ListBox
 
Using Codejock.ListBox:
Dim idx as Long
For idx = 0 to List1.ListCount -1
    If List1.List(idx) = "MyItem" Then
        List1.ListIndex = idx
    End If
Next idx
 
I think to be inadvertence...
 
I hope you plain to remove this limitation.
 


-------------
gibra
CJ SuiteControl v: 13.x to 19.x
Windows 10 64bit
VS2019 - VB6.0 SP6
<a href="http://nuke.vbcorner.net/Home/tabid/36/language/en-US/Default.aspx" rel="nofollow">VS/VB 6.0 Installer v6.8



Replies:
Posted By: Baldur
Date Posted: 15 March 2010 at 11:22am
You can use simply use FindItem-Method.


Posted By: gibra
Date Posted: 15 March 2010 at 4:06pm
Thank you for reply.
 
OK, I know this, but the problem is different.
 
I explain: Codejock Controls is an 'enhanced replacement' for intrinsec VB controls (at least).
So, CJ.ListBox should be 100% compatible with VB.ListBox control. Instead isn't!
 
Moreover, this problem involve many other Codejock Controls.
 
When I want to migrate a VB project which use intrinsic VB controls, I would that the old VB control Properties and Methods should be supported in CJ Controls.
Instead I forced to rewrite a lot of code to solve the problems created by SuitePro because:
 
Many native Properties and Methods of VB controls not longer work in SuitePro.
 
Methods not supported. Example:
ListBox and ComboBox doesn't allow to add Item a design time.
ListView doesn't allow to create ColumnHeaders a design time.
 
Properties not supported. Example:
MouseIcon and MousePointer is missing on almost all of controls.
 
This is only a example, but there are many other methods and properties not supported by SuitePro.
Sincerely, after enthusiastic purchasing, I still discover day by day (with my disappointment) a lot of limitations in Codejock SuitePro ActiveX.
 
I don't know if I will renew my subscription next year...
 


-------------
gibra
CJ SuiteControl v: 13.x to 19.x
Windows 10 64bit
VS2019 - VB6.0 SP6
<a href="http://nuke.vbcorner.net/Home/tabid/36/language/en-US/Default.aspx" rel="nofollow">VS/VB 6.0 Installer v6.8


Posted By: Oleg
Date Posted: 16 March 2010 at 8:10am
Hello,
 
Thanks, we added "set" implementation for Text property.


-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net