What should i do to fix grub rescue mode error ? i tried some grub commands to access gui but after rebooting it will happing the same

What have you tried:
ls
set root=(hd0,gptx)
set prefix=(hd0,gptx)/boot/grub
insmod normal
normal

and

grub-install /dev/sda
update-initramfs -u
update-grub

What is the error:
error: unknown filesystem
grub rescue mode

What device is this on: asus tuf gaming a17

use grub rescue to set boot parameters and boot into the installed system and then from a booted up system, repair grub.

hd0 will be the hard drive, but not a partition!