Products | Support | Email a link to this topic. | Send comments on this topic. | Back to Introduction - All Topics | Help Version 19.0.3.25
|
Leadtools.Dicom Namespace > DicomDataSet Class : InitializeCommandSet Method |
public void InitializeCommandSet( DicomCommandType commandType, bool request )
'Declaration
Public Sub InitializeCommandSet( _ ByVal commandType As DicomCommandType, _ ByVal request As Boolean _ )
'Usage
Dim instance As DicomDataSet Dim commandType As DicomCommandType Dim request As Boolean instance.InitializeCommandSet(commandType, request)
public void InitializeCommandSet( DicomCommandType commandType, bool request )
function Leadtools.Dicom.DicomDataSet.InitializeCommandSet( commandType , request )
public: void InitializeCommandSet( DicomCommandType commandType, bool request )
This example will initialize a new DICOM command set and copy it to another command set.
Imports Leadtools Imports Leadtools.Dicom <TestMethod()> _ Public Sub TestCommandSet() 'Make sure to initialize the DICOM engine, this needs to be done only once 'In the whole application DicomEngine.Startup() Dim ds As DicomDataSet = New DicomDataSet() Using (ds) ds.InitializeCommandSet(DicomCommandType.CFind, True) Debug.Assert(ds.InformationCommand = DicomCommandType.CFind) Debug.Assert(ds.IsRequestCommand = True) Dim ds1 As DicomDataSet = New DicomDataSet() Using (ds1) ds1.Copy(ds, Nothing, Nothing) End Using End Using DicomEngine.Shutdown() End Sub
using Leadtools; using Leadtools.Dicom; [TestMethod] public void TestCommandSet() { //Make sure to initialize the DICOM engine, this needs to be done only once //In the whole application DicomEngine.Startup(); using (DicomDataSet ds = new DicomDataSet()) { ds.InitializeCommandSet(DicomCommandType.CFind, true); Debug.Assert(ds.InformationCommand == DicomCommandType.CFind); Debug.Assert(ds.IsRequestCommand == true); using (DicomDataSet ds1 = new DicomDataSet()) { ds1.Copy(ds, null, null); } } DicomEngine.Shutdown(); }
using Leadtools.Dicom.Constants; using Leadtools; using Leadtools.Dicom; [TestMethod] public void TestCommandSet() { //Make sure to initialize the DICOM engine, this needs to be done only once //In the whole application DicomEngine.Startup(); using (DicomDataSet ds = new DicomDataSet()) { ds.InitializeCommandSet(DicomCommandType.CFind, true); Debug.Assert(ds.InformationCommand == DicomCommandType.CFind); Debug.Assert(ds.IsRequestCommand == true); using (DicomDataSet ds1 = new DicomDataSet()) { ds1.Copy(ds, null, null); } } DicomEngine.Shutdown(); }