Hey folks,
I've got meself a problem. Pretty annoying one at that.
Well, I'm playing around with a newbie program that I want to make to display junk files in a listBox.
When I use the functions and everything in the same class everything works well (all the files are
correctly displayed in the listbox). Well, that's all good but now I want to seperate the code into
seperate classes to ease down on the eyestrain.
I've made a function one the main form in my program to read strings sent to it by another function in another
class, and then to add the information into the listBox1:
Here is the button label I'm using:
Here is the sample from my main form:Code:private void linkLabel2_LinkClicked(object sender, System.Windows.Forms.LinkLabelLinkClickedEventArgs e) { //IEBrowser Cache SysClean.IClean.IECache test = new IECache(); test.IECacheRun(); }
Here is the sample from the form from which I'm sending information:Code:public void LB1Add(System.String Received) { System.String Add; Add = Received; listBox1.Items.Add(Add); //Doesn't work, my test text won't enter }
The funny thing is is that a StreamWriter code can read the text in place of listBox1.Items.Add and add it toCode:public void IECacheRun() { System.String send; send = "The contents of your cache file (index.dat) is listed below:"; SysClean.IClean.IClean SendFunc = new IClean(); SendFunc.LB1Add(send); }
a text file...
Can you figure this out? I've taken 2 hours at breaking blood vessels in my brain trying to, maybe you can
save me from completely going nutso and start talking to myself?!?! PLEASE
Oh, ps, using VC# 2003, not Borland
Thanks,
Rob Sitter
[Professional at novice]



LinkBack URL
About LinkBacks




