All Questions
124
questions
0
votes
1
answer
369
views
How to make a method, that accepts an input, into a property of a class object?
The issue I've encountered here, is that I am currently trying to make an object that has a method as a property. I was able to get it to work on public static void methods, but not methods that ...
1
vote
1
answer
235
views
How can I read the name of a thread in a C# application?
I'm working on a multithreaded application, written in C#.
I would like to verify if a thread is already running or not.
You might think "How easy can that be?", but there seems to be a ...
-3
votes
2
answers
167
views
System.NullReferenceException Object reference not set to an instance of an object (List) [duplicate]
public List<Faculty> Faculties {get;set;}
List<Faculty> faculties = FacultiesManager.Faculties;
Faculties.Add(something);
how can i interact with the object list
2
votes
2
answers
925
views
A way to catch any change of an object with properties
I have a simple program that's supposed to capture any change of object A. When it does detect a change, it will write down the stringified object into file A.
Now the most obvious approach would be ...
0
votes
1
answer
224
views
How can I add Nested Object List Properties to an existing Object
I'm trying to figure out how I can add an object list property to an existing object, which also has a list object property. I have 3 classes as FirstList, SecondList, and ThirdList with an Id and ...
0
votes
2
answers
742
views
How to dynamically handle changes in a JSON object name that may change regularly, when building C# class to deserialize the JSON? [closed]
my predicament is that I have to deserialize some JSON files provided by my company's software eng department, for me to use in a production environment, however some revisions of the JSON files have ...
0
votes
0
answers
57
views
C# Object properties comparison
I have a class which is used for objects comparison:
public static class ComparisonHelper
{
public static bool DeepCompare(this object obj, object another)
{
if (...
0
votes
2
answers
204
views
C# access to stack object property
How can I access the objects property in this situation?
Araba araba = new Araba();
araba.Renk = "mavi";
araba.fiyat = 12345;
// I created this class and it working normally
ArrayTypedStack ...
0
votes
3
answers
462
views
Are C# properties objects?
I'm learning C# from the book "Head First C#". I thought I understood properties. They are used like fields but work like methods, with getters and setters. I never thought of them as ...
-1
votes
1
answer
36
views
Class including list
when i am assigning the values in the list its saying object not set to instance of an object any help , i can retrieve from other service , when i am trying to assign the value in the list its ...
0
votes
1
answer
329
views
Should I use response object or property for returning response
I have a requirement where I need to send SMS to our customers. For sending SMS we have multiple providers. To achieve this, I have designed an interface and created different classes for providers by ...
1
vote
2
answers
138
views
Different properties in one list
i have a class that mades me sick.
I get this data from my db, and just want to manipulate things and bring it back.
The class that get my nervs broken:
public class Part
{
public string name { ...
0
votes
1
answer
116
views
Updating a property through wpf datagrid in a collection through the individual element
Ok here: source xaml in question, in ucPacketPrinting.xaml
<DataGridCheckBoxColumn
x:Name="clmPrint"
Binding="{Binding IsSelected, ...
-2
votes
1
answer
164
views
C# Get property values from an Object
Throughout my WebApp project, i'm logging the details of the current user across most of the controller/razor page model methods. I moved the code used for retrieving the current user into a ...
0
votes
1
answer
38
views
How would I set a property of an Object that was created in another form in c#? [duplicate]
For my coding project in c# I must create a program that uses multiple forms. Mine is an RPG character creator that will simply have the user select traits and stats, and then display them on the ...