Measurement Studio for .NET Languages

cancelar
Mostrando resultados para 
Pesquisar então 
Você quer dizer: 

DAQ Assistant Task Name Conflict

Hi,

My college has recently purchased a M-Series DAQ acquisition card and I am trying to use it with visual basic.net with Measurement Studio 7.1.

As I am new to DAQ and VB.net I am trying to use the DAQ assistant to capture my voltage signal. I have set-up the task and usercontrol and have placed into my program (all corectly, I think!). However when I run the program and activate the capture, I obtain a DAQException, which states that I have a "task name specified conflicts with an existing task name" in the code generated by Measurement studio in the following line:
0 Kudos
Mensagem 1 de 4
4.431Exibições
Sorry...typo..

The line is:

Public Class VoltageTestTask
Inherits Task

Public Sub New()
MyBase.New("VoltageTestTask") *****This is the line where the exception occurs.

Have I made a basic error, or is there a way to erradicate this error?

Yours

Jon Pegrum
0 Kudos
Mensagem 2 de 4
4.430Exibições
You might want to open up the Measurement And Automation Explorer (MAX) and check whether a task with this name already exists there. Look under My System >> Data Neighbourhood >> NI-DAQmx Tasks. Any tasks under here are global tasks. Creating multiple tasks with the same name is not allowed.

I hope this helps
Bilal Durrani
NI
0 Kudos
Mensagem 3 de 4
4.417Exibições
Another possibility is that you are not properly disposing the task after you use it. Call Task.Dispose when you are done with the task. This applies if you get the error the second time you use the task in your application.
0 Kudos
Mensagem 4 de 4
4.412Exibições