The value of boolean setting Ask to update automatic links determines if the This workbook contains links to one or more external sources that could be unsafe message box is displayed when a workbook is opened.
With VBA, this setting can be controlled with the application.askToUpdateLinks property.