Click here to Skip to main content
15,893,663 members
Home / Discussions / C#
   

C#

 
AnswerRe: Retrieving GMail Contacts Pin
Russ-T16-Mar-10 20:19
Russ-T16-Mar-10 20:19 
QuestionConnecting to Remote SQL Server Pin
benzima16-Mar-10 15:59
benzima16-Mar-10 15:59 
AnswerRe: Connecting to Remote SQL Server Pin
PIEBALDconsult16-Mar-10 17:06
mvePIEBALDconsult16-Mar-10 17:06 
AnswerRe: Connecting to Remote SQL Server Pin
Russ-T16-Mar-10 17:57
Russ-T16-Mar-10 17:57 
QuestionGeneric event? Pin
Sirenfal16-Mar-10 15:04
Sirenfal16-Mar-10 15:04 
AnswerRe: Generic event? Pin
PIEBALDconsult16-Mar-10 15:44
mvePIEBALDconsult16-Mar-10 15:44 
GeneralRe: Generic event? Pin
Sirenfal16-Mar-10 16:30
Sirenfal16-Mar-10 16:30 
AnswerRe: Generic event? Pin
Gideon Engelberth16-Mar-10 18:06
Gideon Engelberth16-Mar-10 18:06 
My assumption is that the answer for this is that you cannot have a generic event for the same reason you cannot have a generic field in a non-generic class (or of a generic type that is not a type parameter for the class containing the field). If this was allowed, your class would have to vary in size depending on how many different events were used by external code, which of course is not allowed.

The best option that comes to mind is making all of the packet classes can inherit from some base packet class. Then you can make the event use that base class and have the handlers only process packets of the expected type.
GeneralRe: Generic event? Pin
Sirenfal16-Mar-10 18:34
Sirenfal16-Mar-10 18:34 
GeneralRe: Generic event? Pin
Gideon Engelberth17-Mar-10 3:29
Gideon Engelberth17-Mar-10 3:29 
QuestionReplace two table's items with eachother in SQL Pin
teknolog12316-Mar-10 13:00
teknolog12316-Mar-10 13:00 
AnswerRe: Replace two table's items with eachother in SQL Pin
Luc Pattyn16-Mar-10 13:24
sitebuilderLuc Pattyn16-Mar-10 13:24 
GeneralRe: Replace two table's items with eachother in SQL Pin
teknolog12316-Mar-10 23:55
teknolog12316-Mar-10 23:55 
AnswerRe: Replace two table's items with eachother in SQL Pin
Dan Mos16-Mar-10 15:03
Dan Mos16-Mar-10 15:03 
GeneralRe: Replace two table's items with eachother in SQL Pin
teknolog12317-Mar-10 2:35
teknolog12317-Mar-10 2:35 
GeneralRe: Replace two table's items with eachother in SQL Pin
Dan Mos21-Mar-10 5:26
Dan Mos21-Mar-10 5:26 
GeneralRe: Replace two table's items with eachother in SQL Pin
teknolog12322-Mar-10 2:46
teknolog12322-Mar-10 2:46 
QuestionWhy it doesn't eat SYSTEM MEMORY???? Pin
Nick Reshetinsky16-Mar-10 7:00
Nick Reshetinsky16-Mar-10 7:00 
AnswerRe: Why it doesn't eat SYSTEM MEMORY???? Pin
OriginalGriff16-Mar-10 7:23
mveOriginalGriff16-Mar-10 7:23 
AnswerRe: Why it doesn't eat SYSTEM MEMORY???? Pin
Luc Pattyn16-Mar-10 7:25
sitebuilderLuc Pattyn16-Mar-10 7:25 
AnswerRe: Why it doesn't eat SYSTEM MEMORY???? Pin
Dave Kreskowiak16-Mar-10 8:06
mveDave Kreskowiak16-Mar-10 8:06 
AnswerRe: Why it doesn't eat SYSTEM MEMORY???? Pin
AspDotNetDev16-Mar-10 9:17
protectorAspDotNetDev16-Mar-10 9:17 
GeneralRe: Why it doesn't eat SYSTEM MEMORY???? Pin
Luc Pattyn16-Mar-10 9:23
sitebuilderLuc Pattyn16-Mar-10 9:23 
GeneralRe: Why it doesn't eat SYSTEM MEMORY???? Pin
AspDotNetDev16-Mar-10 10:17
protectorAspDotNetDev16-Mar-10 10:17 
GeneralRe: Why it doesn't eat SYSTEM MEMORY???? Pin
Luc Pattyn16-Mar-10 10:27
sitebuilderLuc Pattyn16-Mar-10 10:27 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.