Some features allow Equations and linking directly in the Property Manager. (See 2018 SOLIDWORKS Help - Direct Input of Equations in PropertyManagers for the list.) It's as simple as typing the Equal sign in the dimension box to get the drop-down where you can make your selection. See below from a Linear Component Pattern in an Assembly.
This hasn't always been the case, and still isn't available for all features that use a dimension, but it can still be done. If you can't do it directly in the Property Manager go ahead and create the feature, using a value that's close to what you need, and click Okay to close the feature. Now there are two options for linking the dimension.
1. Single-click on the feature in the tree to show the dimension in the graphics area (or double-click if you don't have Instant 3d turned on).
Double-click on it to bring up the standard dimension dialog box, enter the Equal sign, and you'll get the same drop-down shown above. You'll need to do a manual rebuild for the change to take effect.
..or option 2: Open your Equations dialog box and go to the "Dimensions" tab. All dimensions in the model will be listed. Remove the value in the "Value / Equation" column and enter the Equal sign. That will give the same options for linking. (Naming dimensions will be a big help if you want to use this option. That will make it much easier to find the one you need.)