L
Liz
ok, this is really simple stuff, or it should be ... but I'm stuck
In a Windows Forms app, I have something resembling this:
Form1.cs
========
namespace NS
Class Form1
{
public Label label1
...
private void func1()
{
iterateRows();
}
}
Class1.cs
=========
using NS;
public class GetLabel
{
private void iterateRows()
{
Form1.label1.Text = "some value";
}
}
the method iterateRows is really performing a loop operation and I just want
to show values in label1 with each iteration; simple, right ? should be
but label1 is not visible from here ... I cannot find anything in the docs
which makes clear to me why Form1.label1.Text is not visible ... this kind
of stuff used to be a piece of cake in "C" .. but I've been away from coding
for awhile ...
I suppose I could pass a reference to label1 to iterateRows() and make this
work ? but I'd rather not and I'd like to understand why this won't work
in any case
Thanks for any help/explanations ...
L
In a Windows Forms app, I have something resembling this:
Form1.cs
========
namespace NS
Class Form1
{
public Label label1
...
private void func1()
{
iterateRows();
}
}
Class1.cs
=========
using NS;
public class GetLabel
{
private void iterateRows()
{
Form1.label1.Text = "some value";
}
}
the method iterateRows is really performing a loop operation and I just want
to show values in label1 with each iteration; simple, right ? should be
but label1 is not visible from here ... I cannot find anything in the docs
which makes clear to me why Form1.label1.Text is not visible ... this kind
of stuff used to be a piece of cake in "C" .. but I've been away from coding
for awhile ...
I suppose I could pass a reference to label1 to iterateRows() and make this
work ? but I'd rather not and I'd like to understand why this won't work
in any case
Thanks for any help/explanations ...
L