Hi, <gs id="15679284-25bd-49f1-9ea9-1eea49fd8be5" ginger_software_uiphraseguid="d7f3613a-3f8d-4eca-b5dd-83cd884cb307" class="GINGER_SOFTWARE_mark">i</gs> have excel that <gs id="8dd26a21-5427-47e7-85d8-6814c1ae4230" ginger_software_uiphraseguid="d7f3613a-3f8d-4eca-b5dd-83cd884cb307" class="GINGER_SOFTWARE_mark">i</gs> store all of my macros.
<gs id="19952d46-aa72-41ae-81b6-7bf760da52b4" ginger_software_uiphraseguid="827b5346-8358-408c-91b2-3d6a912ca1fe" class="GINGER_SOFTWARE_mark">i</gs> have build a macro to save my excel file in the same folder and with the same name, but <gs id="a0156244-1887-4515-b675-010bfd3fe425" ginger_software_uiphraseguid="827b5346-8358-408c-91b2-3d6a912ca1fe" class="GINGER_SOFTWARE_mark">i</gs> need to change the code to save it in XLSX Format and close the <gs id="7d28cddf-57b3-4df8-9b24-3335ce1f59b8" ginger_software_uiphraseguid="827b5346-8358-408c-91b2-3d6a912ca1fe" class="GINGER_SOFTWARE_mark">xls</gs> file and open the new XLSX one.
And my code not working that well in saving xD so need your help.
<gs id="19952d46-aa72-41ae-81b6-7bf760da52b4" ginger_software_uiphraseguid="827b5346-8358-408c-91b2-3d6a912ca1fe" class="GINGER_SOFTWARE_mark">i</gs> have build a macro to save my excel file in the same folder and with the same name, but <gs id="a0156244-1887-4515-b675-010bfd3fe425" ginger_software_uiphraseguid="827b5346-8358-408c-91b2-3d6a912ca1fe" class="GINGER_SOFTWARE_mark">i</gs> need to change the code to save it in XLSX Format and close the <gs id="7d28cddf-57b3-4df8-9b24-3335ce1f59b8" ginger_software_uiphraseguid="827b5346-8358-408c-91b2-3d6a912ca1fe" class="GINGER_SOFTWARE_mark">xls</gs> file and open the new XLSX one.
And my code not working that well in saving xD so need your help.
Code:
Dim <gs id="c49bc9df-9259-4387-8acf-85f1ac49c65e" ginger_software_uiphraseguid="cb90572d-a50a-418e-b30b-5ade04b1e6af" class="GINGER_SOFTWARE_mark">thisWb</gs> As Workbook, d As Integer
Set <gs id="d833f773-733f-4fe7-9d71-c3453a1f0dd8" ginger_software_uiphraseguid="8b3ebdb5-74ff-4c99-a7ad-69d7b9d40990" class="GINGER_SOFTWARE_mark">thisWb</gs> = ActiveWorkbook
Workbooks<gs id="8a3e72a9-2ae4-487c-bc68-b74671fa9acd" ginger_software_uiphraseguid="1242d18d-f84b-449e-9621-a5549e0ba993" class="GINGER_SOFTWARE_mark">.</gs>Add
<gs id="5d532443-4aa5-411c-8ead-498105808973" ginger_software_uiphraseguid="f35ee94e-527b-4123-92d3-5efda19e0da9" class="GINGER_SOFTWARE_mark">d</gs> = InStrRev<gs id="2203ed25-d714-4852-9d94-b6e96f835996" ginger_software_uiphraseguid="f35ee94e-527b-4123-92d3-5efda19e0da9" class="GINGER_SOFTWARE_mark">(</gs><gs id="c5266cae-a805-4521-82a8-6c4c2a4a9188" ginger_software_uiphraseguid="f35ee94e-527b-4123-92d3-5efda19e0da9" class="GINGER_SOFTWARE_mark">thisWb</gs><gs id="36d9fa5c-fbe8-4dc8-b352-ae492add2357" ginger_software_uiphraseguid="f35ee94e-527b-4123-92d3-5efda19e0da9" class="GINGER_SOFTWARE_mark">.</gs>FullName, ".")
ActiveWorkbook.SaveAs FileName:=Left(thisWb.FullName, d - 1) & Format(Now, " dd_mm_yyyy hhmmss") & Mid(thisWb.FullName, d)
<gs id="cdb61452-8294-4b56-9b43-7fab0a1ffcda" ginger_software_uiphraseguid="fb202e83-dfbc-4ea0-a6fe-1c5788a961f8" class="GINGER_SOFTWARE_mark">ActiveWorkbook</gs><gs id="36b00abe-764e-434c-82cd-6081209ccb54" ginger_software_uiphraseguid="fb202e83-dfbc-4ea0-a6fe-1c5788a961f8" class="GINGER_SOFTWARE_mark">.</gs>Close <gs id="25170763-d051-4e4f-b4f4-77a2602aa626" ginger_software_uiphraseguid="fb202e83-dfbc-4ea0-a6fe-1c5788a961f8" class="GINGER_SOFTWARE_mark">savechanges</gs><gs id="1ef29bc3-342a-4ea2-b24f-aa208eb83930" ginger_software_uiphraseguid="fb202e83-dfbc-4ea0-a6fe-1c5788a961f8" class="GINGER_SOFTWARE_mark">:</gs>=False