Observable.Generate Memory leak, or somethin I'm doing wrong.
• Hi,      I'm having an issue with Observable.Generate      The
following is my code:      Observable.Generate<double,
double>(0,       //initial condition
sampleNo => !EndNow, //when To stop
sampleNo => (sampleNo >= SampleRate) ? 0 : sampleNo + 1,
//increment sampleNo
sampleNo => GenerateSample(sampleNo),     //Generate Sample
//sampleNo => new TimeSpan((long)(100000 / SampleRate)),
.Subscribe(data =>   //subscribe subject      Working Version
(Long Running  Task instead of Observable.Generate)
Task.Factory.StartNew(() =>                         int sampleNo
= 0;                         while (!EndNow)
sampleNo= (sampleNo >= SampleRate) ? 0 : sampleNo + 1;
if (dataevnt!=null)