> For the complete documentation index, see [llms.txt](https://docs.customerglu.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.customerglu.com/schema/faq/how-to-find-and-add-screen-names-for-entrypoints.md).

# How to find and add Screen Names for Entrypoints

Check where you are using the below methods and verify the screen names. We will add the screen names that can be configured for the app in the dashboard in the next steps&#x20;

### Find Screen Name in App Code

Check in your code where you are using the below method and verify the screen names. We will add the screen names that we can configure for app in dashboard in next steps.

{% tabs %}
{% tab title="Android" %}
The given function should be used on **every Activity's** `onResume` Method

```java
@Override
protected void onResume() {
    super.onResume();
    customerGlu.showEntryPoint(MainActivity.this,"screenName");
} 
```

{% endtab %}

{% tab title="iOS" %}
The given function should be used on each **ViewController's** `viewWillAppear()` method:

```swift
override func viewWillAppear(_ animated: Bool) {
    super.viewDidLoad()
    customerGlu.setCurrentClassName(className: String(describing: type(of: self)))
}
```

{% endtab %}

{% tab title="Flutter" %}
The given code should be added on every Activity:

```dart
@override 
Widget build(BuildContext context) { 
return CGScreenDetector(
 classname: "screenName",
  child: Scaffold( 
  body: Container( 
  width: MediaQuery.of(context).size.width, 
  decoration: BoxDecoration(color: Colors.white), 
  child: Text("My Widget");
      ),
     )
    );
   }
  
```

**For Android:**

The given function should be used in `MainActivity` , inside the `onResume` method to support adding the floating button/popup entry points on the activity via the dashboard:

```java
@Override
protected void onResume() {
    super.onResume();
        CGUtils.setActivity(this);
} 
```

{% endtab %}

{% tab title="React Native" %}
The given function should be used on every Activity's `useFocusEffect()` Method :

```javascript
import { SetCurrentClassName } from '@customerglu/react-native-customerglu';
import { useFocusEffect, useRoute } from "@react-navigation/native";
const route = useRoute();
    useFocusEffect(
        React.useCallback(() => {
            SetCurrentClassName(route.name);
        }, [navigation])
    );
   
```

{% endtab %}
{% endtabs %}

### Add Screen Names to dashboard&#x20;

* Open the CustomerGlu dashboard
* Go to **Nudges section** and create a new nudge
* In the **Trigger Criteria Section** , add the screen name in the **Allowed Screen** field.&#x20;
  * If screen name exists then select the screen name&#x20;
  * If not then you can **Add Custom Screen name** that is configured on app code  <br>

<figure><img src="/files/68iF36oWhytE7ZEr7xDe" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/36DbXXWBFrzkKAdvagD6" alt=""><figcaption></figcaption></figure>

* Enter the Screen Name and click on  **SAVE**. Screen Name will be added in list.&#x20;
* Select the newly added screen name and launch a nudge.

{% hint style="warning" %}
Make sure Screen Name present in app needs to be same in dashboard
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.customerglu.com/schema/faq/how-to-find-and-add-screen-names-for-entrypoints.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
