KiXforms Forum Index KiXforms
The Forum for the KiXforms Community
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
 Quick Links 
Site News
Downloads
Documentation
Donations
Script Archive
Tracking Systems

Remove all items from combobox

 
Post new topic   Reply to topic    KiXforms Forum Index -> KiXforms.NET Discussion
View previous topic :: View next topic  
Author Message
Mart
KiXforms Regular
KiXforms Regular


Joined: 03 Oct 2005
Posts: 57
Location: Rotterdam - Netherlands

PostPosted: Tue Nov 11, 2008 12:14 pm    Post subject: Remove all items from combobox Reply with quote

Is there any way to remove all items from a combobox in KF.net

I've been searching here but did not find anything useful yet.

I tried
Code:

For Each $item in $ComboBox.Items
   $ComboBox.Items.Remove($item)
Next


but that is not working. It only removes the selected item.

Been looking at the code and trying some variations this morning but all failed. This is a part of a function that gets executed when a button is clicked.

Any help is appreciated.

_________________
Mart

- He's chained forever to a world that's departed.....It's not enough, it's not enough - Sorrow by Pink Floyd.
Back to top
View user's profile Send private message
Mart
KiXforms Regular
KiXforms Regular


Joined: 03 Oct 2005
Posts: 57
Location: Rotterdam - Netherlands

PostPosted: Tue Nov 11, 2008 12:24 pm    Post subject: Reply with quote

Hmmmmm...it always pays to post here. Just after posting I stumbled upon something when Googling. It was about VB.NET but I gave it a go and Bob was my uncle. The Combobox is empty and can be repopulated with new values.

Code:

$ComboBox.Items.Clear()


Works just fine.

_________________
Mart

- He's chained forever to a world that's departed.....It's not enough, it's not enough - Sorrow by Pink Floyd.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    KiXforms Forum Index -> KiXforms.NET Discussion All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group