Search
 
SCRIPT & CODE EXAMPLE
 

CSHARP

c# dynamic object get value

var nameOfProperty = "property1";
var propertyInfo = myObject.GetType().GetProperty(nameOfProperty);
var value = propertyInfo.GetValue(myObject, null);
Comment

PREVIOUS NEXT
Code Example
Csharp :: c# datetime get number of week 
Csharp :: pass datatable to stored procedure c# dapper 
Csharp :: c# reverse a string 
Csharp :: c# request run as administrator 
Csharp :: oncollisionenter compare tag 
Csharp :: dictionary c# 
Csharp :: unity c# set object tag 
Csharp :: visual studio run multiple forms at once 
Csharp :: unity dontdestroyonload 
Csharp :: how to draw gizmos unity 
Csharp :: c# xpath read attribute value 
Csharp :: c# regex to find number between parenthesis 
Csharp :: how to write a variable in console c# 
Csharp :: unity print name of button when click on it 
Csharp :: c# mongodb connection 
Csharp :: data annotation c# name 
Csharp :: get normal from 3 points 
Csharp :: c# read text file separated by comma 
Csharp :: c# func with no return 
Csharp :: get date value from datepicker c# 
Csharp :: c# list append 
Csharp :: c# string array initialization 
Csharp :: how to sort string array alphabetically in c# 
Csharp :: memset alternative in c# 
Csharp :: httppostedfilebase in .net core 3.1 
Csharp :: unity default cube mesh 
Csharp :: asking for user input integer c# 
Csharp :: topdown unity 
Csharp :: how to check a list is null or empty in c# 
Csharp :: c# convert split to list 
ADD CONTENT
Topic
Content
Source link
Name
4+2 =