Questions tagged [dynamic-binding]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
1 answer
92 views

Dynamic color based on condition LWC

i want to fill the svg color based on condition JS : get OpptColorIcon() { const colors = this._listOpp.map(opp => { return opp.Scoring === "weak" ? "#FF8C00" : &...
Fark's user avatar
  • 17
0 votes
1 answer
44 views

Issue related Dynamic SOQL query

I have written a dynamic query for filter data at run time based on the different condition. string squery='Select id, SVMXC__Serial_Number__c, SVMXC__Serial_Number__r.Name, SVMXC__Service_Order__r....
Shruti Saran's user avatar
0 votes
1 answer
1k views

Dynamically Pass Bind Variables to a SOQL Query With queryWithBinds Method

I was going through the new feature from Spring 23 release regarding Dynamically Pass Bind Variables to a SOQL Query With queryWithBinds Method. It seems like it is working when there is only one ...
Sudipta Deb's user avatar
  • 1,251
3 votes
1 answer
218 views

Register dynamically Connected App: was anybody successfully done it?

Register dynamically Connected App: was anybody successfully done it? I tried to follow the steps provided in this article https://help.salesforce.com/s/articleView?id=sf....
Patlatus's user avatar
  • 16k
0 votes
1 answer
158 views

How to Create Dynamic Bound List Variable Names in a Loop for Dynamic SOQL

I'm trying to create a dynamic SOQL string based on the type of fields being used. If the field is a text area, it contains a list of comma delimited strings. For each text area field, I create a list ...
number41's user avatar
  • 928
1 vote
1 answer
791 views

How to get property from lightning web component based on button clicked

I have a dynamic lwc that generates related lists dynamically. I want to add a New button to the component but want to be able to dynamically get the component from which the new button was clicked so ...
Thomas's user avatar
  • 2,294
0 votes
2 answers
2k views

Assign dynamically values in fields via field API name

I am trying to populate a field with the value of another field dynamically based on custom metadata types. I use the method variable.put(fieldAPIName, value) in order to populate the fields. Here is ...
Xrhstos Kolonis's user avatar
0 votes
1 answer
1k views

LWC - How to clear my input text fields when saving?

When saving a record, my input fields should is replaced with empty value (clear the text field) and I am having issue with the one within the iteration. I have 2 inputs that are not part of the ...
Eric's user avatar
  • 73
0 votes
1 answer
1k views

Dynamic field rendering depends on object fields in LWC [closed]

I got a requirement that the LWC form fields rendering has to be dynamic. Say if I add a text box field in object then in front end(LWC), it has to come automatically without any coding in LWC. Some ...
SFDC-Beginner's user avatar
0 votes
1 answer
64 views

add Datetime values inside IN query clause in a different context

I am trying to create a query dynamically which contains the Date and Datetime values with IN clause with WHERE For example, SELECT Id FROM Opportunity WHERE Program__c IN ('Online','On Campus') AND ...
Hunt's user avatar
  • 235
3 votes
1 answer
893 views

Dynamic csv generation for a dynamic soql query in apex

When constructing a csv via apex how do we avoid hardcoding the recordString assignment within the query loop? Note I have a dynamic List<String> fieldsList that represent field names. For ...
Peter Noges's user avatar
  • 1,100
0 votes
0 answers
157 views

Dynamic object is not getting inserted

I want to insert dynamic object with dynamic fields and value. I have written below code in execute method and i am getting "Attempt to de-reference a null object" error and not finding where I am ...
baby samanwaya's user avatar
0 votes
1 answer
994 views

Add both dynamic and literal CSS classes to the same element

Pretend I have an element that I wish to give a literal class, such as: <p class="slds-text-title">My Title</p> But I also have a dynamically determined class I wish to add, which I ...
Nathan Fig's user avatar
0 votes
2 answers
11k views

LWC Dynamically Show a field based on picklist value

Based on the Subtopic__c or SubSubtopic__c (I know great API names) I want to show a text box called Other. I have looked at some documentation and based on what that has stated this should work. Take ...
Gunner1714's user avatar
0 votes
1 answer
690 views

Calculation in Einstein Analytics Dashboard JSON - dynamic reference line

I am adding a dynamic reference line to a combo widget and the line needs to show an average conversion rate. Monthly conversion rate is presented well, as the column calculating this value is set ...
g4c's user avatar
  • 17
1 vote
0 answers
1k views

Dynamically assign sObject field details in LWC

I have created a inline editable LWC. This solution is dynamic i.e. to add a new field on the table , i just have to add on field set and based upon field type and access, it will be displayed in the ...
Salesforce Development's user avatar
1 vote
1 answer
5k views

Custom Inline Editable Table in LWC

I have created a Custom Inline editable table in LWC. Here are the details: Apex Class : I am getting the fields to be displayed from Field set and created one wrapper class to pass the fields ...
Salesforce Development's user avatar
6 votes
2 answers
4k views

LWC best practice call child method

see example https://developer.salesforce.com/docs/component-library/tools/playground/q8rtcVIBf/79/edit Parent component <template> Value in Parent : {objMap.key} Value in Parent : {...
Aleksei's user avatar
  • 61
2 votes
2 answers
4k views

How to retrieve field attributes from dynamic fields in lightning component

I am loading my fields dynamically trough a fieldset. Using aura:id="requiredField" on the lightning:inputField I can get the fields using a map in the controller. I have made some fields required at ...
Thomas's user avatar
  • 2,294
0 votes
1 answer
962 views

Hot to make a dynamic lightning:inputfield required

I have a fieldset which I get from serverside and load on clientside I am adding the required parameter to the field but my component does not alert on required. I added the values behind the fields ...
Thomas's user avatar
  • 2,294
0 votes
2 answers
1k views

Dynamic row values inherits the values from row before in lightning component

I have a lightning component where in I have a few text fields and 2 picklist fields, controlling and dependent. The problem is whenever I try to add a new row dynamically, the new row will take the ...
anxiousAvocado's user avatar
2 votes
1 answer
67 views

Is it possible to rebind for dynamic SOQL in a more scalable way?

I came to the realisation that it isn't difficult to create my own String Interpolation, like this: public class XAP_UTIL_MapInterpolation implements XAP_UTIL_InterpolationIntf { String template; ...
Brian Kessler's user avatar
0 votes
1 answer
2k views

Error message: Invalid literal value [1, 1]: 'WorkOrder' - Lightning Components - Dynamic Binding

I have a issue, I'm trying to create a Dynamic Form with two lightning Components and fieldsets, each component's related to an Object 'WorkOrder' and 'WorkOrderLineItem'. I pass the API names of each ...
Karla Martinez's user avatar
0 votes
1 answer
58 views

The dynamic component shows empty when rendered from another component

I am rendering the dynamic component based on the profile the problem is when its loaded it shows the dynamic component in that not the fields which i have in the dynamic component.Below is the code ...
user46777's user avatar
0 votes
1 answer
2k views

Dynamic vertical tab lightning component

I am bout to create an dynamic vertical tabbar which gets its content from a query later on. This turns out to be an issue as the aura:iteration seems to be not filled at the point of time the init ...
nico525's user avatar
  • 31
0 votes
1 answer
674 views

How to get related objects and fields of a parent object dynamically?

Can any one suggest me how I can get related objects and their fields of a parent object.Here is the code I have tried so far: public void discoverRelatedAccessibleFields(sObject newObj) { ...
sivanee's user avatar
  • 123
4 votes
2 answers
1k views

Can Apex SOQL query variable binding be done in a method other than the method which invokes Database.query?

Apex Commons has some brilliant solutions, but one of the things which I feel is missing is an object-oriented approach to the SOQL query's "WHERE" conditions. I'm presently working on my own ...
Brian Kessler's user avatar
15 votes
1 answer
157 views

Passing calculated values to components makes them immutable

I'm calculating a value while I pass it to a component. But for some reason this makes it immutable, so I can't update it in my component. These are some cases I played with: <aura:application ...
itsmebasti's user avatar
  • 6,359
0 votes
1 answer
130 views

How is this markup fixing the error?

In a custom VF page I get the following error :- System.SObjectException: SObject row was retrieved via SOQL without querying the requested field: Campaign.Product__c Error is in expression '{!...
Rob Cowell's user avatar
3 votes
1 answer
487 views

Are dynamically created components bound the same as child components?

I have a lightning component that dynamically renders an indeterminate number of child components. Each child component represents an item in a list. I iterate through the list and create different ...
api-testuser45690's user avatar
2 votes
1 answer
2k views

Dynamic checkbox only eveluates to true

I have a dynamic checkbox generated trough an iterator.I want to be able to get the true and false values from the current state of the checkbox. When ik check or uncheck my checkbox is always ...
Thomas's user avatar
  • 2,294
1 vote
1 answer
746 views

How to fetch the accounts based on a value checkbox

I have a dynamic checkbox generator which is bound by city on the account which works fine all cities are rendered with a corresponding checkbox. When I select the checkbox a city is added to a list ...
Thomas's user avatar
  • 2,294
3 votes
1 answer
7k views

How to bind dynamic checkboxes to id

I have a couple of checkboxes which I dynamically create trough an iteration. In want to use these to trigger a function. My issue is when I select/check 1 checkbox all the others get checked ...
Thomas's user avatar
  • 2,294
0 votes
1 answer
808 views

Lightning Component Field Binding conditional expression

In a component, initially i was binding a case picklist field value as an attribute. But now, i have requirement to bind it to a different field based on a boolean flag. Original Code snippet (inside ...
user2957592's user avatar
0 votes
1 answer
3k views

Wrapper class dynamic access to fields [duplicate]

We have wrapper class: public class Meta { @AuraEnabled public Integer total; @AuraEnabled public Integer count; @AuraEnabled public Integer offset; @AuraEnabled public String orderBy;...
Karel L's user avatar
  • 344
13 votes
2 answers
8k views

Dynamic field binding in Lightning (e.g. lightning:input)

This is to me the most restricting drawback of Lightning compared to Visualforce. A way to dynamically bind/access properties like values of fields. To make complex component structures fast I don't ...
Robert Sösemann's user avatar
1 vote
0 answers
128 views

Can event.source() be stored as attribute in dynamically created component without destroying source when dynamic component is reloaded

Use Case I have a parent container that has a single reusable modal component. There is also a container with many rows of line items rendered as individual components. In certain circumstances a ...
Daniel Collier's user avatar
-1 votes
1 answer
845 views

How to pass a String from Visualforce to Apex, then re-rendering the page

I have a VF page that displays a table of records. I'd like the table to be filtered by one of it's String fields, "currency", so if I chose 'USD', it will only show records with 'USD', same for 'CAD',...
PrawnCrackers's user avatar
0 votes
1 answer
1k views

Binding dynamic multiselect step

I would like to bind multi-select dynamic step in a title of a chart but can't figure out how to do that. This is the step: "step_1": { "datasets": [ { ...
mascot's user avatar
  • 553
0 votes
1 answer
6k views

How to get sObject field value

This question is related to more or less that I have asked here My question is, how to get the field value from sObject to little demo you here. Here is my vfp: <apex:page controller="...
Nick's user avatar
  • 6,924
0 votes
2 answers
1k views

How to bind <apex:inputField> using dynamic sObject

Is that possible to bind the sObject field in the visualforce page? I'm getting the below error but not sure its helping me but I'm sure it has to do with mySobject that I have in the inputField I ...
Nick's user avatar
  • 6,924
0 votes
2 answers
463 views

Dynamic Component OutputField Bound to SObject

I am trying to bind a field to an outputfield dynamically apex, but in doing so I get value for <apex:outputField> is not a dynamic binding! This does not work: Component.Apex....
streco's user avatar
  • 159
0 votes
0 answers
149 views

Issue with dynamically rendering inputField from fieldset in Visualforce page

I have a page where inputFields are rendered from a fieldset on Opportunity object. When I load the page, it loads correctly. But when any server side action is done and page is re-rendered an error ...
ajinkyah's user avatar
  • 751
12 votes
1 answer
6k views

Lightning - dynamically creating element and binding it's attributes

I'm trying out to generate input elements dynamically and wasn't able to bind value attribute. I getting following error when trying to display component: testDynamicBinding.cmp <aura:component ...
ytiq's user avatar
  • 4,465
1 vote
1 answer
44 views

JavaScript reading visualforce binded variables

I need some help understand how JavaScript and Visualforce interact. I have a eventListener that works perfectly when the DOM is loaded: window.addEventListener('DOMContentLoaded', function() { if (...
Olivia's user avatar
  • 3,431
2 votes
0 answers
132 views

Is it not possible to use Dynamic binding of sObject fields in a Lightning Component? [duplicate]

I'm trying to loop a list of sObject fields and displaying the fields as column in a table. In Visualforce, we could bind an sObject field like value="{!Contact[fieldName]}". But I'm unable to make ...
VarunC's user avatar
  • 5,900
0 votes
1 answer
373 views

I wanna have a <apex:selectList that automatically fetches select options from an object's field

How to achieve a functionality where i have a <apex:page> <apex:form> <apex:selectList id="countries" value="{!Location__c.Country__c}" size="1" required="true"...
Shobhit Saxena's user avatar
0 votes
0 answers
1k views

Can we create a lightning component attribute dynamically and inject it in the component mark up from the controller/helper?

I am trying to create components dynamically in a lightning component. However, the HTML markup or DOM inside which these components are being created are also not static. I am also creating the DOM ...
Ayan Sengupta's user avatar
4 votes
2 answers
5k views

Can we create HTML markup dynamically from helper/controller in a lightning component?

Lightning gives us the scope of creating aura components dynamically from the controller/helper using $A.createComponent/createComponents. However, I was wondering if there is a way to create HTML ...
Ayan Sengupta's user avatar
0 votes
1 answer
4k views

How to use field sets in a lightning component to create a multi-grid structure form with a lightning look and feel?

I am trying to create a lightning component that would render a form based on a picklist selection. I read this post below and was able to kick start my development How to use fieldsets with ...
Ayan Sengupta's user avatar