Click here to Skip to main content
15,908,173 members
Home / Discussions / C#
   

C#

 
GeneralRe: Retrieving USB Barcode scanner data... Pin
Jacob Dixon13-May-09 3:06
Jacob Dixon13-May-09 3:06 
AnswerRe: Retrieving USB Barcode scanner data... Pin
cackharot27-May-09 15:03
cackharot27-May-09 15:03 
GeneralRe: Retrieving USB Barcode scanner data... Pin
Jacob Dixon28-May-09 4:17
Jacob Dixon28-May-09 4:17 
QuestionSending file via TCP protocol Pin
nike_arh12-May-09 10:31
nike_arh12-May-09 10:31 
AnswerRe: Sending file via TCP protocol Pin
Luc Pattyn12-May-09 14:11
sitebuilderLuc Pattyn12-May-09 14:11 
GeneralRe: Sending file via TCP protocol Pin
nike_arh12-May-09 23:35
nike_arh12-May-09 23:35 
GeneralRe: Sending file via TCP protocol Pin
Luc Pattyn13-May-09 0:03
sitebuilderLuc Pattyn13-May-09 0:03 
QuestionCurious Question about ProgressBar object between two classes Pin
Blubbo12-May-09 9:52
Blubbo12-May-09 9:52 
In FirstWindow class:
* Has progress bar object named "progressBar1".  
* Its value is updated in this class as the process runs.

In SecondWindow class:
* Has progress bar object named "pbSecond".  
* This SecondWindow class invokes FirstWindow class but does not use (display) the
   FirstWindow GUI.
* This SecondWindow sends the data to FirstWindow the data to be processed and save to the file.

Now, I had this kinda of crazy idea to try and was amazed it does work! I'm not certain on how this works... passing the pointer of the object?

FirstWindow class has this property:

public ProgressBar pBar
{
      set { progressBar1 = value; }
}

public int DumpRFData(byte[] dat)
{
   pBar.Maximum = dat.length;
   for (int i = 0; i < dat.length; i++)
   {
         progressBar1.value = i;
         ... code sippet (for retriving dump data)
   }
}


now in SecondWindow class:

public int DumpData()
{
      byte[] data = new byte[1000];
      FirstWindow fw = new FirstWindow();
      fw.pBar = pbSecond;
      fw.DumpRFData(data);
}

when the DumpRFData is invoked, the progress bar in SecondWindow is updated as the process in FirstWindow runs.

How could that be happening? Processed from the pointer or what?
AnswerRe: Curious Question about ProgressBar object between two classes Pin
Christian Graus12-May-09 10:00
protectorChristian Graus12-May-09 10:00 
GeneralRe: Curious Question about ProgressBar object between two classes Pin
Blubbo13-May-09 2:19
Blubbo13-May-09 2:19 
QuestionConverting between types inside Lambda Expressions Pin
Andre Vianna12-May-09 8:59
Andre Vianna12-May-09 8:59 
QuestionDraw railway using Graphics GDI+ Pin
baranils12-May-09 8:49
baranils12-May-09 8:49 
AnswerRe: Draw railway using Graphics GDI+ Pin
Christian Graus12-May-09 9:14
protectorChristian Graus12-May-09 9:14 
GeneralRe: Draw railway using Graphics GDI+ Pin
baranils12-May-09 9:42
baranils12-May-09 9:42 
GeneralRe: Draw railway using Graphics GDI+ Pin
Christian Graus12-May-09 10:00
protectorChristian Graus12-May-09 10:00 
AnswerRe: Draw railway using Graphics GDI+ Pin
Mark Churchill12-May-09 18:27
Mark Churchill12-May-09 18:27 
GeneralRe: Draw railway using Graphics GDI+ Pin
baranils12-May-09 19:47
baranils12-May-09 19:47 
QuestionMoving an array element to a variable. Pin
Lecutus112-May-09 8:18
Lecutus112-May-09 8:18 
AnswerRe: Moving an array element to a variable. Pin
OriginalGriff12-May-09 8:26
mveOriginalGriff12-May-09 8:26 
AnswerRe: Moving an array element to a variable. Pin
Dave Kreskowiak12-May-09 8:49
mveDave Kreskowiak12-May-09 8:49 
AnswerRe: Moving an array element to a variable. Pin
Lecutus113-May-09 6:02
Lecutus113-May-09 6:02 
QuestionHow to convert OCX file into C# Pin
dwark10612-May-09 7:48
dwark10612-May-09 7:48 
AnswerRe: How to convert OCX file into C# Pin
CPallini12-May-09 8:16
mveCPallini12-May-09 8:16 
GeneralRe: How to convert OCX file into C# Pin
dwark10612-May-09 8:24
dwark10612-May-09 8:24 
AnswerRe: How to convert OCX file into C# Pin
OriginalGriff12-May-09 8:21
mveOriginalGriff12-May-09 8:21 

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.