Hallo nochmal,
zwar funktioniert das jetzt, wenn man Antwortet oder eine Mail neu erstellt, das ein bestimmte Name aus der Benutzerliste im "Von"-Feld vor eingetragen steht, allerdings soll das nicht bei allen CRM-Usern so sein.
Also wenn sich User X angemeldet hat und eine Mail beantworten möchte soll der Code nicht angewandt werden.
Aber ich hab keine Ahnung wie ich im Code schreiben soll, das er die GUID überprüfen soll und dann entscheidet.
Wer weiß da einen Rat oder die richtige Codeanweisung für GUID Überprüfung?
Das hier klappt so nicht.if (UserID != '16769C93-F5DF-DA11-8E80-0003FFD90CC3')
das ist der Code der im Moment funktioniert: if(crmForm.FormType == 1)
{
//Create an array to set as the DataValue for the lookup control.
var lookupData = new Array();
//Create an Object add to the array.
var lookupItem= new Object();
//Set the id, typename, and name properties to the object.
lookupItem.id = '{000DIE00-00US-ER00-0ID0-000HIER0000}';
lookupItem.typename = 'systemuser';
lookupItem.name = 'Vor eingetragener User';
// Add the object to the array.
lookupData[0] = lookupItem;
// Set the value of the lookup field to the value of the array.
crmForm.all.from.DataValue = lookupData;
alert('der Absender wurde automatisch auf "
[email protected]" gesetzt')
}