• VIKASH CHAND KUMAR
  • NEWBIE
  • 20 Points
  • Member since 2019

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 10
    Questions
  • 5
    Replies
Hi All, i am trying to write one condition to open Data Import wizard if opportunity is not closed lost. also to throw a message if opportunity is closed lost, but its not working. can you please have a look. also i am using execute on javascript

{! IF(Opportunity.StageName != "Closed Lost", "/lightning/setup/DataManagementDataImporter/home", "XXXXXXXXXXXXXX) }  

also i am trying   below one

if({!Opportunity.StageName=="Closed Lost"}){
    alert("XXXXXXXXXXXXXXXXXX");
}
else{
    window.top.location.href =
        "/lightning/setup/DataManagementDataImporter/home";
}

its not working . 
Hi All, i am trying to write one condition to open Data Import wizard if opportunity is not closed lost. also to throw a message if opportunity is closed lost, but its not working. can you please have a look.

{! IF(Opportunity.StageName != "Closed Lost", "/lightning/setup/DataManagementDataImporter/home", "XXXXXXXXXXXXXX) }  

also i am trying   below one

if({!Opportunity.StageName=="Closed Lost"}){
    alert("Opportunity is Closed Lost, Learner Can not be uploaded");
}
else{
    window.top.location.href =
        "/lightning/setup/DataManagementDataImporter/home";
}

its not working . 
Hi all,

i am trying to write one custom button which should open only one custom object, i want to restrict user to see other standard and custom object. is it possible ? could you please guide here.
Hi , i am trying to write workflow rule to not fire if one of the field out of 90 filed is created or edited.

my rule is 

AND(NOT( ISNEW() ),  field1 = TRUE, NOT(ISCHANGED(field1 ))) . 

I want to include my condition, if one field 'field3' is updated/created this workflow should not fire.
i am trying to create list of contentversion for set of Id and blob data, which i am able to create, but now when i am trying to create contentdocumentlink for the list of contentversion, i am not getting any field which i should be relating to my LinkedEntityId.

List<ContentVersion> cvc=new List<ContentVersion>();
List<ContentDocumentLink> cdll = new List<ContentDocumentLink>();
 for(Id x : y.keyset()){  
        ContentVersion cv=new ContentVersion();
        cv.Title=XXXXXX; 
        cv.VersionData= y.get(x);
        cv.PathOnClient=XXXXXX; 
        cvc.add(cv);
    }  
Database.Insert(cvc);
            for(ContentVersion cvv: [Select Id,ContentDocumentId from ContentVersion where ?????? IN : y.keyset() ]){
                ContentDocumentLink cdl = new ContentDocumentLink();
                cdl.ContentDocumentId = cvv.ContentDocumentId;
                cdl.LinkedEntityId = ????????
                cdl.ShareType = 'V';
                cdll.add(cdl);                              
                  System.debug('Hello');            
            }          
                
                insert cdll;
 
I am getting error "Insert failed. First exception on row 0; first error: INSUFFICIENT_ACCESS_ON_CROSS_REFERENCE_ENTITY, You do not have the level of access necessary to perform the operation you requested. Please contact the owner of the record or your administrator if access is necessary.: [NetworkId]"  while creating ContentVersion. when i am trying to find "ContentVersion" object in Profile, its not there. 
Hi All,

i want to suspend "Sharing Rule Calculations" using script in Defer sharing calculation. Tried a lot to get API name and all, couldn't find. Can anyone please help.
public with sharing class A implements B {
    private static Real dataParamObj=new Real();  
    public List<C> method1(Id courseId) {        
        dataParamObj.a=a;
        dataParamObj.b=b;
        dataParamObj.c='Course';
    public void method2(Id y) {
        dataParamObj.d=d;       
            dataParamObj.e = e;
    public List<M> method3(Id courseId) {
        dataParamObj.f=f;
    }
    public List<MN> method4(Id courseId) {
        dataParamObj.g=g;
    }
    public List<PQ> method5(Id courseId) {
        dataParamObj.h = h;
    }
    public  XZ returnValues(){       
        return dataParamObj;        
    }
}

i have created static variable dataParamObj and all the values a,b,c,d,e,f,g,h assigned to dataParamObj shud be returned by this method returnValues() called in different class. it was working before, but not sure what happened after winter 20 release update, static variable dataParamObj is able to hold only last value assigned 'h'. please help. not sure where is problem, it was working before.
Hi, i want to print follwing lines in lightning component.

""please email us on email vikuemail.com or call us on 234 567 890""

1. i want email to show in highlighted in email format, so that when i click on email, it should be direct email. and also phone number highlighted in different color.
2. i want to use this in custom settings, so that based on requirement this statement can be changed.

i wrote a list of String returning both these values in apex, which will be returned to JS and then will be used by component.

but confused, how to implemnt this.
Can anyone please help.
I am always getting this error "ContactDetails$controller$locationChange [Cannot read property 'indexOf' of undefined] Failing descriptor: {ContactDetails$controller$locationChange}" Not sure what is wrong, can you please help

My component is 

<aura:component controller="ContactController">

    <aura:attribute name="contact" type="Contact" default="{'sobjectType': 'Contact'}"/>
    <aura:handler event="aura:locationChange" action="{!c.locationChange}"/>

    <div class="details">
        <h1>{!v.contact.Name}</h1>
        <h3>{!v.contact.Account.Name}</h3>
        <h3>{!v.contact.Title}</h3>
        <p>{!v.contact.Phone}</p>
        {!v.contact.MobilePhone}
    </div>

</aura:component>



and Controller is



({
    locationChange : function(component, event, helper) {
        
        var token=event.getParam("token");
        if(token.indexOf('contact/')===0)
        {
            var contactId=token.substr(token.indexOf('/')+1);
            var action=component.get("c.findById");
            action.setParams({"contactId":contactId});
        }
        action.setCallback(this,function(response){
            
            component.set("v.contacttt",response.getReturnValue());
        })
    $A.enqueueAction(action);
    }
})
Hi all,

i am trying to write one custom button which should open only one custom object, i want to restrict user to see other standard and custom object. is it possible ? could you please guide here.
Hi, i want to print follwing lines in lightning component.

""please email us on email vikuemail.com or call us on 234 567 890""

1. i want email to show in highlighted in email format, so that when i click on email, it should be direct email. and also phone number highlighted in different color.
2. i want to use this in custom settings, so that based on requirement this statement can be changed.

i wrote a list of String returning both these values in apex, which will be returned to JS and then will be used by component.

but confused, how to implemnt this.
Can anyone please help.
I am always getting this error "ContactDetails$controller$locationChange [Cannot read property 'indexOf' of undefined] Failing descriptor: {ContactDetails$controller$locationChange}" Not sure what is wrong, can you please help

My component is 

<aura:component controller="ContactController">

    <aura:attribute name="contact" type="Contact" default="{'sobjectType': 'Contact'}"/>
    <aura:handler event="aura:locationChange" action="{!c.locationChange}"/>

    <div class="details">
        <h1>{!v.contact.Name}</h1>
        <h3>{!v.contact.Account.Name}</h3>
        <h3>{!v.contact.Title}</h3>
        <p>{!v.contact.Phone}</p>
        {!v.contact.MobilePhone}
    </div>

</aura:component>



and Controller is



({
    locationChange : function(component, event, helper) {
        
        var token=event.getParam("token");
        if(token.indexOf('contact/')===0)
        {
            var contactId=token.substr(token.indexOf('/')+1);
            var action=component.get("c.findById");
            action.setParams({"contactId":contactId});
        }
        action.setCallback(this,function(response){
            
            component.set("v.contacttt",response.getReturnValue());
        })
    $A.enqueueAction(action);
    }
})
Hello I've installed Lightning Connect Quickstart via trailhead. Step 4 says select the External Orders app. Question - where is External Orders app found? After I find it I need to click Set Customer IDs to assign customer ID numbers to the sample account records in my Developer Edition.