Skip to main content
Filter by
Sorted by
Tagged with
0 votes
1 answer
62 views

I created a class to calculate a Exponential Moving Average: public class ExponentialMovingAverage { public Int32 Period { get; set; } public ExponentialMovingAverage(Int32 period = 20) { ...
Miguel Moura's user avatar
-2 votes
1 answer
62 views

I have an ICollection<Plante> Jardin which I want to sort according to some property Plante.Taille: private readonly ICollection<Plante> Jardin; I use the instance method ...
Gui Gui's user avatar
0 votes
1 answer
1k views

I have a requirement to create an object 'factory' that works as follows: Accepts a list of matching object types. Compares each property value in the list to see if they match. Returns a new single ...
Bandito's user avatar
  • 329
0 votes
2 answers
654 views

I have an instance variable _foo declared like so - List< Dictionary<int, HashSet<int> > > _foo; Yes, it is a messy data structure that is a List of Dictionaries whose key is an ...
Happy Green Kid Naps's user avatar
0 votes
2 answers
663 views

I have a type of non-ordered records: public class Row { public string Client { get; set; } public string Account { get; set; } public string Status { get; set; } } and its instantiation ...
timnavigate's user avatar
1 vote
2 answers
70 views

I have the following datatable Col1 Col2 Col3 A B 1 A B 2 A C 1 The Col1 and Col2 is the unique key so the first and the second row is duplicated. The Col3 differ so I would like to have an option to ...
Muflix's user avatar
  • 6,896
0 votes
1 answer
566 views

I have a LINQ query that I am having trouble optimizing. It takes about 6 seconds to run. IList<Note> notes; data = client.Configuration.Data.OfType<UWData>() .Where(s => s....
Avinash Avi's user avatar
0 votes
1 answer
59 views

have been trying for several hours to resolve the problem but i cant sos here is the tables im working with on pastebin var result = E .Join(A, a => a.ID, aa => aa.ID, ...
invis's user avatar
  • 15
-1 votes
1 answer
715 views

I have below query where i am using the where clause with select and getting the result (list of librarySourceRowInputs) and would like to use the aggregate instead of (where and select). In this ...
Glory Raj's user avatar
  • 17.7k
0 votes
3 answers
314 views

( I am a beginner with C# ) I wants to create a list of Person class using 2 lists, List of Users and List of Post here is how the class structure looks. Problem : while Creating Object using LINQ, i ...
Rohan park's user avatar
0 votes
3 answers
1k views

I have a table of doctors in my database. So I'm trying to get the list of the firstName of the doctors in my database. In the ViewModel class I'm using this code to get it public List DoctorsList () ...
DOUHADJI's user avatar
1 vote
2 answers
1k views

Can the following be done in LINQ as a one-liner, without using a for-loop? IEnumerable<MyObj> MyList = EF.GetList(etc); foreach (var row in MyList) { row.uploadedAt = MyUtils....
joedotnot's user avatar
  • 5,193
0 votes
2 answers
473 views

my class, public class User { public string Username { get; set; } public string Password { get; set; ...
Doc's user avatar
  • 179
0 votes
1 answer
168 views

Class student and the main are just for reference.. In the try catch block there are two separate s1.SNum = "string" that should each throw a separate argument but both throw the same one every time ...
Eroe's user avatar
  • 3
0 votes
3 answers
1k views

public class Account { public List<Memo1> Memos { get; set; } } public class Memo1 { public string Memo { get; set; } public DateTime AddDate { get; set; } public string UserID {...
harsha tharanga's user avatar
-3 votes
3 answers
113 views

If I need just the maximum [or the 3 biggest items] of an array, and I do it with myArray.OrderBy(...).First() [or myArray.OrderBy(...).Take(3)], it is 20 times slower than calling myArray.Max(). Is ...
Jeno Csupor's user avatar
  • 2,939
3 votes
0 answers
39 views

I'm trying to determine if there is a correct way to first filter a collection and then determine if any items in the collections pass the filter condition. The two (basic) statements I'm trying to ...
A-A-ron's user avatar
  • 579
0 votes
2 answers
62 views

I would need: a list(of employee) that contains all the employees contained in all companies. (e1,e2... e9) the employee how has the oldest DischargeDate higher than 1/1/2018 I have solved it in this ...
JC M's user avatar
  • 78
3 votes
1 answer
3k views

Group the repetitive value in the object list using Linq query. I have the following data as table called "SudentAssessment" with these data. AssessmentId Username SITSupervisor ...
Hezron Naresh's user avatar
0 votes
0 answers
83 views

I have a problem which seems to be quite similar to Query objects for one to many relationship in LINQ I've been trying to solve my problem referring the above but somehow I've been failing for a ...
user3247458's user avatar
-3 votes
3 answers
1k views

I have the following LINQ query that I want to optimize. Our system is heavily dependent on this, so even slight optimization will help over all. Any ideas are welcome, not sure where to even start.. ...
scorpion5211's user avatar
  • 1,070
-2 votes
1 answer
278 views

I am building a simple search tool in vb.net windows forms application with sql server database, The user will enter a unique id and will see the results which shows the status. Object Class: ...
MAF's user avatar
  • 99
1 vote
1 answer
801 views

I am trying to create an extension method that will be usable for both LINQ-to-Object and LINQ-to-Entities for creating a functioning Where query. More will go into it eventually but to start I am ...
StuffOfInterest's user avatar
-1 votes
2 answers
474 views

i've got a C# web Api receiving the following object : "cars": { "bmw": true, "benz": false, "kia": true, "hyundai": false, "madza": false, "ford": ...
Silva's user avatar
  • 675
0 votes
3 answers
161 views

Say we have two List<T>. The first is a list of sales totals: class SalesTotals { public Guid EmpID { get; set; } public string EmpName { get; set; } public decimal? TotalSales { ...
Scuzzlebutt's user avatar

1
2 3 4 5
28