![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
| Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks. |
| |||||||
| |
| | #1 (permalink) |
| | 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 |
My System Specs![]() |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Forum | |||
| URGENT HELP | Vista installation & setup | |||