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
NickHockingNickHocking 

Dynamic table / spreadsheet in VF page

Hi All.

 

I want to create a VF page which purely contains a 'spreadsheet'. I want this spreadsheet to start with, for example, 5 rows.

 

Each row to be exactly the same.

 

The job of the spreadsheet is to calculate a job cost for an opportunity. For example - I have an opportunity which will require 2 business analysts, 3 developers, and a project manager. I want to be able to have one resource per row.

 

Each row would display the resource name (optional), their 'job role' (custom field in User object, which is their role, eg, 'Developer'. If a name is input, then it should auto populate with their role, if no name, then should be a picklist), corresponding daily rate for that resource (auto populate from job role selection), then a field for the user to input the number of days the resource will be required for, a field for percentage discount for that resource (optional input), then the last two columns would be gross and net totals for that resource.

 

Each row would be optional, so if no data is input in the other rows, then they are ignored. Then, the bottom of the table would have a TOTALS row which just adds up total discount (%), net and gross totals, as a quote for the opportunity.

 

It would also be cool to be able to add more rows if 5 isn't enough.

 

This could be an extra module to the Opportunity tab, or simply a tab on it's own, as a standalone calculator....

 

Please can someone give me a push in the right direction in terms of getting started - I'm extremely new to VF and Salesforce, and while i may have bitten off more than i can chew, i should be able to battle my way through, but just need a little nudge as to whether i can do all this in VF, or whether it'd be better to do it in jscript/html, apex...etc, etc

 

Many thanks

Vinita_SFDCVinita_SFDC

Hello,

 

Please refer following help link and customize the code snippets given as per the requirement:

 

http://wiki.developerforce.com/page/Making_A_Spreadsheet_On_Force.com?app_data=%7B%22pi%22%3A%2252446bab1dbff1ab2500000d%22%2C%22pt%22%3A%22wall%22%7D