subracting specific word from a variable file name
<p>This might be easy for many of you but i am new in VBA.I have an Excel file with variable name which is "Dateiname" and i would like to update this "Dateiname" by adding variable "hops". My Problem is Dateiname has already ".xlsm" inside of it and i want ".xlsm" Extension to be gone after the Dateiname, so i can add "hops" variable to "Dateiname" and end it with ".xlsm" Extension. </p>

<pre><code>    Dim hops as String
    Dim Dateiname as String

 Dateiname = Dateiname &amp; hops &amp; ".xlsm"
</code></pre>

<p>How can i do this ?</p>