Print Page | Close Window

Hyperlink-Click Event in Markups

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Controls
Forum Description: Topics Related to Codejock Controls
URL: http://forum.codejock.com/forum_posts.asp?TID=12062
Printed Date: 23 November 2024 at 2:32am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Hyperlink-Click Event in Markups
Posted By: Jebo
Subject: Hyperlink-Click Event in Markups
Date Posted: 03 September 2008 at 2:58pm
Thank you for Beta 12.1
 
But how do I use now the Args parameter in the Click event?

Public Sub Click(ByVal Sender As Object, ByVal Args As Object)
    ...???
End Sub
 
I can't find a sample or some explanation in the "markupguide.chm".
 
I found only this:
 
Public Sub Hyperlink_Click(Reserved1 As Object, Reserved2 As Object)
    MsgBox "Clicked"
End Sub
Private Sub Form_Load()
    Label1.EnableMarkup = True
    Label1.MarkupContext.SetMethod Me, "Hyperlink_Click"
    Label1.Caption = "<TextBlock>Click <Hyperlink Click='Hyperlink_Click'>" & _
                  "this</Hyperlink> link</TextBlock>"
End Sub
 
 
But how does it work now?
 
THANK YOU FOR HELP!!!
 



Replies:
Posted By: Jebo
Date Posted: 05 September 2008 at 12:57pm
Hello,
 
please any help? ;-(


Posted By: tobi
Date Posted: 06 September 2008 at 6:15am
seems Oleg is on holidays 


Posted By: Oleg
Date Posted: 08 September 2008 at 4:10am
Hi,
Yes, I was :)
 
Jebo, there is new \Common\VB\MarkupSample  sample.
 
 
Public Sub HyperClick(ByVal Sender As MarkupObject, ByVal Args As MarkupRoutedEventArgs)
    MsgBox "Click"
End Sub
 
 
 


-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS


Posted By: Jebo
Date Posted: 08 September 2008 at 4:14am
Hi Oleg,
 
OK, but "HOW" do I interpret this both parameters (MarkupObject + MarkupRoutedEventArgs)?
 
Because I've many Links in my Label-Control and now I must detect which of my Links was clicked!!!
 
So I need something like This:
 
Msgbox "Clicked: " & sender.name & " / " & Args.Event.Name & " / " & Args.Source
 
But i seems, that ONLY "Args.Event.Name" will work and will tell me only "Ckick"!  ???
For all the other ones a error will occurs!!!
 


Posted By: Jebo
Date Posted: 08 September 2008 at 4:22am
...and do I also "need" the new MarkupLabel-control or is this control optional?
 
Because if I don't put the MarkupLabel-control to my project, there is now "MarkupObject" "MarkupRoutedEventArgs" objects in my project?


Posted By: Jebo
Date Posted: 09 September 2008 at 10:53am
Can Anybody give me a hint?
 
I feel me realy confused about the new Markup-Events!
 
PLEASE HELP!!!


Posted By: Oleg
Date Posted: 10 September 2008 at 1:19am
Hello,
 
Here sample: https://forum.codejock.com/uploads/20080910_011846_Markup.zip - Markup.zip


-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS


Posted By: Jebo
Date Posted: 10 September 2008 at 4:19am
Ahhh, I understand now, "Hyperlink Tag" is the right way!
 
BIG THX!!!


Posted By: Moonlite
Date Posted: 08 July 2009 at 12:50am
hi, Oleg. i'm trying to convert your sample to C# but always get error. do i miss something? thanks.



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net