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
legacytexasladylegacytexaslady 

Need s-control to pull in field from one object to another (possibility of multiple choices)

In a nutshell, I am tackling an issue beyond my skills and but thought s-controls would work but I don't know how to write them. It is not necessary that it be an s-control. Anything that would work would be great.

Please note that the custom object Target is the child in the master-detail relationship with Account. I wanted the Install to be linked to the Target but found that this was not possible, so I thought I could pull in the target summary name from the Target to tie it all together.

Here is the example:Account: Bob's burger Shack

  1. Custom Object: Target
  2. Target Summary name: (field formed by Concatenated  fields) Bob's burger Shack 2007 Long term DP FCB expansion (account name& year& target type& brand& target name)
  3. Targeted Units: 5
  4. Annual VPO: 100
  1. Custom Object: Install
  2. Target Summary Name: I want to pull in the exact one above - please note that there may be multiple targets (past & present) but I only want to link it to one specific one
  3. Installed Units: 1
  4. Annual VPO: Once the correct target summary name is found(selected), then I want to pull in the Annual VPO field that is tied to it.
  5. Daily VPO: Non-visible field to calculate the Annual VPO into a daily VPO
  6. Gallons gained: This will be a field that calculates (the daily VPO* # of days remaining in year) * the number of installed units

 Can anyone help? I am stuck on the red highlights. Other solutions/ ideas would be interested in as well. I greatly appeciate time & efforts in advance. Needless to say, I have zero programming skills.

Always ThinkinAlways Thinkin
Hi,
If Install is only linked to one specific Target, you could use a Lookup Relationship field on Install. This would mean that the Install is only related to one Target at a time and any of the past multiple Targets you reference would not be tracked.

If a new Install is created from the Target, the Target's standard Name (or Number) field would be automatically populated to the Install's Lookup field. Is your "Target Summary Name" field the Standard field or is it a Custom field? Makes it easier if it's the Standard field; if not, we'll need the Lookup field to establish a relationship between the two object so that we can automatically pull any field we want from the Target.