if running a Demo (demo CD/DVD) version, version is set to Demo and it will display the demo EULA
Will force a “SAMPLE” watermark when running a Demo version (demo CD/DVD) if running a Demo (demo CD/DVD) display the demo EULA the first time PROMS is run gets for ReleaseMode and EULA file names Disable RO Editor when running a Demo version
This commit is contained in:
@@ -7,6 +7,7 @@ using System.Reflection;
|
||||
using Volian.Controls.Library;
|
||||
using VEPROMS.CSLA.Library;
|
||||
using System.Text.RegularExpressions;
|
||||
using Volian.Base.Library;
|
||||
|
||||
namespace VEPROMS
|
||||
{
|
||||
@@ -22,14 +23,16 @@ namespace VEPROMS
|
||||
// - AssemblyInfo.cs
|
||||
//"Data Source=.\\SQLEXPRESS;Initial Catalog=VEPROMS_RGE_SAMG_Convert;Integrated Security=True"
|
||||
DateTime buildDateTime = new System.IO.FileInfo(Assembly.GetExecutingAssembly().Location).LastWriteTime;
|
||||
// If the AssemblyConfiguration is "DEMO" then we are running a Demo version
|
||||
string demoTxt = VlnSettings.ReleaseMode.Equals("DEMO")?"(Demo)": "";
|
||||
string connectionString = Database.VEPROMS_Connection;
|
||||
Match mServer = Regex.Match(connectionString,".*Data Source=([^;]*).*");
|
||||
string server = (mServer.Success)?mServer.Groups[1].Value:"unknown";
|
||||
if (server.StartsWith(@".\")) server = @"Local \ " + server.Substring(2);
|
||||
string databaseName = Database.SelectedDatabase;
|
||||
this.Text = String.Format("About {0}", AssemblyTitle);
|
||||
this.Text = String.Format("About {0}", AssemblyTitle + " " + demoTxt);
|
||||
this.labelProductName.Text = AssemblyProduct;
|
||||
this.labelVersion.Text = String.Format("Version {0}", AssemblyVersion);
|
||||
this.labelVersion.Text = String.Format("Version {0}", (demoTxt.Equals(""))? AssemblyVersion : demoTxt);
|
||||
this.labelVersionDateTime.Text = String.Format("Build Date: {0}", buildDateTime.ToString());
|
||||
this.labelCopyright.Text = AssemblyCopyright;
|
||||
this.labelCompanyName.Text = AssemblyCompany;
|
||||
@@ -146,7 +149,8 @@ namespace VEPROMS
|
||||
|
||||
private void btnViewEULA_Click(object sender, EventArgs e)
|
||||
{
|
||||
string strEULA = System.Environment.CurrentDirectory + "\\EULA.TXT";
|
||||
string EulaFile = string.Format(@"\{0}", VlnSettings.EULAfile);
|
||||
string strEULA = System.Environment.CurrentDirectory + EulaFile;
|
||||
frmViewTextFile ViewFile = new frmViewTextFile(strEULA,RichTextBoxStreamType.PlainText);
|
||||
ViewFile.Text = "End-User License Agreement";
|
||||
ViewFile.ShowDialog();
|
||||
|
@@ -7,6 +7,7 @@ using System.Text;
|
||||
using System.Windows.Forms;
|
||||
using Volian.Print.Library;
|
||||
using VEPROMS.CSLA.Library;
|
||||
using Volian.Base.Library;
|
||||
|
||||
namespace VEPROMS
|
||||
{
|
||||
@@ -45,7 +46,9 @@ namespace VEPROMS
|
||||
{
|
||||
OpenPDF = openPDF;
|
||||
InitializeComponent();
|
||||
MyPromsPrinter = new PromsPrinter(myItem, rev, revDate, watermark, debugOutput, origPgBrk, pdfPath + @"\\Compare", false, overWrite, cbd, pdfFile);//openPDF);
|
||||
// if the version number of PROMS is 1.0, then we are running a Demo version.
|
||||
// When running a Demo version, force a "Sample" watermark when printing.
|
||||
MyPromsPrinter = new PromsPrinter(myItem, rev, revDate, (VlnSettings.ReleaseMode.Equals("DEMO")) ? "Sample" : watermark, debugOutput, origPgBrk, pdfPath + @"\\Compare", false, overWrite, cbd, pdfFile);//openPDF);
|
||||
PDFPath = pdfPath;
|
||||
this.Text = "Creating PDF of " + myItem.DisplayNumber;
|
||||
_NewLocation = newLocation;
|
||||
|
@@ -463,7 +463,8 @@ namespace VEPROMS
|
||||
}
|
||||
private DialogResult ShowEULA()
|
||||
{
|
||||
string strEULA = System.Environment.CurrentDirectory + "\\EULA.TXT";
|
||||
string eulaFile = string.Format(@"\{0}", VlnSettings.EULAfile);
|
||||
string strEULA = System.Environment.CurrentDirectory + eulaFile;
|
||||
frmViewTextFile ViewFile = new frmViewTextFile(strEULA, RichTextBoxStreamType.PlainText);
|
||||
ViewFile.Text = "End-User License Agreement";
|
||||
ViewFile.ButtonText = "Agree";
|
||||
|
Reference in New Issue
Block a user