How to get assembly (module) name?

Topics: Core, Writing modules
Dec 25, 2011 at 1:22 PM


I'm trying to get my assembly (module) name via type of controller in this module like this:

namespace MyModuleName.Controllers
	public class AdminController : Controller, IUpdateModel

		public string GetMyModuleName()
			return this.GetType().Assembly.GetName().Name;


But i get something like this:  App_Web_tsnixv3r

 How can I should do this to get MyModuleName?

Dec 27, 2011 at 8:42 AM

Looks like it's really the root namespace that you are after.