I'm using c#, and I would like to know if is there a way to read a specific message that is inside an eventhub. Not read them all and then search but have the offset or something similar and make something like a query to get that event
Event Hubs is a stream that can be only read in a forward-only manner; you don't have the ability to run a SQL-like query against it and find specific data based on arbitrary criteria. That said, with a bit of contextual knowledge, there are some options that would get you close.
If you know the partition that your event was published to and the offset or sequence number that was assigned to the event when it was published, then you can use that to specify that event as a starting point for your consumer. This sample illustrates the details.
If you know the partition and the approximate time that the event was published, you can use the same approach to start reading from a specific point in time and scan forward until you find the event that you're interested in. This sample illustrates the details.
If you don't know the partition or have any context around how the event was published, your only option would be to read from the beginning of each partition and scan forward to seek the event.