Can't set 240 refresh rate

Hi
I recently updated my monitor, and I have a problem reaching the desired refresh rate of 240hz. The monitor works well on another OS partition on the same system and Manjaro detects it, but not nvidia-settings or xrandr.

If I try to set it with

xrandr --output DP-4 --mode 5120x1440 --rate 240.00

nothing happens.

This is my xrandr

[carlos@ManJaro ~]$ xrandr
Screen 0: minimum 8 x 8, current 5120 x 1440, maximum 32767 x 32767
DP-0 disconnected (normal left inverted right x axis y axis)
DP-1 disconnected (normal left inverted right x axis y axis)
HDMI-0 disconnected (normal left inverted right x axis y axis)
DP-2 disconnected (normal left inverted right x axis y axis)
DP-3 disconnected (normal left inverted right x axis y axis)
DP-4 connected primary 5120x1440+0+0 (normal left inverted right x axis y axis) 1mm x 1mm
3840x1080    119.97 + 239.97    59.97  
5120x1440    120.00*   59.98  
2560x1440    239.90   120.00    59.95  
2560x1080    119.88    60.00    59.94  
1920x1080    119.88    60.00    59.94  
1680x1050     59.95  
1600x900      60.00  
1440x900      59.89  
1280x1024     75.02    60.02  
1280x800      59.81  
1280x720      60.00  
1152x864      75.00  
1024x768      75.03    70.07    60.00  
800x600       75.00    72.19    60.32    56.25  
640x480       75.00    72.81    59.94  
DP -5 disconnected (normal left inverted right x axis y axis)
USB-C-0 disconnected (normal left inverted right x axis y axis)

Hi!
Try to add that mode before you set it

Thanks, sorry for the question, how can I do it?

Hi!
Take a look at this link
Xrandr- Arch-Wiki

I followed the xrandr wiki, and tried to add that mode but

[carlos@ManJaro ~]$ xrandr --addmode DP-4 5120x1440_240.00
X Error of failed request:  BadMatch (invalid parameter attributes)
Major opcode of failed request:  140 (RANDR)
Minor opcode of failed request:  18 (RRAddOutputMode)
Serial number of failed request:  43
Current serial number in output stream:  44