Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
eventasm
Partner - Contributor II
Partner - Contributor II

Execute Command in script will finish but not execute

Hi everyone,

Due to project needs I need a qliksense app to execute something like:

execute cmd.exe /c start msedge www.awebpageigottoopen.com;

This is the syntax I've followed and I've also tried with /C (caps)

I'm running a qliksense server installation and I've disabled standard mode on the QMC already, and my settings.ini looks like this:

eventasm_0-1608751844324.png

Note: I've also tried without the StandardReload line and it won't work either.

My main problem is that when I execute my app it goes like it shows bellow:

eventasm_1-1608751955337.png

It's in Spanish (sorry about that) but it basically says load was sucessfully finished but it hasn't opened that msedge window. I'm using the server machine so it should open it at my windows session but it won't. 

Any ideas of what's going on? I really need help on this 

Labels (2)
17 Replies
Anil_Babu_Samineni

First try in command prompt if that working or not and also, These parameters you are passing not in Legacy mode since Qlik Sense is difficult to execute such external. You have to use middle tools to design such a way like Powershell..

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
eventasm
Partner - Contributor II
Partner - Contributor II
Author

Hi Anil,

First of, thanks for your reply. I've tried creating a .bat file to call it from in the execute command but it isn't working. I've also tried just calling something like "C:\thePathInMyMachine\msedge.exe" which is one of the examples I've found on the internet and won't work either. Any other ideas?

Thanks in advance. 

Anil_Babu_Samineni

Try this way and see, Go to Setting.ini and add this parameter AllowExecuteCommand=1

Then, Write something like this and execute? Execute "C:\thePathInMyMachine\msedge.exe";

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
eventasm
Partner - Contributor II
Partner - Contributor II
Author

Hi again Anil,

I've done as you said and now at least we have something new to face.

eventasm_0-1609234184973.png

After adding the new line to my Settings.ini (and restarting the services and so on) now when I launch the script it will stay "thinking" forever.

I've faced this before in another qliksense server deployment I used for testing the execute command but i thought may be it was because the machine wasn't powerfull enough to run the execute order. This new machine im using now is using 8GB RAM memo and two i7 8th gen CPUs at 1.80GHz which i guess should be enough.

Any thoughts?

Again, thank you for your help.

Anil_Babu_Samineni

Can you please explain what is this about, Execute "C:\thePathInMyMachine\msedge.exe"

So that i can investigate further in my environment.

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
eventasm
Partner - Contributor II
Partner - Contributor II
Author

As I explained in the original post, the aim of this is to lauch a web browser with an url. So basically the steps i need to follow are:

1. Be able to enable the usage of execute command. 

2. Be able to launch a web browser with execute command.

3. Be able to launch a web browser with an url.

I'm still stuck at step 1-2 where i can't happen to use the execute command properly. 

As you can see in my last post, right now im just calling my internet explorer .exe file. So I'm doing as it follows:

Execute "C:\Program Files\Internet Explorer\iexplore.exe";

This way, I should be calling the .exe file which should open the Internet Explorer app/program. 

Once I achieve this i will be able to proceed to step 3. 

Hope I've explained myself properly.

As always, thanks a lot.

Anil_Babu_Samineni

In future, You planned to not use Qlik Sense or ?Because, we can enable this functionality by help of button to simply giving the URL. In case if you need this, I will check the possibility and come back..

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
Anil_Babu_Samineni

Additionally, I just tried this in my environment after enabled OverrideScriptSecurity=1 in settings.ini and it is working for me

EXECUTE "C:\Program Files\Internet Explorer\iexplore.exe" http://www.awebpageigottoopen.com/

What this is doing, Once QS reload from this execution

- Opened the IE browser

- Opened this URL

- Closed this browser and script reloaded

Sorry, If i still mis understading the question

 

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
eventasm
Partner - Contributor II
Partner - Contributor II
Author

Yes, all other possibilities have been considered and discarded due to project needs (I'm sorry, as you may understand i can't go deeper into this) but the following have been considered and discarted:

1. Creating a windows task which would open the web with the windows task scheduler.

2. Using a button for navigation wouldn't meet project needs.

3. The only option left we thought of was execute command.

About your next message, that's exactly what it is intended to do but it isn't working in my deployment.

Is it ok if i take a look at your settings.ini? Are you using qliksense server or desktop? if you're using server, what version are you using? 

Thanks.