65.9K
CodeProject is changing. Read more.
Home

Sliding Up Popup Notification Like Skype

starIconstarIconstarIconstarIcon
emptyStarIcon
starIcon

4.79/5 (20 votes)

Nov 10, 2014

CPOL

1 min read

viewsIcon

49972

downloadIcon

2925

Sliding Up Popup Notification Like Skype

Introduction

This tip is about Skype Type of Sliding Pop up Message Notification. Whenever you call popup function, a new message will be shown like sliding bottom to top and gets appended with old message. Top message will get removed at its preset timeout and slowly will get collapsed. When you hover your mouse to popup window, a close button will appear on Top right of pop and you can close all popups quickly.

You can show up to X messages at a time.

Background

This is for multiple messages to be shown coming at the same time with different message types.

Header Text: This for giving name of your application.

Message Type: This is for giving Message header, e.g., Error, User name, Event Name.

Message detail: This field is for giving short discription of message. For example: Error detail, User Online/offine, Event Detail.

Icon: This field is for giving image symbol to your message.

Using the Code

Simple concept like Timer (for animation and message time out), Queue and manual paint event make this Sliding popup.

Whenever new message comes to queue, animation timer gets started and on tick window is moved up and at the same time painting event is called.

You can just import DLL in your project and just set the various parameters like time out message, font style, color, etc. before calling popup function.

public void popup(string strTitle, string strContent, 
int nTimeToShow, int nTimeToStay, int nTimeToHide, int notify, Image imageshow);
Sliding Up Popup Notification Like Skype - CodeProject