java - How get file path from property file and pass into the method as arguments -


in property file:

folderpath=c:\pre-configured/import.csv

in main class im passing path argument method load

properties pro = new properties(); new csv().load(con,"pro.folderpath", "validation"); 

but giving error as:

pro.getproperty(folderpath) (the system cannot find file specified.) 

please in passing path method argument.

you need load properties file first:

filereader reader = new filereader( "your properties file path" );  properties prop2 = new properties(); prop2.load( reader ); prop2.list( system.out ); 

Popular posts from this blog

php - How should I create my API for mobile applications (Needs Authentication) -

5 Reasons to Blog Anonymously (and 5 Reasons Not To)

Google AdWords and AdSense - A Dynamic Small Business Marketing Duo