SS4: Unable to access a (DataObject) class in a controller

(I am sorry if I ask a number of questions about DataObjects but they are 90% of my project)

I confirm that the leadin slash is NOT needed: $offerer = Offerer::create(); works.

OK, so since you fixed the syntax error in the file, did you do another dev/build ? Did the database tables get created OK?

The syntax error is fixed. I always perform dev/build. No database tables created. Finally, whatā€™s very odd is that the error message keeps referring to my HomeController (site root url) even though I am not calling it. (Instantiation of Offerer DataObject works perfectly)

OKā€¦ if the database tables havenā€™t been created, then thatā€™s why the code canā€™t find the class. We need to work out why they arenā€™t building properly before anything else (same as with the original issue)

The error you get when you do a dev/build can you post more of it? Itā€™s very hard to debug without seeing the full error.

Alsoā€¦ if the error is referring to the home controllerā€¦ can you post the code for that too?

Yes, the error most likely lies with my Apartment.php class. I am going to try to find it on my own. If I canā€™t, Iā€™ll post the full dev/build error message. Is that OK ?

The error you posted suggests that there is an issue with the HomeController class. It might be worth debugging that before you look at the Apartment class

Iā€™ ll debug the HomeController class, Apartment class and let you know with potential error messages if thatā€™s ok.

(Hello),
I think dev/build does not create all my DB tables (besides the Offerer class) because I have various relationships between DataObject classes, which are called in all the controllers I have.
I was able to solve some issues, the latest dev/build error message is explicit:

Parse error : syntax error, unexpected ā€˜submitprofileformā€™ (T_STRING), expecting variable (T_VARIABLE) in C:\xampp\htdocs\silver\mysite\code\OffererController.php on line 113

OffererController.php is here:

https://paste.ofcode.org/Be8jmc865YHaAM4HNZdRqw

I used submitprofileform only twice: on line 78 and 113

The best information I could find and relied on to create/edit forms in SS is here:

https://www.silverstripe.org/community/forums/form-questions/show/35036

Thank you.

Thatā€™s just a syntax error again, line 113 (as per the error message)

Should be public function submitprofileform(.....

All DataObjects errors and Controllers errors were fixed, the DB tables were all successfully created.

I appreciate your help.