im sorry, i was thinking you are usign this inside the gallery, this is a little bit confuse to me, if you try to use in a gallery, how you get the selection from this item? I mean, is not clear to me what you trying to do.
i guess you field is out of the gallery and you are not working inside the gallery.
if this is correct you can try something like this:
If(galleryname.Selected.columnname.Value="some text";"more some text";"other text")
but you must to have a way to select this item of a gallery.
you could get the value in other way, maybe get directly from you datasource or usign a collection, its a little bit obscure to me what you want comparing what you doing