@@ -22,68 +22,68 @@ The following tutorial demonstrates how you can add a simple **RadChat** control
22
22
23
23
>caption **Example 1**: Declaration of a **RadChat** control.
24
24
25
- ````ASPX
26
- <asp:ScriptManager runat="server" ID="ScriptManager1" />
27
- <telerik:RadChat ID="RadChat1" runat="server">
28
- </telerik:RadChat>
29
- ````
25
+ ```` ASPX
26
+ <asp:ScriptManager runat="server" ID="ScriptManager1" />
27
+ <telerik:RadChat ID="RadChat1" runat="server">
28
+ </telerik:RadChat>
29
+ ````
30
30
31
31
32
32
1 . Set some of the messages and user settings like ** Placeholder** , ** Name** and ** IconUrl** .
33
33
34
34
>caption **Example 2**: The chat now has a custom placeholder message, username and avatar
35
35
36
- ````ASPX
37
- <asp:ScriptManager runat="server" ID="ScriptManager1" />
38
- <telerik:RadChat runat="server" ID="RadChat1">
39
- <MessagesSettings Placeholder="Type your message here..." />
40
- <UserSettings Name="John" IconUrl="avatar.png" />
41
- </telerik:RadChat>
42
- ````
36
+ ```` ASPX
37
+ <asp:ScriptManager runat="server" ID="ScriptManager1" />
38
+ <telerik:RadChat runat="server" ID="RadChat1">
39
+ <MessagesSettings Placeholder="Type your message here..." />
40
+ <UserSettings Name="John" IconUrl="avatar.png" />
41
+ </telerik:RadChat>
42
+ ````
43
43
44
44
1 . Press F5 to run the application. You will see the chat that is displayed in ** Figure 1** . From this point you can start interacting with the chat.
45
45
46
46
>caption **Example 3**: Assigning the client-side event handlers:
47
47
48
- ````ASPX
49
- <asp:ScriptManager runat="server" ID="ScriptManager1" />
50
- <telerik:RadChat runat="server" ID="RadChat1" Width="300px" Height="300px">
51
- <ClientEvents
52
- OnActionClick="OnActionClick"
53
- OnInitialize="OnInitialize"
54
- OnLoad="OnLoad"
55
- OnPost="OnPost"
56
- OnSendMessage="OnSendMessage"
57
- OnTypingEnd="OnTypingEnd"
58
- OnTypingStart="OnTypingStart" />
59
- <MessagesSettings Placeholder="Type your message here..." />
60
- <UserSettings Name="John" IconUrl="avatar.png" />
61
- </telerik:RadChat>
62
- ````
63
-
64
- ````JavaScript
65
- function OnActionClick(sender, args) {
66
- }
67
-
68
- function OnInitialize(sender, args) {
69
- }
70
-
71
- function OnLoad(sender) {
72
- sender.postMessage("Hello!");
73
- }
74
-
75
- function OnPost(sender) {
76
- }
77
-
78
- function OnSendMessage(sender, args) {
79
- }
80
-
81
- function OnTypingEnd(sender, args) {
82
- }
83
-
84
- function OnTypingStart(sender, args) {
85
- }
86
- ````
48
+ ```` ASPX
49
+ <asp:ScriptManager runat="server" ID="ScriptManager1" />
50
+ <telerik:RadChat runat="server" ID="RadChat1" Width="300px" Height="300px">
51
+ <ClientEvents
52
+ OnActionClick="OnActionClick"
53
+ OnInitialize="OnInitialize"
54
+ OnLoad="OnLoad"
55
+ OnPost="OnPost"
56
+ OnSendMessage="OnSendMessage"
57
+ OnTypingEnd="OnTypingEnd"
58
+ OnTypingStart="OnTypingStart" />
59
+ <MessagesSettings Placeholder="Type your message here..." />
60
+ <UserSettings Name="John" IconUrl="avatar.png" />
61
+ </telerik:RadChat>
62
+ ````
63
+
64
+ ```` JavaScript
65
+ function OnActionClick (sender , args ) {
66
+ }
67
+
68
+ function OnInitialize (sender , args ) {
69
+ }
70
+
71
+ function OnLoad (sender ) {
72
+ sender .postMessage (" Hello!" );
73
+ }
74
+
75
+ function OnPost (sender ) {
76
+ }
77
+
78
+ function OnSendMessage (sender , args ) {
79
+ }
80
+
81
+ function OnTypingEnd (sender , args ) {
82
+ }
83
+
84
+ function OnTypingStart (sender , args ) {
85
+ }
86
+ ````
87
87
88
88
89
89
0 commit comments