You need to go through the Union Cave. From gfaqs:
If you head a bit to the left (note that you can fish in the water with the Old
Rod for Level 10 Magikarp and Goldeen) you will notice that you can go up as
well as down. For now, go up. Collect the X ATTACK to the left, then go straight
up. The first firebreather of the game will spot you, with quite the sprite.
Defeat his Vulpix, then go down the stairs.
Head straight forward and press A on the rock you hit to get a hidden X SPEED.
Keep going left to find a TM39 ROCK TOMB lying on the floor. This is a fairly
good Rock move with low PP but a 100% chance of lowering the target's speed
as well as a 50 base power. You may be better off with Rock Throw if you have
a Geodude or Onix, though but it could be a good asset for Sandshrew.
If you go to the northern part of the room, you can also get an X DEFEND.
use Surf to surf up into a new part of this floor. Battle the
hiker found here, then examine the small rock next to the larger, pointier
rock in the top right corner in relation to the hiker to find a hidden REVIVE.
Continue going up for another hiker, then follow the left route up the stairs.
Surf across the water here and go back onto land through the gap
take the southern path
instead of going left. Push the boulder a space to the left, then go up the
now exposed stairs. Just follow the path around and then exit the cave.
You'll be in the ruins again, but this time in some weird boulder maze. Be
careful not to jump over the ledge at the bottom (like I just did when I was
writing this >_>;) There's an invisible NUGGET on one of the mid boulders if
you use the Itemfinder. Find your way around - note that you can cross in front
of that green thing - and enter the ruin on the other side.
This time, we need a Water Stone. If you're lucky enough to have one, go up to
the painting and "Use" it and the wall will open. The stone itself won't be
used, thankfully. Go inside to find a STARDUST, STAR PIECE, MYSTIC WATER and
LEPPA BERRY.
In the main room, you can solve a puzzle of Omanyte. Do so, with the usual
touchscreen moving and rotating pieces to get thrown into the ruins with even
more Unown shapes unlocked. In fact, you should be able to catch all of the
regular twentysix alphabet letters now.
I think that's all, sorry if it got confusing because the guide kinda jumps around.
You get the ? and ! Unown after you catch the 26 other Unown. A new chamber in the main area is opened up after you get all 26 and talk to one of the researchers.