| |

Make the Custom GL Impact Stick

Follow-up to: The NetSuite GL Impact Screen Is Hiding Your Best Columns Last week we covered the NetSuite GL Impact trick: replace searchid=-36 in the URL with your own saved search ID, and the GL Impact screen renders with whatever columns you want — Item, Quantity, custom segments, all of it. That post mentioned two…

Follow-up to: The NetSuite GL Impact Screen Is Hiding Your Best Columns

Last week we covered the NetSuite GL Impact trick: replace searchid=-36 in the URL with your own saved search ID, and the GL Impact screen renders with whatever columns you want — Item, Quantity, custom segments, all of it.

That post mentioned two ways to make the change stick — a bookmarklet, or a custom button on the transaction form. Here’s how to actually build each one.

Same scope as the original post: Both approaches below apply to the Actions → GL Impact screen — the standalone page with the searchid in the URL — not the newer GL Impact tab/subtab that renders inline on some transaction forms. The tabbed view doesn’t use a searchid parameter, so neither the bookmarklet nor the button below will affect it.

Approach 1: The Bookmarklet (5 minutes, just for you)

A bookmarklet is a bookmark that runs a tiny piece of JavaScript instead of navigating to a URL. You make one, save it to your bookmarks bar, and from then on you click your normal GL Impact button, then click the bookmarklet, and the page reloads with your custom columns.

It works because the bookmarklet rewrites the current URL in place — swapping the stock searchid for your custom one — without caring which transaction you’re on.

How to set it up

Right-click your browser’s bookmarks bar and choose Add Page (Chrome/Edge) or Add Bookmark (Firefox/Safari). Then:

  • Name: Custom GL Impact
  • URL: paste the snippet below, with 3688 replaced by your actual saved search ID
javascript:(function(){window.location.href=window.location.href.replace(/searchid=-?\d+/,'searchid=3688');})();

Save it. Done.

How to use it

Open the GL Impact screen on any transaction the normal way — click the GL Impact link, see the stock screen. Then click your Custom GL Impact bookmarklet. The URL rewrites, the page reloads, and your columns appear.

Note for Chrome users: starting a few years ago, Chrome strips the leading javascript: prefix when you paste a bookmarklet URL. If clicking the bookmarklet does nothing, edit the bookmark and add javascript: back at the very front of the URL. Firefox and Edge usually preserve it.

Approach 2: A Custom Button on the Transaction Form (15–20 minutes, for the whole team)

If you find yourself reaching for the bookmarklet ten times a day — or you want this to work for everyone on your team without asking each of them to set up their own bookmark — the next step up is putting a button directly on the transaction record itself.

There is one NetSuite wrinkle that matters here: on a standard transaction form in view/inquiry mode, NetSuite does not let you simply attach a Client Script and call it directly from the form the way many people expect. The button needs to be added by a User Event script, and that User Event script in turn points the form to a Client Script that contains the browser-side function the button will call.

So this approach uses two scripts:

  • a User Event script to add the button during beforeLoad in view mode
  • a Client Script to open the custom GL Impact URL in a new tab

That sounds more complicated than it is. In practice, both files are short, and once deployed they are easy to maintain.

The two scripts

1) User Event script

This script runs on transaction load in view mode only. It adds the Custom GL Impact button to the form and points the form to the Client Script file.

/**
 * @NApiVersion 2.1
 * @NScriptType UserEventScript
 * @description Adds a Custom GL Impact button to transaction records on view,
 *              wired to GLImpactSearchCS.js.
 */
define([], function () {
    function beforeLoad(context) {
        if (context.type !== context.UserEventType.VIEW) return;

        var form = context.form;
        form.clientScriptModulePath = './GLImpactSearchCS.js';

        form.addButton({
            id: 'custpage_gl_impact_btn',
            label: 'Custom GL Impact',
            functionName: 'openCustomGLImpact'
        });
    }

    return {
        beforeLoad: beforeLoad
    };
});

2) Client Script

This script contains the function the button calls. It grabs the current record ID, builds the GL Impact URL with your custom saved search ID, and opens it in a new tab.

/**
 * @NApiVersion 2.1
 * @NScriptType ClientScript
 * @description Opens the custom GL Impact search results in a new tab
 *              based on the current record.
 */
define(['N/currentRecord'], function (currentRecord) {
    function openCustomGLImpact() {
        var recordId = currentRecord.get().id;
        var glUrl = '/app/accounting/transactions/gllines.nl' +
                    '?searchid=3688' +
                    '&Transaction_INTERNALID=' + recordId;
        window.open(glUrl, '_blank');
    }

    return {
        openCustomGLImpact: openCustomGLImpact
    };
});

Replace 3688 with your actual saved search ID.

How to deploy it

Five steps inside NetSuite, none of them difficult:

  • Upload both script files. Go to Customization → Scripting → Scripts → New, click the + to add the files, and upload both the User Event script and the Client Script.
  • Create the User Event Script record. After uploading the User Event file, click Create Script Record. Give it a clear name like Custom GL Impact Button UE and save it.
  • Deploy the User Event script to the transaction types where you want the button to appear — Sales Order, Item Receipt, Vendor Bill, and so on.
  • Make sure the Client Script file stays in the same folder path referenced by form.clientScriptModulePath. The User Event script uses that path to wire the form to the Client Script.
  • Test on a saved transaction in view mode. Open a transaction, confirm the Custom GL Impact button appears, click it, and confirm it opens the GL Impact page with your custom search columns.

That’s it. From then on, anyone using that transaction type and deployment sees the button automatically — no bookmarklet setup required.

Why the extra script is worth it

The bookmarklet is great for one person. The User Event + Client Script pattern is better when you want something that feels native to the form and works consistently for a team.

It also gives you one obvious place to enhance the behavior later. Want separate buttons for different GL views? Want to show the button only for certain roles or subsidiaries? Want different saved searches by transaction type? The User Event deployment gives you room to grow.

Don’t Forget: Make the Saved Search Available to Everyone Who Needs It

Whichever approach you pick, there’s one detail that determines whether your work helps anyone besides you: the saved search itself has to be accessible to the people clicking the button or bookmarklet. If your colleague triggers the same custom GL Impact and they don’t have access to your saved search, NetSuite shows them an error or an empty screen.

This is the step most teams skip, and it’s why “that thing the admin set up” never gets adopted broadly. Five minutes of setup on the saved search prevents it.

Saved search settings to get right

  • Public: checked. Makes it visible to all users with appropriate role permissions.
  • Audience tab: Restrict to the roles that actually need it — Accountant, Controller, A/P Clerk, etc. Don’t give every role access to every saved search just because you can.
  • Allow Audience to Edit: unchecked. This is the one people miss. Without it, anyone with access can “helpfully” tweak your search — and the next person who clicks the button gets whatever they changed it to. Lock it down.
  • Owner: Set this to a system or admin account, not your personal user. If you ever leave or change roles, the search keeps working.

Document it somewhere your team will actually find it

A button or bookmarklet with no explanation is the kind of thing people use once, forget about, and rediscover six months later. Take five minutes to write it down:

  • What the button does (“shows item, quantity, and custom fields on GL Impact”)
  • Which transaction types it’s enabled on
  • The internal ID of the saved search powering it
  • Who owns it, so the next admin knows who to ask when something changes

Stick that note in your team’s wiki, your shared Google Doc, or wherever your runbook lives. The single thing that determines whether internal tooling sticks is whether people can find it on their second day looking.

Train one or two people beyond yourself

Even on a small team, having two people who understand the setup means the next time something breaks — a new transaction type needs the button, or you upgrade to a custom segment that should be added to the search — there’s someone besides you who can fix it.

This is the difference between a tool that lasts and a tool that quietly dies the day you’re out sick.

Which One Should You Pick?

Bookmarklet: Pick this if it’s just you, you want it working in five minutes, and you’re comfortable with browser bookmarks. Zero impact on the NetSuite account itself. Easy to undo.

Custom button: Pick this if you find yourself doing this every day, you want it on transaction records (not just the GL Impact screen), or you want to set it up once for the whole team without asking everyone to manage their own bookmarks.

In our own work, we usually start clients on the bookmarklet to prove the value, then move to the custom button once the team confirms they want it permanently. There’s no shame in starting small.


Want this set up properly across your account? Fourth Wave Consulting has been writing NetSuite scripts since 2003. We can build the saved search, deploy the scripts, and document it for your team — usually in a couple of hours. Book a free hour and we’ll take a look at where else this approach could pay off in your account.

Similar Posts