# \[0.21\] \[Android\] Can't select text inside a TextView

**URL:** <https://forums.fusetools.com/t/0-21-android-cant-select-text-inside-a-textview/4150>\
**Category:** Bug Reports\
**Created:** [June 25, 2016, 2:30am UTC](https://forums.fusetools.com/t/0-21-android-cant-select-text-inside-a-textview/4150 "2016-06-25T02:30:49Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![cyril.gantzer](https://avatars.discourse-cdn.com/v4/letter/c/ba9def/32.png) [@cyril.gantzer](https://forums.fusetools.com/u/cyril.gantzer)\
**Post date:** [June 25, 2016, 2:30am UTC](https://forums.fusetools.com/t/0-21-android-cant-select-text-inside-a-textview/4150/1 "2016-06-25T02:30:49Z")

</div>

I don’t know if it has anything to do with the caret-at-the-end-of-input bug fix, but as of 0.21 I can neither move the caret inside a TextView (usually achieved by holding your finger to the screen for a while then moving it) nor select a portion of text, to cut or copy it (although I suspect this is a result of the first issue).

---

<div class="post-metadata">

**Author:** ![Baggers](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/baggers/32/665_2.png) [@Baggers](https://forums.fusetools.com/u/Baggers)\
**Post date:** [July 11, 2016, 10:54am UTC](https://forums.fusetools.com/t/0-21-android-cant-select-text-inside-a-textview/4150/2 "2016-07-11T10:54:16Z")

</div>

Hi cyril,

Is this target specific or is it happening in preview and on device?

---

<div class="post-metadata">

**Author:** ![cyril.gantzer](https://avatars.discourse-cdn.com/v4/letter/c/ba9def/32.png) [@cyril.gantzer](https://forums.fusetools.com/u/cyril.gantzer)\
**Post date:** [July 11, 2016, 4:37pm UTC](https://forums.fusetools.com/t/0-21-android-cant-select-text-inside-a-textview/4150/3 "2016-07-11T16:37:53Z")

</div>

It was on Android Preview but the issue has gone away since then

---

<div class="post-metadata">

**Author:** ![cyril.gantzer](https://avatars.discourse-cdn.com/v4/letter/c/ba9def/32.png) [@cyril.gantzer](https://forums.fusetools.com/u/cyril.gantzer)\
**Post date:** [July 13, 2016, 11:13pm UTC](https://forums.fusetools.com/t/0-21-android-cant-select-text-inside-a-textview/4150/4 "2016-07-13T23:13:05Z")

</div>

Actually scratch that, I still have the bug. It’s just not happening on every TextView, just one specific one. It’s really hard to debug, but I finally found what was causing it. At the end of my .ux page, I have these lines:

```auto
<WhileInactive>
    <Change PairMessagingPage.Visibility="Collapsed" Delay="0.2" />
</WhileInactive>

```

If I delete the Change, the bug disappears. I need this node, as this is how I navigate between different pages. I don’t see any easy workaround, but maybe you get an idea of the root cause?

---

<div class="post-metadata">

**Author:** ![cyril.gantzer](https://avatars.discourse-cdn.com/v4/letter/c/ba9def/32.png) [@cyril.gantzer](https://forums.fusetools.com/u/cyril.gantzer)\
**Post date:** [July 13, 2016, 11:21pm UTC](https://forums.fusetools.com/t/0-21-android-cant-select-text-inside-a-textview/4150/5 "2016-07-13T23:21:27Z")

</div>

Full repro example (try selecting text in the TextView: no cursor):

```auto
<App>
<JavaScript>
    var Observable = require('FuseJS/Observable');
    var currentPage = Observable('First');

    module.exports = {
        currentPage: currentPage,
        navigate: function () {
            currentPage.value = 'Second';
        }
    }
</JavaScript>
<DirectNavigation ux:Name="NavMain" Active="{currentPage}" />
<Page ux:Name="First" Background="Red">
    <Tapped>
        <Callback Handler="{navigate}" />
    </Tapped>
    <WhileInactive>
        <Change First.Opacity="0" Duration="0.2" />
        <Change First.Visibility="Collapsed" Delay="0.2" />
    </WhileInactive>
</Page><Page ux:Name="Second" Background="White">
    <TextView ux:Name="GroupMessageInput" TextWrapping="Wrap" Padding="6,6,0,6" Value="Hi this is some kind of Lorem Ipsum that will get big enough so that it wraps around once or twice…" />
    <WhileInactive>
        <Change Second.Opacity="0" Duration="0.2" />
        <Change Second.Visibility="Collapsed" Delay="0.2" />
    </WhileInactive>
</Page>
</App>

```

---

<div class="post-metadata">

**Author:** ![Baggers](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/baggers/32/665_2.png) [@Baggers](https://forums.fusetools.com/u/Baggers)\
**Post date:** [July 25, 2016, 2:11pm UTC](https://forums.fusetools.com/t/0-21-android-cant-select-text-inside-a-textview/4150/6 "2016-07-25T14:11:33Z")

</div>

I’ve bumped this internally as I’m seeing a similar issue on the latest version. For me I can select but only after the device has rotated once. Sounds nasty.

Were on it though

---

<div class="post-metadata">

**Author:** ![Vegard\_Strand\_Lende](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/vegard_strand_lende/32/349_2.png) [@Vegard\_Strand\_Lende](https://forums.fusetools.com/u/Vegard_Strand_Lende)\
**Post date:** [July 25, 2016, 3:21pm UTC](https://forums.fusetools.com/t/0-21-android-cant-select-text-inside-a-textview/4150/7 "2016-07-25T15:21:18Z")

</div>

What device is this failing on? I can select text without problems at first try and also after reloads.

 ![file](https://s3.us-east-2.amazonaws.com/fuse-legacy-forum-assets/JyhJPuB60HYL-legacy-files-UAFS31z9fW85XJYe-LrXo9joluehge--c690CoAHq.png)

---

<div class="post-metadata">

**Author:** ![cyril.gantzer](https://avatars.discourse-cdn.com/v4/letter/c/ba9def/32.png) [@cyril.gantzer](https://forums.fusetools.com/u/cyril.gantzer)\
**Post date:** [July 25, 2016, 4:59pm UTC](https://forums.fusetools.com/t/0-21-android-cant-select-text-inside-a-textview/4150/8 "2016-07-25T16:59:19Z")

</div>

Nexus 5. Same behavior as Chris though: if I rotate the device, it works (and if I rotate it back to initial position, it’s fixed).

 ![file](https://s3.us-east-2.amazonaws.com/fuse-legacy-forum-assets/uJUlKxSOgc7Y-legacy-files-tONumiQiYclyv06Y-FxOij6EbY9TWYEwVuYWk-kFO.png)

 ![file](https://s3.us-east-2.amazonaws.com/fuse-legacy-forum-assets/WvzZLyRoaEa9-legacy-files-HbMjMH27MdEVJ7b8-dN6I4b2pCL3QvpHGvBcbJN_d.png)

 ![file](https://s3.us-east-2.amazonaws.com/fuse-legacy-forum-assets/Diu5p1O1rRs1-legacy-files-bkjR43fmiG70tKVy-eu2rgwTAwZVmPZLluOFV9mwo.png)

---

<div class="post-metadata">

**Author:** ![Vegard\_Strand\_Lende](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/vegard_strand_lende/32/349_2.png) [@Vegard\_Strand\_Lende](https://forums.fusetools.com/u/Vegard_Strand_Lende)\
**Post date:** [July 26, 2016, 10:25am UTC](https://forums.fusetools.com/t/0-21-android-cant-select-text-inside-a-textview/4150/9 "2016-07-26T10:25:48Z")

</div>

Hmm, this is very strange. My first test was on my Nexus 5, and there it works. I just tested on a Nexus 9 tablet, and there the bug does trigger as described. Kinda feels like something weird is going on in Android. Changing `Second.Visibility="Collapsed"` to `Second.Visibility="Hidden"` makes it work. You can use that as a fix in the meantime, it might take some time to track down the bug here.
