📘 Lectures 1–5
Q1: What is Visual Programming?
A: It is the creation of GUI-based applications that respond to user actions using events.
Q2: What is WPF and why is it used?
A: WPF (Windows Presentation Foundation) is used to create rich desktop GUI applications
using XAML and C#.
Q3: What is event-driven programming?
A: A programming style where code is executed in response to user interactions like mouse
clicks or key presses.
Q4: What is XAML in WPF?
A: XAML is a markup language for defining UI elements in WPF applications.
Q5: What is the difference between StackPanel and Grid?
A: StackPanel arranges elements in a line (horizontally or vertically), while Grid arranges them
in rows and columns.
📘 Lectures 6–10
Q1: What is a namespace in C#?
A: A namespace organizes code and helps avoid name conflicts between classes.
Q2: What is the use of constructors?
A: Constructors initialize objects when a class is instantiated.
Q3: What is an anonymous method?
A: A method without a name, defined using the delegate keyword, often used in event
handling.
Q4: What is operator overloading?
A: Redefining how operators like +, -, *, etc., work for user-defined types.
Q5: Difference between List and Dictionary?
A: List stores items in order, Dictionary stores key-value pairs.
📘 Lectures 11–15
Q1: What are extension methods?
A: Methods that extend existing types without modifying them, defined as static.
Q2: How to write to a file in C#?
A: Using StreamWriter or File.WriteAllText() inside a using block.
Q3: What is BAML?
A: Binary Application Markup Language – a compiled version of XAML for faster loading.
Q4: What does x:Code do?
A: Embeds code inside a XAML file (not commonly used).
Q5: What does using do in file handling?
A: Ensures automatic disposal of file resources to prevent memory leaks.
📘 Lectures 16–20
Q1: What is a Dependency Property?
A: A property that supports data binding, styling, and automatic updates in WPF.
Q2: What is an Attached Property?
A: A property used by child elements that is defined in the parent, like Grid.Row.
Q3: What is GridSplitter?
A: A UI element that allows resizing of Grid rows or columns at runtime.
Q4: Grid Sizing Modes?
A: Absolute (fixed), Auto (fit content), and Star (*) which proportionally divides space.
Q5: Difference between Margin and Padding?
A: Margin is outer spacing; Padding is inner spacing inside the control.
📘 Lectures 21–22
Q1: Role of Grid.IsSharedSizeScope?
A: Allows multiple grids to share column or row sizes for consistent layout.
Q2: What are attached events?
A: Events that can bubble or tunnel through the element tree in WPF.
Q3: Meaning of Preview prefix in events?
A: Indicates a tunneling event that is handled before bubbling events.
Q4: What happens in AboutDialog MouseRightButtonDown?
A: Shows event source info in the title and draws a border around the clicked control.
Q5: Use of Control Templates in WPF?
A: To redefine the visual structure of a control without changing its logic.