function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
RAHUL KARMAKARRAHUL KARMAKAR 

Please comment the code below its urgent

On Case record users should be able to put a case comment. Case is a standard object and Case Comment should be a custom object. Case detail page should be a VF Page and should display Case Comments Related List in an Expand/Collapase manner
karthikeyan perumalkarthikeyan perumal
Hello Rahul, 

in your case 

Create a VisualForce page and overrider standard Details pages in Case Object (Buttons, Links, and Actions---View) like below
User-added image

if you wish to display custom object ( owm case comment) as related list create master details relationship with case object. add the like below.
 
<apex:page standardController="Case">
	<apex:relatedList list="CaseComments__r" />
</apex:page>
 Otherwise you would like to dispay standard case comments related list
<apex:page standardController="Case">
	<apex:relatedList list="CaseComments" />
</apex:page>
Expand/Collapase behaviour for related list try or below links for your reference. 
https://developer.salesforce.com/forums/?id=906F000000098asIAA
http://stackoverflow.com/questions/17460116/how-can-i-expand-and-collapse-a-div-using-javascript
hope it will help you. 

Thanks
karthik