First of all, group IDs (GID) below 1000 are used by the system and other no-login groups and usually not as primary group for normal user accounts. You should give your user a GID above 1000, ideally the same number as its user ID (UID).
Second, file system ownership is bound to user/group IDs, not names. Therefore changing your account's UID and GID will make it lose all rights on files it owned before.
This means you have to reassign the ownership of that account's home directory to the new UID/GID pair. The most important file here is probably the ~/.Xauthority file. If that one is not owned by the correct user, it will not be able to log into the graphical desktop.
You recursively change the ownership of a directory with this command:
sudo chown -R USER:GROUP DIRECTORY
Simply replace USER and GROUP with the respective name or ID and use your old user's home directory (e.g. /home/myoldlogin) as DIRECTORY. The command you have to run could then look like this:
sudo chown -R 1026:1000 /home/myoldlogin