cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Want the oppurtunity to discuss enhancements to PTC products? Join a working group! X

Changing View Issues

rireland-bowcot
12-Amethyst

Changing View Issues

Platform: Hololens

 

I have encountered an issue with Studio when trying to change a particular View in Studio. 

 

I have 5 Views (a, b, c, d, e) and in each I have enter the following code into the corresponding javascript file. 

// Change scene 
$scope.app.goa=function() {
twx.app.fn.navigate("a");
};

$scope.app.gob=function() {
twx.app.fn.navigate("b");
};

$scope.app.goc=function() {
twx.app.fn.navigate("c");
};

$scope.app.god=function() {
twx.app.fn.navigate("d");
};

$scope.app.goe=function() {
twx.app.fn.navigate("e");
};

I also have 5 Application Events (a, b, c, d, e) each with the corresponding function to load the correct scene e.g. 

app.goa();

When I run the preview these application events work for all but 2 Views. And after clicking the Application Event to load a broken scene this prevents any other buttons from working. 

 

I have also tried changing view without using javascript and relying on bindings but this leaves me with the same result. I have remove all other code form the .js file but still nothing. 

 

Can anybody think of what could be going on here?

 

Many thanks.

4 REPLIES 4

What errors if any are you seeing in the console when you run in Preview? If you are using Chrome Shift+Ctrl+i will open the console for a tab.

In Short... A lot 

 

I ran the application up until the point it stopped working. 

 

I have attached the saved console log file for you. Hopefully it makes more sense to you than myself. 

 

Thanks for the help. 

Hi @jmikesell

 

Could you please reply on this. Thanks in advance.

Regards-Mohit

@rireland-bowcot Sorry but I was looking for the Javascript console errors not the Studio log files.

 

If you are using Chrome. When you start a Preview of your experience press Shift+Ctrl+i and this will bring up the developer tools and there is a console in here. This will show you JS errors produced by the JS code you wrote and by View.

 

@mgoel I'm not sure it's best practice for a PTC employee to be bugging customers to solve other customers problems. Maybe there is someone in PTC technical support that you should be tagging in these threads you are trying to get closed?

Announcements

Top Tags