SilverShaded
Well-known member
- Joined
- Mar 7, 2020
- Messages
- 110
- Programming Experience
- 10+
Im struggling to make sense of this, I managed to locate what I think are the correct 64bit DLLs and reference them so the 'using' statement is now ok.
However the VSTA.session statement doesnt exist. The code is copied from an old example (VS2015) i was assuming it shouldn't have changed much and can't find an equivalent example for VS 2022. What am I doing wrong?
However the VSTA.session statement doesnt exist. The code is copied from an old example (VS2015) i was assuming it shouldn't have changed much and can't find an equivalent example for VS 2022. What am I doing wrong?
C#:
using VSTA = Microsoft.VisualStudio.Tools.Applications;
namespace WinFormsApp8
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private VSTA.Session _session;
private void button1_Click(object sender, EventArgs e)
{
if (_session == null)
{
var sessionMgr = VSTA.SessionManager.Create("MyHostApp");
_session = sessionMgr.CreateSession();
}
_session.Ide.Show();
}
}
}
Last edited: