![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
|
Welcome to Vista Forums we are your forum to discuss Windows Vista x64 and x86 systems. Whether you need help or just want to post an idea you have on Vista, this is the forum for you.
br> br> |
| |||||||
![]() |
| | Thread Tools | Display Modes |
| | #1 (permalink) |
| Guest | Urgent I want to know that I have created one custom activity and in that I have created main class and with that also created designer class and validator class but when I debug my solution the control goes inside the validator class but does not goes inside the designer class so I want to know that what is the entry point to debug the designer class so my control goes inside that the class for sample I am providing its syntax. From the main class i have to call the designer class before my main class started so i cannot place a break point at that location So please tell my what is the entry point of that class. calling of the class syntax is followings : [DesignerAttribute(typeof(LwSqlDbActivity.LwSqlDesigner))] Thank You and designer class is : public sealed class LwSqlDesigner : ActivityDesigner { protected override void Initialize(Activity activity) { base.Initialize(activity); this.DesignerTheme.BackColorStart = Color.White; this.DesignerTheme.BackColorEnd = ColorTranslator.FromHtml("#F9CB5A"); this.DesignerTheme.BackgroundStyle = System.Drawing.Drawing2D.LinearGradientMode.Vertical; this.DesignerTheme.BorderColor = ColorTranslator.FromHtml("#BF8311"); } protected override void PreFilterProperties(IDictionary properties) { base.PreFilterProperties(properties); UpdateSqlParametersList(properties); UpdateDynamicProperties(properties); } private void UpdateSqlParametersList(IDictionary properties) { if (this.Activity != null && this.Activity is LwSqlActivity) { LwSqlActivity activity = Activity as LwSqlActivity; try { if (activity.ConnectionString != null && activity.ConnectionString.Length > 0) { SqlCommand command = activity.CreateCommand(); //Build SQL parameters list if (activity.ConnectionString != null) { LwSqlHelper.GetTextParameters(command); } if (command.Parameters != null && command.Parameters.Count > 0) { for (int i = 0; i < command.Parameters.Count; i++) { PropertyDescriptor prop = new LwSqlParameterPropertyDescriptor(command.Parameters[i].ParameterName, LwSqlHelper.GetType(command.Parameters[i].SqlDbType), new Attribute[] { new ParenthesizePropertyNameAttribute(true) }); properties[prop.Name] = prop; } } } } catch (InvalidOperationException) { Console.WriteLine("Operation is invalid"); } } } private void UpdateDynamicProperties(IDictionary properties) { if (this.Activity != null && this.Activity is LwSqlActivity) { LwSqlActivity activity = Activity as LwSqlActivity; if (activity.ConnectionString == null) { properties.Remove("SourceTable"); } } } protected override void OnActivityChanged(ActivityChangedEventArgs e) { base.OnActivityChanged(e); TypeDescriptor.Refresh(e.Activity); } } Please reply as soon as possible |
![]() |
| Thread Tools | |
| Display Modes | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Urgent Help | vivek | Sound & Audio | 2 | 05-18-2008 11:19 AM |
| I need URGENT help | Milan | Vista account administration | 8 | 04-08-2007 06:42 PM |
| Urgent | chirag | Avalon | 0 | 09-27-2006 06:26 AM |
| urgent | chirag | Avalon | 0 | 09-23-2006 04:27 AM |
| Need help URGENT! | =?Utf-8?B?Tm9TcGluVmV0dGU=?= | Vista General | 0 | 09-15-2006 03:01 PM |