Community
Showing results for 
Search instead for 
Do you mean 
Reply

Creating a plugin: Logon to Framework

Tuned Listener
Posts: 11
Country: United States

Creating a plugin: Logon to Framework

Hi All,

 

1. When creating a plugin, is it necessary to logon to the framework in order to create contacts / companies via SDK in the current database?

2. If it is, can I just use the current user and his / her credentials WITHOUT hardcoding them in the plugin code? In other words, when the user clicks the menu item, just use the username and password of the said user as they are currently logged in.

 

Thanks,

Scott

 

 

Bronze Elite Contributor
Posts: 2,115
Country: United_Kingdom

Re: Creating a plugin: Logon to Framework

Hi Scott,

 

The ActApplication holds an ActFramework object from the Current logged on user:

 

//Act.ActApplication actApp

 

Act.Framework.ActFramework oFram = actApp.ActFramework;

oFram.Contacts.CreateContact(); //then you can go ahead and set the field details

 

//---or even---

Act.Framework.Contacts.Contact oContact = actApp.ActFramework.COntacts.CreateContact();

 

Sorry its in C# but hopefully you get the idea.

HTH

Vivek

Vivek Gargav
Caldere Associates Ltd.
www.caldere.com
vgargav@caldere.com
My Blog
Tuned Listener
Posts: 11
Country: United States

Re: Creating a plugin: Logon to Framework

Thanks, that's what I needed!

 

Scott