# why am I getting a casting failed here. can someone tell me what i did wrong?

**URL:** <https://forums.unrealengine.com/t/why-am-i-getting-a-casting-failed-here-can-someone-tell-me-what-i-did-wrong/1910382>\
**Category:** UI\
**Tags:** unreal-engine, Blueprint, question\
**Created:** [June 20, 2024, 3:04pm UTC](https://forums.unrealengine.com/t/why-am-i-getting-a-casting-failed-here-can-someone-tell-me-what-i-did-wrong/1910382 "2024-06-20T15:04:29Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Leshrac231](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Leshrac231](https://forums.unrealengine.com/u/Leshrac231)\
**Post date:** [June 20, 2024, 3:04pm UTC](https://forums.unrealengine.com/t/why-am-i-getting-a-casting-failed-here-can-someone-tell-me-what-i-did-wrong/1910382/1 "2024-06-20T15:04:29Z")

</div>

![image_2024-06-20_213332355](https://d3kjluh73b9h9o.cloudfront.net/original/4X/4/9/3/493706afe41b9a64cb1b26518a49f2aa08fc2236.png)  
 ![image_2024-06-20_213354989](https://d3kjluh73b9h9o.cloudfront.net/original/4X/4/9/9/499e845af60c2e437e4faca11a47f1458f47ddac.png)  
 ![image_2024-06-20_213412856](https://d3kjluh73b9h9o.cloudfront.net/original/4X/c/8/7/c87a16fceae092939c0c70b77853b02f384c0d22.png)

---

<div class="post-metadata">

**Author:** ![Everynone](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/everynone/32/1135017_2.png) [@Everynone](https://forums.unrealengine.com/u/Everynone)\
**Post date:** [June 20, 2024, 3:36pm UTC](https://forums.unrealengine.com/t/why-am-i-getting-a-casting-failed-here-can-someone-tell-me-what-i-did-wrong/1910382/2 "2024-06-20T15:36:25Z")

</div>

Duplicate thread:

> [@Can someone tell me why my widget component is failing to cast my widget?](https://forums.unrealengine.com/t/can-someone-tell-me-why-my-widget-component-is-failing-to-cast-my-widget/1910364):
>
> first picture is from my actor component, im successing in getting the function i made in my widget component. this is my widget component function. I dont know why but my code is failing to cast my widget and is not succeeding in casting the function from my widget
