MeldrethMan
Technical User
Is it possible to format a hyperlink field and change its behaviour when clicked?
I'm displaying a list of links in a subform in datasheet view and it looks messy with the underlining and colour changes.
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Public Function DisplayHyperFieldText(strHyper As Variant) As String
If Not IsNull(strHyper) Then
DisplayHyperFieldText = Split(strHyper, "#")(0)
End If
End Function
Private Sub Form_Load()
Me.txtBxHyperfield.ColumnHidden = True
End Sub
Private Sub TxtBxDisplayHyperText_Click()
FollowHyperlink (Me.txtBxHyperfield.Hyperlink.Address)
End Sub
There is a property "Display as Hyperlink", but this only allows you to display a text field as a hyperlink: "always, only if hyperlink, on screen". There is no choice to not display as hyperlink. I could not find a way to make a hyperlink not display as a hyperlink in datasheet view. There may be an easier way, but this work-around was the only thing I could come up with.couldn't find any properties for a hyperlink field and searches suggested there weren't any options.