asp.net - How do i get the tab name in a usercontrol umbraco -
does enyone know how tabname can id dont know how name... code far:
int userid = umbraco.basepages.umbracoensuredpage.getuserid(umbraco.basepages.umbracoensuredpage.umbracousercontextid); documenttype typetocreate = documenttype.getbyalias("faqitem"); document newdoc = document.makenew("test123", typetocreate, new global::umbraco.businesslogic.user(userid), 1161); newdoc.getproperty("yourname").value = newdoc.getproperty("question"); foreach(var prop in newdoc.genericproperties) { newdoc.getproperty("email").value += prop.propertytype.tabid + " "; }
i managed same using .getvirtualtabs, like:
foreach (var t in dt.getvirtualtabs()) { if (t.id == id) return t.caption; }
Comments
Post a Comment