<?xml version="1.0" encoding="utf-16" standalone="yes"?>
<!--Created: 30.06.2015 15:49:40-->
<!--ACTOptimumVersion: 6.0.5581.26549-->
<AutoDataItems ACTOptimumVersion="6.0.5581.26549" Created="30.06.2015 15:49:40">
    <AutoDataControl Created="30.06.2015 15:49:40" ClassName="Melville_Schellmann.ACTOptimum3.Control.AutoData3.AutoData3" PrefClassVersion="1.0" ACTOptimumVersion="6.0.5581.26549">
        <Source>' #ScriptName: LookupContact
    ' #Description: DEUTSCH:
    '               Lädt einen Kontakt aus der Zwischenablage, welcher zuvor über das
    '               AutoData-Script "SaveContact" zwischengespeichert wurde.
    '               
    '               ENGLISH:
    '               Loads a contact from the clipboard which was previously cached on
    '               the Autodata script "SaveContact".
    ' #Author: Robert Schellmann
    ' #Copyright: Melville-Schellmann
    Dim PrefPath As String = "Melville-Schellmann/ACTOptimum4/SavedContactID" ' Name des Einstellungswertes
    Dim Title As String = "AutoData"
    Dim Value As String
    Dim ContactID As System.Guid
    Dim ConfigValue As Act.Shared.Config.Value = Nothing
    Dim oContact As Act.Framework.Contacts.Contact
    Dim CurrentUserID As System.Guid

    CurrentUserID = ActApp.ActFramework.CurrentUser.ID

    Try
      ConfigValue = ActApp.ActFramework.Preferences.UserPreferencesDB.GetUserPreference(PrefPath, CurrentUserID)
    Catch ex As Exception
      MsgBox(String.Format("Es ist ein Fehler beim Laden des Einstellungswertes '{0}' aufgetreten.", PrefPath) &amp; vbCrLf &amp; _
        ex.Message, MsgBoxStyle.Exclamation, Title)
    End Try
    If ConfigValue Is Nothing Then
      Exit Function
    Else
      Value = ConfigValue.GetStringValue
    End If

    ContactID = New System.Guid(Value)

    oContact = ActApp.ActFramework.Contacts.GetContactsByID(Nothing, New System.Guid() {ContactID})(0)

    If oContact Is Nothing Then Exit Function

    If MsgBox(String.Format("Zu Kontakt '{0}' wechseln?", oContact.FullName), MsgBoxStyle.Question + MsgBoxStyle.YesNo, Title) = MsgBoxResult.No Then Exit Function

        ActApp.UIContactManager.ShowContact(oContact)</Source>
        <SourceComment>Begriff: {0}</SourceComment>
        <TargetFields></TargetFields>
        <MsgText>{0}</MsgText>
        <Picklist></Picklist>
        <Multiple>False</Multiple>
        <Expandable>True</Expandable>
        <OverwriteAlways>True</OverwriteAlways>
        <CopyToClipboard>False</CopyToClipboard>
        <ShowMsgBox>False</ShowMsgBox>
        <PositionMode>1</PositionMode>
        <FlatStyle>Standard</FlatStyle>
        <AutoDataText>Kontakt laden</AutoDataText>
        <TextAlign>MiddleCenter</TextAlign>
        <AutoDataFormSize>160; 270</AutoDataFormSize>
        <TooltipText></TooltipText>
        <RefreshLoadedViews>False</RefreshLoadedViews>
    </AutoDataControl>
</AutoDataItems>