# CommonNumericTextBlock.CurrentNumericValue should be writable

**URL:** <https://forums.unrealengine.com/t/commonnumerictextblock-currentnumericvalue-should-be-writable/2232108>\
**Category:** Feedback & Requests\
**Tags:** unreal-engine, UI, Plugins\
**Created:** [December 19, 2024, 2:23pm UTC](https://forums.unrealengine.com/t/commonnumerictextblock-currentnumericvalue-should-be-writable/2232108 "2024-12-19T14:23:48Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Pink\_W0lf](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Pink\_W0lf](https://forums.unrealengine.com/u/Pink_W0lf)\
**Post date:** [December 19, 2024, 2:23pm UTC](https://forums.unrealengine.com/t/commonnumerictextblock-currentnumericvalue-should-be-writable/2232108/1 "2024-12-19T14:23:48Z")

</div>

UCommonNumericTextBlock’s CurrentNumericValue (from Common UI Plugin) is BlueprintReadOnly, despite there being a custom setter in the form of SetCurrentValue:

```auto
/**
 * Numeric text block that provides interpolation, and some type support (numbers, percents, seconds, distance).
 */
UCLASS(BlueprintType)
class COMMONUI_API UCommonNumericTextBlock : public UCommonTextBlock
{
	GENERATED_BODY()

public:
	[...]
	// Sets the current numeric value. NOTE: Cancels any ongoing interpolation!
	UFUNCTION(BlueprintCallable, Category = "Numeric Text Block")
	void SetCurrentValue(const float NewValue);
	[...]
	// The current numeric value being formatted for display, potentially being interpolated from. NOTE: The displayed text is very likely not identical to this value, due to formatting.
	UPROPERTY(EditAnywhere, BlueprintReadOnly, Category = "Numeric Text Block")
	float CurrentNumericValue;
	[...]

```

I believe CurrentNumericValue should logically reference its setter, instead of being labelled read only, probably like so:

```auto
	// The current numeric value being formatted for display, potentially being interpolated from. NOTE: The displayed text is very likely not identical to this value, due to formatting.
	UPROPERTY(EditAnywhere, BlueprintReadWrite, Setter = "SetCurrentValue", BlueprintSetter = "SetCurrentValue", Category = "Numeric Text Block")
	float CurrentNumericValue;

```

It being readonly also leads to problems, like not allowing you to bind the value to a float (using the UMG Viewmodel plugin), which instead results in this error on compilation:

 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/a/a/f/aaf92ac30034fc7c4dfb39cc479690165bffa8a9.png)

This problem also seems to exist in other parts of the plugin, like UCommonNumericTextBlock.NumericType and UCommonRichTextBlock.bIsScrollingEnabled

In comparison, for example the baseline UTextBlock’s Text is BlueprintReadWrite with a custom setters:

```auto
UCLASS(meta=(DisplayName="Text"), MinimalAPI)
class UTextBlock : public UTextLayoutWidget
{
	GENERATED_UCLASS_BODY()

public:
	UE_DEPRECATED(5.1, "Direct access to Text is deprecated. Please use the getter or setter.")
	/** The text to display */
	UPROPERTY(EditAnywhere, BlueprintReadWrite, Getter, Setter, BlueprintGetter="GetText", BlueprintSetter="SetText", Category="Content", meta = (MultiLine = "true"))
	FText Text;
	[...]

```

P.S: With the UMG Viewmodel plugin, while a bit more difficult, one can still functionally bind the value by binding the function that sets it, like so:

 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/5/f/7/5f74a1f35b547da8e8d7a635eb34f943bb6d6729.png)
