Is there a way to find the PackageFamilyName at runtime? - c#

Is there a way to figure out the PackageFamilyName (as appearing in the manifest) in runtime? I looked in /Program Files/WindowsApps and could not find the relevant string there. Could not find any API that would let me do this...
Any other ideas are welcome.

I think what you're looking for is PackageId.FamilyName which is available through the Package.Current.Id.FamilyName property.
Source: MSDN Forums

Related

WebContentTypeMapper doesn't exist in System.ServiceModel.Channels?

Wondering if anyone has had this issue before - from everything I'm reading 'WebContentTypeMapper' should live in 'System.ServiceModel.Channels' however it doesn't appear there when I try to access it.
Have I not got something installed in my environment that I should? I can't seem to find any good info on this.
Thanks
According to the documentation that type is in System.ServiceModel.Web.dll

Not getting how to use the execWB method

I am unable to get execWB working. Can any one show me how to initialize it or which namespace or dll file I need to include in order to use this method.
I am trying to zoom out the content on my browser.
You are in luck. Someone already wrote the interop for you.
Try looking at this Stackoverflow question. This CodeProject link concerns VB.Net but you might be able to get some useful information from it.

Sms/Dialog/Threads view in WP7

How I can create a view/control like in an sms/threads view?I was in searching for it much time, but didn't find anything.
wesevendays: take a look at this question, there is a link in my answer to a site where they describe how to mimic SMS bubbles.

DataGrid/View thing for WebMatrix

Yesterday I was on the microsoft webmatrix site looking at the docs, and I saw this thing on the right of the page, I think it was a tutorial or something for some kind of gridview thing for Webmatrix. Although I was interested I didn't take much notice of it as I was reading stuff about Razor. But now I'have spent all day and all night trying to find it again, (even visiting the same page), but I can't. All I can find is a few 3rd party open source things that don't look so friendly.
Does anyone know which one I'm refering to? Have you seen it/used it?
Finally!
I found it. It's the WebGrid.Helper.
Can be found here:
http://www.asp.net/webmatrix/tutorials/6-displaying-data-in-a-grid
http://www.mikesdotnetting.com/ has some good articles on how to expand the use of the webgrid helper that might be of interest.

C#. How to programmatically grant User Log On as a Service

I've searched through the internet, but haven't found any solution in c#. Does anybody know how to give user right to log on as a Service in c#?
EDIT: I found an article on CodeProject with sample code that shows exactly how to do this!
I assume you've already found this KB that shows how to do it with native code. I'm looking for a C# way as well.
I tried in vain to find this. The way I did it in the end was to package the NTRights executable with my application and then launch it as a separate process.
NTRights can be found on the server 2003 resource kti and its usage is documented here:
http://support.microsoft.com/kb/315276

Categories