ionModal not working when trying to resize the content or scroll to top

Hi Everyone,

I am facing an issue when trying to use


Basically, I have a couple of custom directive to handle pages (so sort of walkthrough, with next and previous buttons)
This is inside a modal (ion-nav-view) and the HTML for the template is this:

<ion-modal-view class="troubleshooting" ng-controller="troubleCtrl" >
        <h1 class="title">Trouble</h1>

    <ion-content class="container has-footer">

        <interrogator ng-if="activeSection.path === 'interrogator'" content-path="./assets/"

        <solution-wizard solution-id="{{activeSection.solutionId}}" images-path="./assets/images/"
                                   ng-if="activeSection.path === 'solutionWizard'"></solution-wizard>

        <button class="button button-outline button-positive button-full main"


The buttons are emitting an event for when the page changes, and in the event, I call $ionicScrollDelegate.resize()
$ionicScrollDelegate.scrollTop(), like this:

$scope.$on('changePage', function() {
  $log.debug('resizing modal');
  return $ionicScrollDelegate.scrollTop();

but it’s not working. If my content is long, and then I click next (or previous), I expect the new content to go back to the top,but it does not.

The content for the next page stays at the bottom, but as soon as I click on everywhere on the page, it then scrolls back to top.

Any suggestions on this? Thanks

Check if you have injected $ionScrllDelegate into the controller function or not

Is, it is inject properly

Hi, nick_heatgenius
Just put in your controller

$scope.$on('$ionicView.enter', function (event, data) {

Here, app.article put your page state name Like etc…

nope. I still have to click somewhere in the modal for it to resize properly. Also, my modal never changes the url, so on view enter would not fix the issue, as when I enter the view the position is correct, but it’s getting wrong when navigatin trought the modal itself

in this example you were change the state name ?
Like ,


change state name

I am not changing the state name, and I don’t need to either. In my example, all it change it just the modal content, that’s it.