メインコンテンツへスキップ

Excelで複数のメールアドレスをハイパーリンクに変換するにはどうすればよいですか? 

ワークシートにプレーンテキストの電子メールアドレスのリストがあり、これらの電子メールアドレスを、アドレスをクリックしながら電子メールを送信できるハイパーリンクに変換したい場合。 もちろん、それらをハイパーリンクされた電子メールアドレスに変換することはできますが、変換する必要のあるアドレスが複数ある場合、この方法は退屈になります。 この記事では、このタスクに対処するためのいくつかの良いトリックについて説明します。

Formulaを使用して複数の電子メールアドレスをハイパーリンクに変換する

複数のメールアドレスをVBAコードでハイパーリンクに変換する


矢印青い右バブル Formulaを使用して複数の電子メールアドレスをハイパーリンクに変換する

ハイパーリンク 機能を使用すると、列の電子メールアドレスをハイパーリンクされたアドレスに一度にすばやく変換できます。

1。 この式を入力してください = hyperlink( "mailto:"&A2) 結果を配置する空白のセルに、スクリーンショットを参照してください。

docはアドレスをハイパーリンクに変換します1

2。 次に、塗りつぶしハンドルをこの数式を含めるセルまでドラッグすると、次のスクリーンショットに示すように、すべての電子メールアドレスがクリック可能なハイパーリンクになります。

docはアドレスをハイパーリンクに変換します2


矢印青い右バブル 複数のメールアドレスをVBAコードでハイパーリンクに変換する

ご覧のとおり、上記の式を使用すると、各メールアドレスの前に文字列「mailto:」が追加されます。アドレス内でmailto:を使用したくない場合は、次のVBAコードを使用するとよいでしょう。

1。 を押し続けます Altキー+ F11 Excelでキーを押すと、 アプリケーション向け Microsoft Visual Basic 窓。

2に設定します。 OK をクリックします。 インセット > モジュール、次のマクロをに貼り付けます モジュール 窓。

VBAコード:複数のメールアドレスをハイパーリンクに変換する

Sub EmailHylink()
'updateby Extendoffice
    Dim xRg As Range
    Dim xCell As Range
    Dim xAddress As String
    Dim xUpdate As Boolean
    On Error Resume Next
    xAddress = Application.ActiveWindow.RangeSelection.Address
    Set xRg = Application.InputBox("Please select the data range", "Kutools for Excel", xAddress, , , , , 8)
    If xRg Is Nothing Then Exit Sub
    xUpdate = Application.ScreenUpdating
    Application.ScreenUpdating = False
    For Each xCell In xRg
        xCell.Hyperlinks.Add Anchor:=xCell, Address:="mailto:" & xCell.Value
    Next
    Application.ScreenUpdating = xUpdate
End Sub

3。 コードを貼り付けたら、を押してください F5 このコードを入力すると、使用するデータ範囲を選択するように促すプロンプトボックスが表示されます。スクリーンショットを参照してください。

docはアドレスをハイパーリンクに変換します3

4。 そして、 OK、選択したすべての電子メールアドレスがハイパーリンクされたアドレスに変換されました。スクリーンショットを参照してください。

docはアドレスをハイパーリンクに変換します4

最高のオフィス生産性向上ツール

🤖 Kutools AI アシスタント: 以下に基づいてデータ分析に革命をもたらします。 インテリジェントな実行   |  コードを生成  |  カスタム数式の作成  |  データを分析してグラフを生成する  |  Kutools関数を呼び出す...
人気の機能: 重複を検索、強調表示、または識別する   |  空白行を削除する   |  データを失わずに列またはセルを結合する   |   数式なしのラウンド ...
スーパールックアップ: 複数の基準の VLookup    複数の値の VLookup  |   複数のシートにわたる VLookup   |   ファジールックアップ ....
詳細ドロップダウン リスト: ドロップダウンリストを素早く作成する   |  依存関係のドロップダウン リスト   |  複数選択のドロップダウンリスト ....
列マネージャー: 特定の数の列を追加する  |  列の移動  |  Toggle 非表示列の表示ステータス  |  範囲と列の比較 ...
注目の機能: グリッドフォーカス   |  デザインビュー   |   ビッグフォーミュラバー    ワークブックとシートマネージャー   |  リソースライブラリ (自動テキスト)   |  日付ピッカー   |  ワークシートを組み合わせる   |  セルの暗号化/復号化    リストごとにメールを送信する   |  スーパーフィルター   |   特殊フィルター (太字/斜体/取り消し線をフィルター...) ...
上位 15 のツールセット12 テキスト ツール (テキストを追加, 文字を削除する、...)   |   50+ チャート 種類 (ガントチャート、...)   |   40+ 実用的 (誕生日に基づいて年齢を計算する、...)   |   19 挿入 ツール (QRコードを挿入, パスから画像を挿入、...)   |   12 変換 ツール (数字から言葉へ, 通貨の換算、...)   |   7 マージ&スプリット ツール (高度な結合行, 分割セル、...)   |   ... もっと

Kutools for Excel で Excel スキルを強化し、これまでにない効率を体験してください。 Kutools for Excelは、生産性を向上させ、時間を節約するための300以上の高度な機能を提供します。  最も必要な機能を入手するにはここをクリックしてください...

説明


Officeタブは、タブ付きのインターフェイスをOfficeにもたらし、作​​業をはるかに簡単にします

  • Word、Excel、PowerPointでタブ付きの編集と読み取りを有効にする、パブリッシャー、アクセス、Visioおよびプロジェクト。
  • 新しいウィンドウではなく、同じウィンドウの新しいタブで複数のドキュメントを開いて作成します。
  • 生産性を 50% 向上させ、毎日何百回もマウス クリックを減らすことができます!
Comments (7)
No ratings yet. Be the first to rate!
This comment was minimized by the moderator on the site
Ich suche eine Formel mit der ich EMail-Adressen in URLs umwandeln kann...

Beispiel: > http://www.test.de

Kann mir jemand helfen?
This comment was minimized by the moderator on the site
Hello, kk.operator

To solve your problem, please apply the following code:

Sub EmailHylink()
'updateby Extendoffice
    Dim xRg As Range
    Dim yRg As Range
    Dim xCell As Range
    Dim xCell2 As Range
    Dim xAddress As String
    Dim xUpdate As Boolean
    Dim xRegEx As Object
    Dim arrSplit() As String
    
    On Error Resume Next
    xAddress = Application.ActiveWindow.RangeSelection.Address
    Set xRg = Application.InputBox("Please select the data range", "Kutools for Excel", xAddress, , , , , 8)
    Set yRg = Application.InputBox("Please select the save range", "Kutools for Excel", xAddress, , , , , 8)
    If xRg Is Nothing Then Exit Sub
    If yRg Is Nothing Then Exit Sub
    Set yRg = yRg.Range("A1").Resize(xRg.Rows.Count, xRg.Columns.Count)

    xUpdate = Application.ScreenUpdating
    Application.ScreenUpdating = False
    
    Set xRegEx = CreateObject("VBSCRIPT.REGEXP")
    With xRegEx
        .Pattern = "^\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*$"
        .Global = True
        .IgnoreCase = True
    End With
    
    For I = 1 To xRg.Rows.Count
        For J = 1 To xRg.Columns.Count
            Set xCell = xRg.Cells(I, J)
            Set xCell2 = yRg.Cells(I, J)
            If xRegEx.test(xCell.Value) Then
                arrSplit = Split(xCell.Value, "@")
                 If UBound(arrSplit, 1) = 1 Then
                    xCell2.Value = "http://www." & arrSplit(1)
                    xCell2.Hyperlinks.Add Anchor:=xCell2, Address:=xCell2.Value
                 End If
            End If
        Next
    Next
    Application.ScreenUpdating = xUpdate
End Sub


Please have a try, hope it can help you!
This comment was minimized by the moderator on the site
Works perfectly in Excel 2003! Thanks much!
This comment was minimized by the moderator on the site
I'm in a MAC environment so don't have a ALT key. Any other ieas?
This comment was minimized by the moderator on the site
The equivalent for the ALT key is the command key (located to the left of the Option Key).

Both of these keys are located to the left of the spacebar.
This comment was minimized by the moderator on the site
you are a star, it worked perfectly. thanks a million
This comment was minimized by the moderator on the site
I cannot find the find converting cells to hyperlinks.
There are no comments posted here yet
Please leave your comments in English
Posting as Guest
×
Rate this post:
0   Characters
Suggested Locations