Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
M

Mdnss

@Mdnss
About
Posts
4
Topics
1
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • Inheriting Eventhandler in VB.NET from C# class library
    M Mdnss

    Thank you, that builds. Finally: Can you point me to the right direction what this does/means?

    SomeControl.SiteReached += (s, ea) => miBack.Enabled = false;
    SomeControl.SiteOpened += (s, ea) => miBack.Enabled = true;
    SomeControl.ListOpened += new EventHandler(SomeControl_ListOpened);

    Should I ask in C# forum?

    Visual Basic csharp visual-studio help question

  • Inheriting Eventhandler in VB.NET from C# class library
    M Mdnss

    I'm sorry I wasn't clear what my question was. And thank you very much for your quick replies. I did the fix you suggested but still the error is there: 'SomeControl' is not an event of 'MyProject.Main' for

    RaiseEvent SomeControl.SiteReached

    Edit: I also added to the

    Private Sub MenuItem1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MenuItem1.Click

    SomeControl.SiteReached No luck.

    modified on Tuesday, February 16, 2010 4:50 AM

    Visual Basic csharp visual-studio help question

  • Inheriting Eventhandler in VB.NET from C# class library
    M Mdnss

    Yes I do. Actually the question is in the last code: What can I do to inherit those Eventhandlers?

    Visual Basic csharp visual-studio help question

  • Inheriting Eventhandler in VB.NET from C# class library
    M Mdnss

    Hi, Currently I'm working on a Smart Device project in VB.NET (in Visual Studio 2008) and I found a project on the net in C# which fits to my needs so I added to my solution as a class library. So right now I have a solution with a VB project and a C# project (class library). In the C# I have a part like this:

    namespace Something
    {
    public class SomeList : SomeListControl
    {
    public event EventHandler SiteReached;
    public event EventHandler SiteOpened;
    public event EventHandler ListOpened;
    ...

    This namespace is included in my VB project as a Reference.

    Public Class MainClass

    Private SomeControl As SomeList
    
    Private Sub MenuItem1\_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MenuItem1.Click
    
        'In the C# project the following code was implemented:
        'SomeControl.SiteReached += (s, ea) => miBack.Enabled = false;
        'SomeControl.SiteOpened += (s, ea) => miBack.Enabled = true;
        'SomeControl.ListOpened += new EventHandler(SomeControl\_ListOpened);
    
        'What can I do to inherit those Eventhandlers?
    

    ...

    Thank you in advance for your kind help.

    Visual Basic csharp visual-studio help question
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups