# How do I use custom view and system view together?

**URL:** <https://community.homey.app/t/how-do-i-use-custom-view-and-system-view-together/10529>\
**Category:** Developers\
**Tags:** app\
**Created:** [March 13, 2019, 10:54am UTC](https://community.homey.app/t/how-do-i-use-custom-view-and-system-view-together/10529 "2019-03-13T10:54:10Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![limkopi78](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/limkopi78/32/4234_2.png) [@limkopi78](https://community.homey.app/u/limkopi78)\
**Post date:** [March 13, 2019, 10:54am UTC](https://community.homey.app/t/how-do-i-use-custom-view-and-system-view-together/10529/1 "2019-03-13T10:54:10Z")

</div>

I’d like to create a view for users to key in ID, password and 2 more information. Once the driver has these informations, I’d like to call the system Device List view to display the list of devices retrieved from API.

In my app.json:  
“pair”: [  
{  
“id”: “connect”  
},  
{  
“id”: “list\_devices”,  
“template”: “list\_devices”,  
“navigation”: {  
“next”: “add\_devices”  
}  
},  
{  
“id”: “add\_devices”,  
“template”: “add\_devices”  
}  
]

The connect view has 4 fields and an apply button (which emit(‘connect’))

In my driver, I suppose do I do

onPair(socket){  
socket.on(‘connect’, function( data, callback ) {  
//calls API and retrieve and format JSON into devices array

```
    callback(null, 'devices');
}

```

}

I tried both socket.showView(‘list\_devices’) and socket.emit(‘list\_devices’) but I’m still stuck on the connect view. How do I go to the list device view and pass the devices along?

---

<div class="post-metadata">

**Author:** ![Jeroen\_Somhorst](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/jeroen_somhorst/32/184_2.png) [@Jeroen\_Somhorst](https://community.homey.app/u/Jeroen_Somhorst)\
**Post date:** [March 13, 2019, 10:55am UTC](https://community.homey.app/t/how-do-i-use-custom-view-and-system-view-together/10529/2 "2019-03-13T10:55:37Z")

</div>

Take a look at [https://github.com/jjtbsomhorst/eu.jeroensomhorst.domoticz/tree/beta](https://github.com/jjtbsomhorst/eu.jeroensomhorst.domoticz/tree/beta) i’m doing something similar there.

---

<div class="post-metadata">

**Author:** ![limkopi78](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/limkopi78/32/4234_2.png) [@limkopi78](https://community.homey.app/u/limkopi78)\
**Post date:** [March 13, 2019, 11:07am UTC](https://community.homey.app/t/how-do-i-use-custom-view-and-system-view-together/10529/3 "2019-03-13T11:07:08Z")

</div>

> [@Jeroen\_Somhorst](#):
>
> [GitHub - jjtbsomhorst/eu.jeroensomhorst.domoticz at beta](https://github.com/jjtbsomhorst/eu.jeroensomhorst.domoticz/tree/beta)

Thanks! Have been combing the appstore to look for examples. Will try this out!  
The other part of the app where main API calls happen is already done but stuck here for 2 days figuring out how to pass the information in before calling list device…
