Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8773309
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T18:15:44+00:00 2026-06-13T18:15:44+00:00

I have a class Trigger with some members of type SimpleAction : public SimpleAction

  • 0

I have a class Trigger with some members of type SimpleAction:

public SimpleAction OnOver;
public SimpleAction OnOut;
public SimpleAction OnDown;
public SimpleAction OnUp;
public SimpleAction OnClick;
public SimpleAction OnHold;

Now, from another class I’m doing this:

MemberInfo[] members = triggerScript.GetType().GetMembers();
    foreach (MemberInfo item in members) {
            Debug.Log(item.Name);
    }

In log massages I can see list of names of all members of Trigger class. OnOver, OnOut atc are in that list too. But how can I separate members of type SimpleAction from others?
item.DeclaringType is type of Trigger
item.MemberType is “field” for tham.
item.ReflectedType is Trigger too.
How can I get a member list of SimpleAction type?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T18:15:45+00:00Added an answer on June 13, 2026 at 6:15 pm

    Use method GetFields then filter field with FieldType is SimpleAction

     FieldInfo[] fields = triggerScript.GetType()
                .GetFields(BindingFlags.Public | BindingFlags.Instance)
                .Where(field => field.FieldType == typeof (SimpleAction))
                .ToArray();
    
     foreach (var field in fields)
     {
    
     }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Here is what I have <div class='class1'> Some content <div class='trigger'> <a href='#'>Push To
I have class with back reference: public class Employee : Entity { private string
I have class with collection as below public class MyClass:IXmlSerializable { int vesrion; private
I have class that looks like this: class A { public: class variables_map vm
I'm developing an application which will have these classes: class Shortcut { public string
I have a class that requires some of its methods to be called in
I have c class definition and some inner class definitions for that class: class
I have an some html elements defined with class=tab. And in my jquery file,
I have a class called Root which serves as some kind of phonebook for
Suppose I have some application A with a database. Now I want to add

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.