mercredi 1 avril 2015

Vba, Macro code. Excel 2013

Im trying to search for a file, in d:\ folder with the name Division_Application_Partner.xlsx where Division Application and Partner are variables holding string values.


This is the code I gave:



Set WorkbookPath = Dir(path & Division + "_" + Application + "_" + TradingPartner + ".xlsx")


It throws an error saying " Compile Error: Type Mismtach "


Is the name of the file im giving wrong


Aucun commentaire:

Enregistrer un commentaire