Solved

WPF About Box

Posted on 2011-09-28
4
1,288 Views
Last Modified: 2013-12-17
I have a solution with multiple projects (applications). Now I want to create an "About" window (production/company info, etc..) on a control library so that I can reuse it on all my applications.

I have tried PedroSilva's AboutBox template which works fine if the window is on the same project as the application.

i.e. The About window automatically gets the Assembly Title, Description, etc... But since the About window is on a control library in my case, it is getting the assembly information for the control library.

How can I modify it so that it gets the assembly information of the running WPF application?
0
Comment
Question by:Thomasian
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 4

Expert Comment

by:theHollow
ID: 36813273
Hello
I would create my own control with similar design.
That way, I would have full controll over the information, and it would be no problem to add more information at a later point.
0
 
LVL 22

Author Comment

by:Thomasian
ID: 36813500
The AboutBox is just a template and is fully customizable. The code that gets the assembly information can be modified. The problem is it is getting the assembly information of the controllibrary and not the wpf application.
0
 
LVL 4

Accepted Solution

by:
theHollow earned 500 total points
ID: 36813558
Aha
In that case...

This will get you the name of the DLL (control library):
Assembly.GetExecutingAssembly().FullName

And this will get you the name of the EXE:
Assembly.GetEntryAssembly().FullName

And if you need it, this will get you the outer calling assembly:
Assembly.GetCallingAssembly().FullName
When you run your app from Visual Studio, this would be "PresentationCore".
So stick to the two first :-)

You have more choices than "FullName" available.

Hope I understood you correctly :-)
0
 
LVL 22

Author Closing Comment

by:Thomasian
ID: 36813593
Thanks! That's perfect!
0

Featured Post

Monthly Recap

May was a big month for new releases from Linux Academy! Take a look at what our team built recently in our blog. You can access the newest releases from our blog.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A theme is a collection of property settings that allow you to define the look of pages and controls, and then apply the look consistently across pages in an application. Themes can be made up of a set of elements: skins, style sheets, images, and o…
A long time ago (May 2011), I have written an article showing you how to create a DLL using Visual Studio 2005 to be hosted in SQL Server 2005. That was valid at that time and it is still valid if you are still using these versions. You can still re…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question