M
Madni
Dear All,
This chunk of code is working well in my servlet
Class myclass = Class.forName(strMgrApp);
//where strMgrApp actually holds the class TagImportExportMgrApp
TagImportExportMgrApp ob; // any class name
ob = (TagImportExportMgrApp) myclass.newInstance();
oImportExportMgr = (IImportExportMgr) ob;
//IImportExportMgr is interface which TagImportExportMgrApp implements
No runtime error is returned and i can access methods using object
"oImportExportMgr"
But !!!!!!!!!!!!!!!!!!!!!!!!!
whats the problem with this line below :
oImportExportMgr =(IImportExportMgr)
Class.forName(strMgrName).newInstance();
why it generates a runtime error stating :
java.lang.IllegalAccessError: tried to access class
WES.GenericComponents.UploadFile.IImportExportMgr from class
WES.GenericComponents.UploadFile.UploadManager
Any suggestion would be highly obliged
Regards ,
Madni
This chunk of code is working well in my servlet
Class myclass = Class.forName(strMgrApp);
//where strMgrApp actually holds the class TagImportExportMgrApp
TagImportExportMgrApp ob; // any class name
ob = (TagImportExportMgrApp) myclass.newInstance();
oImportExportMgr = (IImportExportMgr) ob;
//IImportExportMgr is interface which TagImportExportMgrApp implements
No runtime error is returned and i can access methods using object
"oImportExportMgr"
But !!!!!!!!!!!!!!!!!!!!!!!!!
whats the problem with this line below :
oImportExportMgr =(IImportExportMgr)
Class.forName(strMgrName).newInstance();
why it generates a runtime error stating :
java.lang.IllegalAccessError: tried to access class
WES.GenericComponents.UploadFile.IImportExportMgr from class
WES.GenericComponents.UploadFile.UploadManager
Any suggestion would be highly obliged
Regards ,
Madni