Thanks, well I found an easier solution.
I set the medium width for images, in the Media Settings page and there will be a version of the images I upload with that width, which is exactly what I need for my theme.
Thanks anyways for the suggestion ??
Take Care, Ovidiu