# Accessing Main file from custom class

**URL:** https://forum.kirupa.com/t/accessing-main-file-from-custom-class/290918
**Category:** Uncategorized
**Created:** [June 22, 2009, 9:05am UTC](https://forum.kirupa.com/t/accessing-main-file-from-custom-class/290918 "2009-06-22T09:05:21Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![SonOfChaos](https://avatars.discourse-cdn.com/v4/letter/s/7c8e57/32.png) [@SonOfChaos](https://forum.kirupa.com/u/SonOfChaos)
#### Post date: [June 22, 2009, 9:05am UTC](https://forum.kirupa.com/t/accessing-main-file-from-custom-class/290918/1 "2009-06-22T09:05:21Z")

</div>

Okay, I know these questions are STUPID, but I’m just learning.

If I have a public function in a ‘main’ file, can I trigger a function their class file.

```auto

public function main(){
    customclass();
}
public function doStuff(){
}

//in another file
public function customClass(){
                      //main just triggered me!
                      //how do I trigger doStuff, just using 'doStuff()' doesn't work...argh!
}

```

Also, is the term ‘main file’ the proper term for the uh…main file. I feel stupider saying it.
