Hi. I use the same technic but in hte file I have "Let vConnString = [Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=myDBName;Data Source=MyServer;Provider=SQLOLEDB.1;]"
and in the load I do
CONNECT TO $(vConnString);
And so I can work on vConnString later in script, and recall the connection if needed.
The dangerous part of this method is that the connection string is stored in the application and so users can see the connection string and use it in a local Qlikview. So we use 2 applications : 1 for load and 1 for display or we "clean" connection strings at the end of the string.