About box in GUI

Ask questions about creating Graphical User Interfaces (GUI) in PowerShell and using WinForms controls.
Forum rules
Do not post any licensing information in this forum.

Any code longer than three lines should be added as code using the 'Select Code' dropdown menu or attached as a file.
This topic is 11 years and 3 weeks old and has exceeded the time allowed for comments. Please begin a new topic or use the search feature to find a similar but newer topic.
Locked
User avatar
jimbobukii
Posts: 52
Last visit: Mon Dec 04, 2017 9:59 am

About box in GUI

Post by jimbobukii »

I am looking to have Menu Items within my PowerShell GUI but I am stuck with an about Dialog, could some one tell me how to call a dialog with all my details like version number etc?
jvierra
Posts: 15439
Last visit: Tue Nov 21, 2023 6:37 pm
Answers: 30
Has voted: 4 times
Been upvoted: 33 times

Re: About box in GUI

Post by jvierra »

Can you try to clarify your question. It does not make much sense.

Are you asking how to add a menu to a form?
User avatar
davidc
Posts: 5913
Last visit: Mon Jul 08, 2019 8:55 am
Been upvoted: 2 times

Re: About box in GUI

Post by davidc »

FYI I moved the post to the PowerShell GUIs forum.

This really depends on the tool you are using. PowerShell Studio supports multi-form projects. It will involve more work if you use PrimalForms CE.
In either case I recommend looking at the Tic Tac Plebius game:

http://www.sapien.com/blog/2011/04/26/t ... hell-game/

It has an about box.

David
David
SAPIEN Technologies, Inc.
jvierra
Posts: 15439
Last visit: Tue Nov 21, 2023 6:37 pm
Answers: 30
Has voted: 4 times
Been upvoted: 33 times

Re: About box in GUI

Post by jvierra »

David - I am guessing that the question is asking how to add the information to an about box.

Good call. I couldn't get that out of the question at first.
User avatar
jimbobukii
Posts: 52
Last visit: Mon Dec 04, 2017 9:59 am

Re: About box in GUI

Post by jimbobukii »

Thanks all,

I used the following....


PowerShell Code
Double-click the code block to select all.
$formNewApplicationName_Load={
	#TODO: Initialize Form Controls here
$authorVersion = '1.0'
$authorDate = 'March 2013'
$authorName = 'Jason Rose'
$authorEmail = 'jrose@yyyy.net.uk'
$authorWebsite = 'http://yyyyy.co.uk'
$authorDitty = "Lorem Ipsum is simply dummy text of the printing and typesetting industry. 
Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. 
It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. 
It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum."
$authorAppName = $formNewApplicationName.Text
}

$aboutToolStripMenuItem_Click={
	#TODO: Place custom script here
	[void][System.Windows.Forms.MessageBox]::Show("Version:`t$authorVersion ($authorDate)`nEmail:`t$authorEmail`nWebSite:`t$authorWebsite`n`n$authorDitty","About $authorAppName")

}
User avatar
davidc
Posts: 5913
Last visit: Mon Jul 08, 2019 8:55 am
Been upvoted: 2 times

Re: About box in GUI

Post by davidc »

I was just about to suggest a message box if you only care about displaying text.

David
David
SAPIEN Technologies, Inc.
This topic is 11 years and 3 weeks old and has exceeded the time allowed for comments. Please begin a new topic or use the search feature to find a similar but newer topic.
Locked