Manufacturer List

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
Il y a 13 ans
That was changed in version 1.90. In this case replace
var manufacturers = this.ManufacturerService.GetAllManufacturers();

with
var manufacturers = this.ManufacturerService.GetAllManufacturers().Take(10);
Il y a 13 ans
I sensed that and actully tried it, but getting error on

if (manufacturers.Count > 0) saying ">" is not allowed..

any thoughts?
Il y a 13 ans
Ohh, sorry. Use "var manufacturers = this.ManufacturerService.GetAllManufacturers().Take(10).ToList();"
Il y a 13 ans
Worked like a charm!
Thanks and keep up the superior work. Looking forward to 2.0
Il y a 13 ans
I had a similar list of manufacturers that were too large and just got it to show a random 10 each time by using something like:

System.Random oRand = new Random();
            int nManufs = 10;
            while (manufacturers.Count > nManufs)
                manufacturers.RemoveAt(oRand.Next(0, manufacturers.Count - 1));
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.