View previous topic :: View next topic |
Author |
Message |
Pointeman
Joined: 07 Sep 2010 Posts: 56
|
Posted: Sat Sep 18, 2010 6:40 pm Post subject: Need 'evaluationDaysLabel' customizable! |
|
|
I'm requesting the 'evaluationDaysLabel' customizable like the accessable 'EvaluationMessage' label, etc...
Note: I appreciate Infralutions 'source code' openness, but I would rather work with parameters, etc...
Again, great support! |
|
Back to top |
|
|
Infralution
Joined: 28 Feb 2005 Posts: 5027
|
Posted: Mon Sep 20, 2010 12:34 am Post subject: |
|
|
If you don't want to modify the actual source code you can derive a new Form from EvaluationDialog and simply change the label directly eg
Code: | class MyEvaluationDialog : EvaluationDialog
{
public MyEvaluationDialog(EvaluationMonitor monitor, string productName)
: base(monitor, productName)
{
this.evaluationDaysLabel.Text = "Custom message - day {0} of your {1} day evaluation";
}
} |
You can either do that using code (as above) or using the Visual Studio designer to create an inherited form and then change the properties you want using the designer. This allows you to change any of the properties of the form including text, font, layout and colors.
Then your calling code uses the derived dialog eg
Code: | MyEvaluationDialog evaluationDialog = new MyEvaluationDialog(evaluationMonitor, Application.ProductName);
EvaluationDialogResult dialogResult = evaluationDialog.ShowDialog(); |
_________________ Infralution Support |
|
Back to top |
|
|
Pointeman
Joined: 07 Sep 2010 Posts: 56
|
Posted: Tue Sep 21, 2010 12:24 am Post subject: |
|
|
Understood, I'm requesting the 'evaluationDaysLabel' customizable like the accessable 'EvaluationMessage' label, etc. It's the only setting you didn't include.
Personally, I don't want to manipulate your code because of possible future code updates. I like to stick with available param, etc...
Thanks for the help. |
|
Back to top |
|
|
Infralution
Joined: 28 Feb 2005 Posts: 5027
|
Posted: Tue Sep 21, 2010 7:50 am Post subject: |
|
|
We can add a property to allow you to access this label property externally from the form in a future release. However the approach I outlined previously doesn't require you to modify our code - since you derive a new class from our existing EvaluationDialog class and override the property in the derived class. This means that you won't have issues with future updates. _________________ Infralution Support |
|
Back to top |
|
|
|