# C++ exposed variable "In use pin no longer exists on node"

**URL:** <https://forums.unrealengine.com/t/c-exposed-variable-in-use-pin-no-longer-exists-on-node/447484>\
**Category:** Programming & Scripting\
**Tags:** unreal-engine\
**Created:** [April 19, 2019, 3:55am UTC](https://forums.unrealengine.com/t/c-exposed-variable-in-use-pin-no-longer-exists-on-node/447484 "2019-04-19T03:55:38Z")\
**Posts on this page:** 15\
**Page:** 1

<div class="post-metadata">

**Author:** ![Dr\_Artimos](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Dr\_Artimos](https://forums.unrealengine.com/u/Dr_Artimos)\
**Post date:** [April 19, 2019, 3:55am UTC](https://forums.unrealengine.com/t/c-exposed-variable-in-use-pin-no-longer-exists-on-node/447484/1 "2019-04-19T03:55:38Z")

</div>

Hello,  
I’m having this very frustrating situation that I’ve seen on a couple of posts here but nothing quite specific to my situation. I have a class in c++ that exposes a variable to be read in a blueprint (more specifically a Widget Blueprint). However, after having renamed a few variables in the c++ class, I get the following error every time I start up my project in UE4 now:

 ![274674-screen-shot-2019-04-18-at-104526-pm.jpg](https://d3kjluh73b9h9o.cloudfront.net/original/4X/6/1/6/616ff357ee0f5b846a59246a307a9aa3575921e1.jpeg)

For reference these are the relevant c++ classes that define and use this variable that I’m exposing.

Here is the class that defined the “chargedAttack” variable:

 ![274675-screen-shot-2019-04-18-at-104931-pm.png](https://d3kjluh73b9h9o.cloudfront.net/original/4X/c/7/f/c7fa3e97dc149177cdbb57f2eb6302ab921dcaa6.png)

And here is the class that uses that stores an instance of the Attack Type which has the chargedAttack variable:

 ![274676-screen-shot-2019-04-18-at-105006-pm.png](https://d3kjluh73b9h9o.cloudfront.net/original/4X/c/b/f/cbfa97330a0a196a7dfca57891e7071ee374c769.png)

I can temporarily fix this issue by just refreshing the node that is causing the problem, but I have to do that every time I open the editor. I have tried deleting and re-creating the BP function but that doesn’t help either.

This is my first post on here by the way so sorry if I put this in the wrong category.

---

<div class="post-metadata">

**Author:** ![Dr\_Artimos](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Dr\_Artimos](https://forums.unrealengine.com/u/Dr_Artimos)\
**Post date:** [May 6, 2019, 4:24am UTC](https://forums.unrealengine.com/t/c-exposed-variable-in-use-pin-no-longer-exists-on-node/447484/2 "2019-05-06T04:24:55Z")

</div>

Bump. Still not able to solve this problem.

I’ve tried deleting and recreating the source c++ that this variable comes from and its children blueprints as well as duplicating the blueprint trying to access this variable.

---

<div class="post-metadata">

**Author:** ![DeadlyMidnight](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@DeadlyMidnight](https://forums.unrealengine.com/u/DeadlyMidnight)\
**Post date:** [May 6, 2019, 7:28am UTC](https://forums.unrealengine.com/t/c-exposed-variable-in-use-pin-no-longer-exists-on-node/447484/3 "2019-05-06T07:28:23Z")

</div>

I’ve had this occur before when renaming variables or making major changes to a class, but don’t think Ive had it persist quite like that. You might want to try deleting your Intermediate and Build folders so you can get a fresh compile and see if that helps. Also just be sure your bp is properly compiling and saving.

---

<div class="post-metadata">

**Author:** ![Dr\_Artimos](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Dr\_Artimos](https://forums.unrealengine.com/u/Dr_Artimos)\
**Post date:** [May 6, 2019, 1:09pm UTC](https://forums.unrealengine.com/t/c-exposed-variable-in-use-pin-no-longer-exists-on-node/447484/4 "2019-05-06T13:09:04Z")

</div>

Unfortunately I’ve tried to delete my Intermediate, Build, and save folders and then rebuilding all the source files. Yet the problem persists.

After reconnecting the pins in question, the blueprint builds, saves and runs just fine. The only issue is that it reverts back when I close and reopen the engine.

Edit:  
I’ve also realized that this problem also appears when I am packaging the game into an executable. It gives the same error about not being able to find the “in ue pins”.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_e71ac9c71](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_e71ac9c71](https://forums.unrealengine.com/u/anonymous_user_e71ac9c71)\
**Post date:** [October 16, 2019, 5:29pm UTC](https://forums.unrealengine.com/t/c-exposed-variable-in-use-pin-no-longer-exists-on-node/447484/5 "2019-10-16T17:29:02Z")

</div>

Hello, were you able to resolve the issue while packaging? I’m running into something similar myself.

---

<div class="post-metadata">

**Author:** ![Dr\_Artimos](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Dr\_Artimos](https://forums.unrealengine.com/u/Dr_Artimos)\
**Post date:** [October 19, 2019, 11:56pm UTC](https://forums.unrealengine.com/t/c-exposed-variable-in-use-pin-no-longer-exists-on-node/447484/6 "2019-10-19T23:56:28Z")

</div>

Sorry man, I tried many things and nothing seems to have fixed the issue. I haven’t touched UE4 in like a half year because I’ve been busy with other things. I would have hoped that there would have been an answer or an engine update to fix this.

Please update this post if you ever figure out what the issue is so that others can know.

---

<div class="post-metadata">

**Author:** ![espaghetters](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@espaghetters](https://forums.unrealengine.com/u/espaghetters)\
**Post date:** [February 22, 2021, 12:45am UTC](https://forums.unrealengine.com/t/c-exposed-variable-in-use-pin-no-longer-exists-on-node/447484/7 "2021-02-22T00:45:01Z")

</div>

This can happen because you’ve added a class redirect that is the same name as a class that you previously had. For instance, what happened to me was that I had `UWeapon` and `AWeaponActor`. I realized that `AWeaponActor` is redundant, so I switched those names around:

```
AWeapon
UWeaponItem

```

As you may or may not know, Unreal Engine uses the `A` and `U` prefixes by convention because a lot of the code generation is knowing whether a class is an `UObject` or an `AActor`. For this reason Unreal Engine omits these prefixes from the class name, so in reality my `AWeapon` class was always named `Weapon`. When we think about it in these terms, `WeaponActor`, `WeaponItem`, and the one that collides: `Weapon`, are the only classes that have ever existed.

So after renaming these classes you’ve likely added your class redirects. The engine will continue to use these redirects as long as they exist in the `DefaultEngine.ini` file.

In my case, they looked like this:

```
+ActiveClassRedirects=(OldClassName="WeaponActor", NewClassName="Weapon")
+ActiveClassRedirects=(OldClassName="Weapon", NewClassName="WeaponItem")

```

Now that we know about how naming classes works, we can see the problem: `Weapon` is becoming `WeaponItem`, which is NOT the correct redirect. It was relevant when the class was a `UWeapon`, but it’s no longer correct when the class is an `AWeapon`. The engine, in its search for `AWeapon`, will instead refer to `UWeaponItem` when the editor starts.

This is an easy fix:

1. Make sure that all of your blueprints that had the old class have been reparented correctly (this is the reason the class redirects are so useful). It is EXTREMELY important that **you manually reparent all of the offending blueprints to the new redirect**.
2. Delete the class redirects.

The next time you launch the editor, the node will no longer complain.

---

<div class="post-metadata">

**Author:** ![espaghetters](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@espaghetters](https://forums.unrealengine.com/u/espaghetters)\
**Post date:** [February 22, 2021, 12:45am UTC](https://forums.unrealengine.com/t/c-exposed-variable-in-use-pin-no-longer-exists-on-node/447484/8 "2021-02-22T00:45:28Z")

</div>

Please see my comment for the answer. Hopefully this helps you with your project. Cheers.

---

<div class="post-metadata">

**Author:** ![3Daoist](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/3daoist/32/467556_2.png) [@3Daoist](https://forums.unrealengine.com/u/3Daoist)\
**Post date:** [January 6, 2023, 9:18pm UTC](https://forums.unrealengine.com/t/c-exposed-variable-in-use-pin-no-longer-exists-on-node/447484/9 "2023-01-06T21:18:27Z")

</div>

This is EXACTLY what is happening to me. I was willing to deal with the annoyance of having to refresh the nodes every time I opened the editor (I also found that CTRL ALT F11 hot building would also clean up the broken nodes) but now I am trying to package the game for testing and I’m getting that broken pin error every time it compiles regardless of whether I’ve fixed it in editor for that session.

---

<div class="post-metadata">

**Author:** ![3Daoist](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/3daoist/32/467556_2.png) [@3Daoist](https://forums.unrealengine.com/u/3Daoist)\
**Post date:** [January 6, 2023, 9:45pm UTC](https://forums.unrealengine.com/t/c-exposed-variable-in-use-pin-no-longer-exists-on-node/447484/10 "2023-01-06T21:45:25Z")

</div>

I am going to research this answer more. I am new to C++ and following a class/tutorial so my understanding of this answer is moderate at best but it seems like something important to understand better.

---

<div class="post-metadata">

**Author:** ![3Daoist](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/3daoist/32/467556_2.png) [@3Daoist](https://forums.unrealengine.com/u/3Daoist)\
**Post date:** [January 8, 2023, 5:58pm UTC](https://forums.unrealengine.com/t/c-exposed-variable-in-use-pin-no-longer-exists-on-node/447484/11 "2023-01-08T17:58:02Z")

</div>

Ah HA! So I was curious to see if the problem was connected to my use of the hot-reload compiler thing (CTRL-ALT-F11) to build my code each time. So I tried closing the editor completely and rebuilding the code in Visual Studio then reopening the project. Sure enough the project loaded without any broken pins and when I packaged the project it compiled just fine. Lesson learned.

---

<div class="post-metadata">

**Author:** ![cruecrue](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@cruecrue](https://forums.unrealengine.com/u/cruecrue)\
**Post date:** [September 12, 2023, 7:48am UTC](https://forums.unrealengine.com/t/c-exposed-variable-in-use-pin-no-longer-exists-on-node/447484/12 "2023-09-12T07:48:31Z")

</div>

This was really helpful, thanks!

---

<div class="post-metadata">

**Author:** ![Telkanile](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Telkanile](https://forums.unrealengine.com/u/Telkanile)\
**Post date:** [March 12, 2024, 1:56pm UTC](https://forums.unrealengine.com/t/c-exposed-variable-in-use-pin-no-longer-exists-on-node/447484/13 "2024-03-12T13:56:29Z")

</div>

This is what fixed the issue for me on UE5.3, thank you for posting. I had this issue with a C++ function exposed to blueprint and also some C++ BTTasks added to a behavior tree that also threw errors on startup constantly. I closed UE5 editor completely, went into Rider and did ‘clean solution’ and ‘build solution’, then re-opened my project in UE5 and voila! it all worked finally!! It does seem to be an issue related to live-coding compiles.

---

<div class="post-metadata">

**Author:** ![mbellay](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@mbellay](https://forums.unrealengine.com/u/mbellay)\
**Post date:** [December 12, 2024, 6:22pm UTC](https://forums.unrealengine.com/t/c-exposed-variable-in-use-pin-no-longer-exists-on-node/447484/14 "2024-12-12T18:22:23Z")

</div>

This worked for me as well, thank you!

---

<div class="post-metadata">

**Author:** ![SixelA\_EG](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/sixela_eg/32/1118994_2.png) [@SixelA\_EG](https://forums.unrealengine.com/u/SixelA_EG)\
**Post date:** [November 4, 2025, 2:35pm UTC](https://forums.unrealengine.com/t/c-exposed-variable-in-use-pin-no-longer-exists-on-node/447484/15 "2025-11-04T14:35:18Z")

</div>

This worked as well for me !  
(even though the function in blueprint which had the error didn’t have any pin to begin with. it was a blueprint function library declared in cpp, and used in blueprint, with no pin except exec pin.)
