Grey Out/disable Specific Items In The ListBox Control?

May 3, 2012

As far as I know, there is no way to grey out/disable specific items in the ListBox control? I want to make a list of surveys that need to be answered, but grey out/disable those that the user has already answered.Or is there some way to do it with ListBox?

View 1 Replies


ADVERTISEMENT

How To Disable ComboBox / ListBox Items

Nov 27, 2007

I need to extend a combobox to disable some listitems (i.e splits - "----------"). I reckon some APIs will be involved, and it could get complicated. That'll not put me off though. If anyone with usefull info on the subject could post it,

View 11 Replies

VS 2010 Disable Buttons While There Are Less Than 2 Items In A Listbox?

Feb 16, 2012

How do I disable buttons while there are less than 2 items in a listbox? I can't figure out how to do it. I'm a newbie in Visual Basic(programming at all)

View 7 Replies

Use Databindings To Enable/disable A Button When A Listbox Contains 0/1+ Items?

Aug 27, 2009

I can't seem to figure out how to use databindings to enable/disable a button when a listbox contains 0/1+ items?

Button1.DataBindings.Add("Enabled", ListBox1, "Items.Count")
Button1.DataBindings.Add("Enabled", ListBox1.Items, "Count")
Result = ArgumentException: Cannot bind to the property or column Count on the DataSource. Parameter name: dataMember

Button1.DataBindings.Add("Enabled", TextBox1, "Text.Length") ' This works?

View 2 Replies

Access Specific Listbox Items?

Jun 25, 2012

I am trying to access a specific item in a listbox. For example, I have 5 items in a list box and I need each one on a different textbox, but I cannot find the code necessary to access a individual item in a listbox. I need the third item in a textbox but I cant find the code to access that SPECIFIC item and turn it into text in the texbox.

View 2 Replies

Listbox Items Colour - Two Types Of Items Populating In A Listbox (checked Listbox)

Apr 28, 2009

I am using VB.NET (version 2008). I have two types of items populating in a listbox (checked listbox). For example: lets say one is type "A" and other is "Type B". Their names maybe same so if the user sees those items in listbox then he won;t be able to determine their type until he click on them and checks out its properties. I wanted that I add each item to listbox and colour them so that blue for example means type "A" is there and red means the other. So this way I will be able to know at a glance that how many item of what type is present. I guess it may not be possible to do that in a standard checkedlistbox. I am also using component factory's krypton controls which enhance the gui of an application. But I dunno if I can progress using that.

View 5 Replies

Pixel Counter - Count The Black Pixels The Grey Pixels The More Grey Pixels

Jul 27, 2009

I'm trying to make a -what i thought would be simple app.My intention was to build program that:1) i'd provide a grayscale image2) the program would count the black pixels the grey pixels the more grey pixels etc. (the hue) and the white3) would make the percentage sum of all pixels, that is: 300.000 black pixels (rgb 0 0 0) etc. given that 0 is the black, 100 the white. e.g a simple grayscale image is 55.2 white

This was my way and i don't think that is useful:

First of a button to convert the image to greyscale:

Dim bm as new Bitmap(source.Width,source.Height)

Dim x

Dim y

[CODE]...

Secondly, -and that's the stupid way- i did -or better i wanted to do- this: i put the code to dynamically create labels, each label having the colour of a pixel as background colour and as text the colour converted to rgb

The third step which i intended to do (i couldn't get pas two) was to sum up the labels etc.

View 6 Replies

Autoselect Pre-programmed Items In A Listbox When A Form Opens With The Control On It?

Aug 3, 2009

I am trying to autoselect pre-programmed items in a listbox when a form opens with the control on it.but i cannot find a proper method to select all the items in the listbox and hold the resulting text as a string that will later be saved to a text file. i do not need help with saving the text to file but rather selecting the items in the listbox.so, after alot of trial and error and no luck I think I am supposed to use

ListBox.ObjectCollection

propriety. but i have no clue whats so ever in how to manage to select all the items in the listbox when this form opens...if this does not make sence then I will rephraze it.

View 6 Replies

Disable Specific Row In ListView?

Apr 20, 2010

how can I disabled specific rows in ListView using vb.net 2003 language?

View 1 Replies

VS 2010 Disable Specific Key?

May 25, 2011

i press windows key sometimes when i writing somethng on my laptop.question : i want to disable windows logo key (windows key) and other key combos like Ctrl + Esc. i dont need disable all time(regedit method : HKEY_CURRENT_USERSoftwareMicrosoftWindowsCurrentVersionPoliciesExplorerNoWinKeys ) just a little time when i writing..

View 2 Replies

Disable A Specific Event And Enable Later?

Jun 1, 2009

I populate a DataGridView during a sub routine. Later in my code I have a RowEnter event for that DataGridView when the user is assessing it after it has been populated during the main procedure. However this RowEnter event gets fired while the DGV is being populate. I only want it to file AFTER its populated. Is it possible to disable this specific event while the DGV is being populated? I really want the user to have the ability to cursor up/down the DGV and see affects of the RowEnter Event. I know I can also use the CellEnter event but it does not have the same effect.

View 4 Replies

Disable A Specific Item In Combobox?

Aug 10, 2010

Lets say have i have 5 items in the combobox

1
2
3
4
5

can i disable a specific item for example just #2?

View 16 Replies

Disable And Enable A Specific Adapter?

Mar 31, 2010

How can I disabel and enabel a specific adapter?(restart a specific adapter by vb code)

View 2 Replies

Enable/disable A Button During A Specific Time Of The Day?

Oct 29, 2009

I have 2 buttons on the form, Button A and button B.

I want to enable button A from 6am till 6pm from Monday to Friday and to disable button B during 6am until 6pm.

And I want to disable button A from 6.01pm till 11.59pm.

During saturday, only button B is enabled for the whole day.

View 16 Replies

Listbox Remove Parts Of Items Containing And Blank Items?

Mar 27, 2012

So I want it to remove any text in the list box that has a "Job" in it and just replace it with a blank nothing.

Like if the listbox looked like this

Yardjob
jobsong
redjob

then it would change it to this

Yard
song
red

I also would like a way of removing any blank items from the listbox.

[URL]

View 12 Replies

Disable Particular Items In A Combobox?

Nov 11, 2011

Is there any option to disable particular items in a combobox?? If No then how can i do that??

I have 4 items in Combobox. For each items( based on combobox selected index change) lots of other calculation is there. i need to display all items but in some cases second item should be disabled.

View 2 Replies

Disable Some Items In A Combobox?

Jan 27, 2009

Is it possible to disable some items in a combobox?Depending on the current mode that my application is in, certain items need to be enabled or disabled.I know that I could remove the items and rebuild the combobox but in this case I think that by showing the items greyed out it gives the user feedback as to what mode they are in and what options would be available to them if they decided to switch modes.

View 17 Replies

Manually Disable All The Items?

Mar 13, 2009

when running a process in a backgroundworker, do i need to manually disable all the items in my form to stop the user from any transactions while the backgroundworker is doing something and then enable them after

View 3 Replies

.net - Clear Listbox Items Except For Searched Items?

Jan 2, 2010

I am using the below code to find all the items in a listbox using vb.net 2005. But how can remove the non searched items from the listbox after searching?

[Code]...

View 2 Replies

Remove Items From ListBox A Based On Items In B?

Nov 5, 2011

I am trying to remove items from a listbox based on the items on another listbox, this seems simple but apparently[code]...

View 1 Replies

Disable Multiple Items From DropDownList?

Jun 6, 2011

I would like to disable a specific items from DropDownList. I have below code but it does not working. DropDownList have 5 items.And,I'm getting error:Index was out of range. Must be non-negative and less than the size of the collection.Parameter name: index

Protected Sub CheckBox1_CheckedChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles CheckBox1.CheckedChanged
Dim X As Integer = 0 <> 1
DropDownList1.Items(X).Enabled = False
End Sub

But, if I add a different value for X, then it disable 1st and 2nd item.

Protected Sub CheckBox1_CheckedChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles CheckBox1.CheckedChanged
Dim X As Integer = 0 or 1
DropDownList1.Items(X).Enabled = False
End Sub

My goal is if I would have a 365 items in DropwDownList to disable items for example between 120 and 150.

View 1 Replies

Hide Or Disable Items In One Combobox?

Feb 25, 2009

how to hide or disable items in one combobox on the basis of selected item in another combobox in vb.net?

View 3 Replies

How To Enable And Disable Items Of Menu

Feb 6, 2010

In VB 6 I enabled and it incapacitated the items of the menu with the following expression. And in VB.net how to do to substitute this expression in my project?

View 7 Replies

VS 2008 Move All Items From Listbox To Another Listbox?

Sep 25, 2011

probs a simple answer but my mind is blank atm. I have this code to move all items from listbox3 to listbox1 but it wont move them unless i select 1, then it moves all items.

[Code]...

View 2 Replies

Asp.net - Disable Each Items In Gridview According To The Textbox Text?

Dec 21, 2010

if booking closed column values is equal or more than textbox1 text then the book button in gridview will be disabled for each gridview item whose booking closed time is greater and equal to textbox1 time ..

How to do that ?

M using VS 2008 and vb

View 1 Replies

Asp.net - Disable Validation On All Items Inside A Panel?

Jul 22, 2011

is it possible to disable validation of all items inside a panel programatically in vb.net?

i can't seem to figure it out.

i disabled all fields inside a panel, but they still cause the page to validate on submit.

this is what i have now:

Public Sub DisableControls(ByVal parent As Control)
Dim cCon As Control
For Each cCon In parent.Controls

[Code]....

View 1 Replies

Disable Controls When Items Are Selected From A Combo Box?

Apr 30, 2011

How to disable other controls when an item is selected from a different combo box. When someone selects a specific item from the combo box provided, It should automatically disable other controls specified to be disable.

View 2 Replies

Disable Menu Strip Sub Items In An Application?

Jun 26, 2010

I am creating a user rights access to a menu. for example an administrtor account can access a sales report while a limited account cannot. What i mean is a customize menu for an administrator and limited user....

ex. administrator
Sales Report--->Daily sales-enable
limited account
Sales Report--->Daily Sales-disable

View 2 Replies

Enabled Propreties To Disable Editing Combobox Items?

Sep 27, 2011

i've tried the enabled propreties to disable editing combobox iteam but it make it gray and it become unreadable.so i changed the combobox style to simple (it looks like a texbox) and i want to know how can i prevent user from changing the content.

View 4 Replies

Disable Menustrip Items If Username And Menuname Match?

Feb 27, 2010

I have a DB table with the names of my Menus and a User names. After a User is logging succesfully I go through the table with the Menuitem names and enable /disable the menuitems accordingly.

Can anybody kindly show me a workaround on how to do this. For example i have this table below and after succesfully loging in as username "aaaaa". Menustrip items with name accounts and finance should be enabled and the rest like billing will be disable.

Table Name
UserAndMenu

[code]....

View 4 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved