hemantc
Posts: 2
Joined: Thu May 26, 2022 11:25 am

"Could not access network location"

Thu May 26, 2022 11:48 am

Hi,
We have created executable using advanced installer. We are getting issue whenever we are trying to execute this exe file using command line. We get this popup "Could not access network location", also I have attached screen shot of that popup with this ticket.
Command we have using for this is :- "path\bootstrapper.exe" REGISTER_PLUGIN=False

Here, REGISTER_PLUGIN is the install parameter that we have used in our project,
Note:- If we are setting value of REGISTER_PLUGIN=True , Then it works fine. Also we are getting same behavior if we are execute this exe using GUI.
Attachments
Capture.JPG
Capture.JPG (21.96KiB)Viewed 1365 times

Catalin
Posts: 6542
Joined: Wed Jun 13, 2018 7:49 am

Re: "Could not access network location"

Thu May 26, 2022 12:00 pm

Hello and welcome to our forums,

Unfortunately, I can not say for sure why this is happening.

In order for me to further investigate this, please forward me the following resources:

- a copy of the .AIP file

- a download link for the setup

by email at support at advancedinstaller dot com.

Best regards,
Catalin
Catalin Gheorghe - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

hemantc
Posts: 2
Joined: Thu May 26, 2022 11:25 am

Re: "Could not access network location"

Fri Jun 03, 2022 7:42 am

Hi Catlin,

We have created a sample project as you requested and attached with this ticket, please go through it.
We also have explained below the current behavior of our bootstrapper and expected behavior of bootstrapper,

Here we have declared some install parameters,
1. MySW_INSTALLED :- To set the value of this parameter we have created one custom action(PowerShellScriptInline_1)
2. REGSISTER_PLUGIN :- Default value for this is "True". Purpose of this parameter is to configure the system as per the status of REGSISTER_PLUGIN parameter. e.g. If it is "False" then only install the bootstrapper but don't configure it to system.
3. CONFIGPATH :- This is the location of Config.pro file where it is actually present and its value we are setting using custom action (PowerShellScriptInline). e.g. If value of MySW_INSTALLED parameter is True then it sets the value of CONFIGPATH as "X:\XYZ\XYZ MySW Common Files\text" else it sets value of CONFIGPATH as "<space>".

Current behavior 1:-
scenario 1 : Machine that does not have the expected software installed and if we are installing using command line,
command used : Path\MyApplication.exe REGISTER_PLUGIN=False

1. It sets "<space>" value to CONFIGPATH parameter because we does not have expected software installed.
2. It sets "False" value to MySW_INSTALLED parameter because we does not have expected software installed.
3. It gives error "Could not access network location error"


Current behavior 2:-
condition:- if value of CONFIGPATH parameter we set as "" using custom action instead of " " then,
scenario 1 : Machine that does not have the expected software installed and if we are installing using command line,
command used : Path\MyApplication.exe REGISTER_PLUGIN=False

1. It sets "some different location" value to CONFIGPATH parameter because we does not have expected software installed.
2. It sets "False" value to MySW_INSTALLED parameter because we does not have expected software installed.
3. It installs the bootstrapper but also dump or create config.pro file inside the CONFIGPATH folder which is under APPDIR location.


Expected behavior :-
scenario 1 : Machine that does not have the expected software installed and if we are installing using command line,
command used : Path\MyApplication.exe REGISTER_PLUGIN=False

1. It sets "" value to CONFIGPATH parameter because we does not have expected software installed.
2. It sets "False" value to MySW_INSTALLED parameter because we does not have expected software installed.
3. It should install the bootstrapper but it should not dump or create config.pro file at any location.
Attachments
MyApplication.aip
AI project
(34.95KiB)Downloaded 95 times

Catalin
Posts: 6542
Joined: Wed Jun 13, 2018 7:49 am

Re: "Could not access network location"

Tue Jun 07, 2022 11:55 am

Hello,

Thank you very much for the detailed test-case and for the sample project.

I have done some tests and this looks like a misconfiguration on your side.

Basically, based on the CONFIGPATH property, you create a folder in the "Files and Folders" page (a property based folder).

Now, in your PowerShell script, you set that property to " ", which obviously is not a valid path. During the "Paths Resolution" action group, a validation of all the folders from your project is done and that error appears if a path is not valid.

The name of the action is "CostFinalize".
CostFinalize ends the disk space costing and resolves the folders in the project
Now, if you change the value of the CONFIGPATH property in your script from " " to "", the following happens:

- the "" value basically means an empty property. A property can have two states:

1. it has a value and therefore it exists

2. it does not have a value and therefore it does not exist

In your case, if you set the property to "", this is what happens (taken from the log file):
MSI (c) (D8!F4) [13:23:05:407]: PROPERTY CHANGE: Deleting CONFIGPATH property. Its current value is ' '.
and then:
MSI (c) (D8:30) [13:23:05:422]: PROPERTY CHANGE: Adding CONFIGPATH property. Its value is 'C:\CONFIGPATH\'.
Since no value is given to it.

With that being said, please give a correct value (a valid path) for the CONFIGPATH property and this should work as expected.

Best regards,
Catalin
Catalin Gheorghe - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”