Click here to Skip to main content
15,910,083 members
Home / Discussions / C#
   

C#

 
GeneralRe: Newbie: NullReferenceException Pin
praths_c11-Dec-06 4:20
praths_c11-Dec-06 4:20 
GeneralRe: Newbie: NullReferenceException Pin
Stefan Troschuetz11-Dec-06 4:28
Stefan Troschuetz11-Dec-06 4:28 
GeneralRe: Newbie: NullReferenceException Pin
gnadeem11-Dec-06 10:46
gnadeem11-Dec-06 10:46 
QuestionRunning an application by the start up of the windows Pin
hadad11-Dec-06 2:34
hadad11-Dec-06 2:34 
AnswerRe: Running an application by the start up of the windows Pin
Stefan Troschuetz11-Dec-06 2:38
Stefan Troschuetz11-Dec-06 2:38 
AnswerRe: Running an application by the start up of the windows Pin
Eric Dahlvang11-Dec-06 2:50
Eric Dahlvang11-Dec-06 2:50 
AnswerRe: Running an application by the start up of the windows Pin
Pete O'Hanlon11-Dec-06 4:50
mvePete O'Hanlon11-Dec-06 4:50 
QuestionHow to access data from a control on one from from another form? [modified] Pin
Saira Tanwir11-Dec-06 1:45
Saira Tanwir11-Dec-06 1:45 
hello
i'm trying to use the values i get from this code

for(int i=0;i<count;i++)<br />
	{<br />
	indice[i] = TableListBox.CheckedIndices[i];<br />
	MessageBox.Show(indice[i].ToString());<br />
	}


where TableListBox is actually a CheckedListBox and its checked indices are being stored in another array.
Now the problem is that when i run this code from its respective form it works fine, but as soon as i close the form and try to access this chunk of code from another form, it gives me the Index out of bound exception for CheckedIndices. i expect this is due to the reason that as soon as i close the form with the CheckedListBox, all its values are discarded.

i've tried solving this problem by storing the CheckedIndices into a static array, but it still is giving me the same exception.

So plz can anyone guide me about this problem of mine and tell me how to retain the checked indices after the form has been closed.

Thanks and awaiting ur reply
Saira


-- modified at 8:34 Monday 11th December, 2006
AnswerRe: How to access data from a control on one from from another form?(URGENT) Pin
Not Active11-Dec-06 2:17
mentorNot Active11-Dec-06 2:17 
GeneralRe: How to access data from a control on one from from another form?(URGENT) Pin
Saira Tanwir11-Dec-06 2:30
Saira Tanwir11-Dec-06 2:30 
AnswerRe: How to access data from a control on one from from another form?(URGENT) Pin
quiteSmart11-Dec-06 2:34
quiteSmart11-Dec-06 2:34 
GeneralRe: How to access data from a control on one from from another form?(URGENT) Pin
Saira Tanwir11-Dec-06 2:49
Saira Tanwir11-Dec-06 2:49 
AnswerRe: How to access data from a control on one from from another form? Pin
Nader Elshehabi11-Dec-06 3:25
Nader Elshehabi11-Dec-06 3:25 
GeneralRe: How to access data from a control on one from from another form? Pin
Saira Tanwir11-Dec-06 3:58
Saira Tanwir11-Dec-06 3:58 
GeneralRe: How to access data from a control on one from from another form? Pin
Nader Elshehabi11-Dec-06 5:21
Nader Elshehabi11-Dec-06 5:21 
QuestionFormatting Day part of DateTime Pin
kaleem tarar11-Dec-06 1:19
kaleem tarar11-Dec-06 1:19 
AnswerRe: Formatting Day part of DateTime Pin
Not Active11-Dec-06 2:23
mentorNot Active11-Dec-06 2:23 
Questionimage upload using atlas Pin
chaitu911-Dec-06 1:06
chaitu911-Dec-06 1:06 
AnswerRe: image upload using atlas Pin
Not Active11-Dec-06 2:16
mentorNot Active11-Dec-06 2:16 
GeneralRe: image upload using atlas Pin
Guffa11-Dec-06 3:30
Guffa11-Dec-06 3:30 
QuestionInvoking DirectX 9 [modified] Pin
Thitechx11-Dec-06 0:51
Thitechx11-Dec-06 0:51 
AnswerRe: Invoking DirectX 9 Pin
Bekjong11-Dec-06 2:01
Bekjong11-Dec-06 2:01 
GeneralRe: Invoking DirectX 9 Pin
Thitechx11-Dec-06 23:07
Thitechx11-Dec-06 23:07 
GeneralRe: Invoking DirectX 9 Pin
Bekjong11-Dec-06 23:37
Bekjong11-Dec-06 23:37 
Questioniterating through a datagridview and getting the value of unbound combobox Pin
Rocky#11-Dec-06 0:51
Rocky#11-Dec-06 0:51 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.