Skip to main content
So I found this discussion (https://success.salesforce.com/answers?id=90630000000go53AAA), but it's not quite what I need. I'd like to have a List button that works just like the native New button, except that it opens the record creation in a new window or tab. This is for a custom object which begins with the 3 letters a21, if that matters or helps. Thanks!
13 respuestas
  1. 27 ago 2014, 18:23
    Gotcha! So here you go:

     

    Change the Behaviour to 'Execute JavaScript' and the Content Source as 'OnClick JavaScript' and write this:

     

    window.open(

    "/a21/e?" +

    "CF00N40000002gRZT={!Case.CaseNumber}" +

    "&CF00N40000002gRZT_lkid={!Case.Id}" +

    "&retURL=%2F{!Account.Id}",

    "_blank"

    );

    Tip: 

     

    Syntax for window.open(...) as per the above snippet:

     

    window.open(url, target);

    Note : I just broke the URL to multiple lines for better readability.
0/9000