Static task Error -200428
I am using Labview 8.2 with an AI Input card 9215 on CDaq 9172. The application uses a static task to read the voltage(displacement).
The app works fine, except when the app is closed(using the x in the top RH corner), then restarted I get the error -200428 at DAQmx Start Task.Vi(Value passed to the task/Channel is invalid). The only fix is to restart the PC.
I have checked that the Stop Task VI is called when the app closes. I have tried resetting the Daq device using Max but it makes no difference.
I believe there is some problem in my code closing the task properly, hence the need to restart the PC to release task resources.
Any suggestions ?
Attachments:
simpleVi.JPG 18 KB
Enclosed a simple Vi that demonstrates the installed app. I have used a simulated CDaq device (identical to the customer cDaq)on my development PC and the simple VI works fine(both built as an exe and just running the VI on the development PC). The static task is identical to the task on the production app that is giving problems
<Item Name="VoltageIN" Type="NI-DAQmx Task">
<Property Name="\0\AI.Max" Type="Str">10</Property>
<Property Name="\0\AI.MeasType" Type="Str">Voltage</Property>
<Property Name="\0\AI.Min" Type="Str">-10</Property>
<Property Name="\0\AI.TermCfg" Type="Str">Differential</Property>
<Property Name="\0\AI.Voltage.Units" Type="Str">Volts</Property>
<Property Name="\0\ChanType" Type="Str">Analog Input</Property>
<Property Name="\0\Name" Type="Str">VoltageIN/Displacement</Property>
<Property Name="\0\PhysicalChanName" Type="Str">AnalogIN/ai0</Property>
<Property Name="\1\AI.Max" Type="Str">10</Property>
<Property Name="\1\AI.MeasType" Type="Str">Voltage</Property>
<Property Name="\1\AI.Min" Type="Str">-10</Property>
<Property Name="\1\AI.TermCfg" Type="Str">Differential</Property>
<Property Name="\1\AI.Voltage.Units" Type="Str">Volts</Property>
<Property Name="\1\ChanType" Type="Str">Analog Input</Property>
<Property Name="\1\Name" Type="Str">VoltageIN/Loadcell</Property>
<Property Name="\1\PhysicalChanName" Type="Str">AnalogIN/ai1</Property>
<Property Name="Channels" Type="Str">VoltageIN/Displacement, VoltageIN/Loadcell</Property>
<Property Name="Name" Type="Str">VoltageIN</Property>
<Property Name="SampClk.ActiveEdge" Type="Str">Rising</Property>
<Property Name="SampClk.Rate" Type="Str">20</Property>
<Property Name="SampClk.Src" Type="Str"></Property>
<Property Name="SampQuant.SampMode" Type="Str">Continuous Samples</Property>
<Property Name="SampQuant.SampPerChan" Type="Str">100</Property>
<Property Name="SampTimingType" Type="Str">Sample Clock</Property>
</Item>
However on the customer PC it throws the error -200428 even after a restart of the PC
Any ideas would be appreachiated
Attachments:
StopTaskOnPanelClose.vi 61 KB
Similar Messages
-
Why do I get error 200428 from executable?
I have a NI-DAQ application running correctly using a project under development LabVIEW 8.6 and NI-DAQ 8.8. When I use the exact same project to build the executable on the same PC, I get error 200428 - "Measurements: Value passed to Task/Channels In control is invalid" on startup. How could this be? I am using DAQ tasks built with the DAQ wizard and stored in the project.
Solved!
Go to Solution.I am well aware that the executable is not the project. LabVIEW executables, however, are always built within project context. The NI-DAQ tasks defined inside the project are part of that context. If I make the NI-DAQ VI a top-level VI and build the executable, everything works fine. It is something about embedding this VI in a larger application (executable only, not development) that is causing my problem.
-
DAQmx Error -200428 occurred at Write Dig Chan.vi
Hello,
I am trying to read the task name, channel name, and physical channel from a configuration file and using this information create a DAQmx task and two global virtual channels. Everything seems to be working ok (no error) until I am trying to write to one of the channels, then I get an "Error -200428 occurred at Write Dig Chan.vi". What am I doing wrong? Thanks for your help.
Peter
Attachments:
Write Dig Chan.vi 37 KBHello Corey,
I tried it out for both the Write Dig Chan.vi and the Write Dig Chan (modified).vi, but in both cases, I get the same errors as before.
Write Dig Chan.vi Error -200428
Write Dig Chan (modified).vi Error -200587
Attachments:
Write Dig Chan.vi 38 KB
Write Dig Chan (modified).vi 44 KB -
Error 200428 in linux example code
Hi All;
I'm trying to use the mx daq-base on a redhat 9.0 system. I have a 6031E installed(pci). I've installed the hardware, then the software and compiled the example code. When I try to run the writeDigPort example I get;
Device indentifier is invalid.
DAQmxBase Error: -200428
lsdaq reports:
NI 603E: "Dev2" (PXIO::16::0)
Nay ideas?
PatAfter further looking into the problem I'm getting an error -200220
here is the suspect code
char chan[] = "dev1/port0:1";
error1= DAQmxBaseCreateDOChan(taskHandle,chan,"",DAQmx_Val_ChanForAllLines);
DAQmxBaseGetExtendedErrorInfo (errBuff, 2048);
printf("\nDAQmxBaseCreateDOChan returned %d %s",error1,errBuff);
This gives the following output
DAQmxBaseCreateTask returned 0
DAQmxBaseCreateDOChan returned -200220 Device identifier is invalid.
Data to write: 0x55
DAQmxBaseGetExtendedErrorInfo returned -200428 Value passed to the Task/Channels In control is invalid.
Anyone have any idea?
Pat -
Hi,
I am trying to run a program that logs temperatures but I am having the following issue:
The program as a vi works it logs the temperatures and saves all the data like expected. Also if i run the executable on the same pc that created the exe it works. However when I make it into an excutable and try to run on another pc the program stops giving me error -200428 and states "Property Node DAQmx Timing (arg 1) in DAQmx Timing(Sample Clock).vi:1->16_ThermocoupleDAQ(Triggered).vi<append><B>Task Name:</B>LogData" How do I fix this error?
Please help this is quite urgent.
Thanks
Chris
Solved!
Go to Solution.What I'm saying is that when you create an installer in your project, one of the options is to export the MAX config and then include that and when run on a new pc, that config will be imported into MAX.
If you want, you can manually export a MAX configuration and manually import one. Just look under the File menu in MAX. You would need to install MAX.
You could also place all of the required configuration steps in your program instead of hiding some of it in MAX.
Message Edited by Dennis Knutson on 02-26-2009 12:06 PM -
Hello,
I am new to DAQmx, so please forgive me if this is a trivial question. I created several DAQmx tasks in LabVIEW, then wrote my vi automatically generating the configuration code by right-clicking a DAQmx Task constant and selecting generate code. When I run the Standalone Solenoid Controller.vi in the Standalone Modules folder, I get a Error -200428 during the first call of DAQmx Write.vi.
What is going on? Please advise. Thank you.
Best regards,
Peter
Attachments:
Solenoid Controller.zip 657 KBThe problem with having a single task is that you have designated those channels to be used for that task. Once that has been done, you shouldn't be able to put those channels into another task or use them on their own.
When wiring the channel into the DAQmx Write, a task is created. That task is what is passed out. So by having that channel already designated for a task, you can't put it into another one. You need to either write to everything with a single task or separate them into multiple tasks.
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines -
USU 6009 counter error: DAQmxBase Error -200428
I want to use USB 6009 as an edge counter. I got this ouput :
create task
createCounterChan
start task
DAQmxBase Error -200428: Value passed to the Task/Channels In control is invalid.
with following code:
// Channel parameters
const char counter[] = "Dev3/ctr0";
// Read parameters
uInt32 readArray[1];
uInt32 arraySizeInSamps=1;
uInt32 initialCount=0;
int32 numSampsPerChan=1;
int32 sampsPerChanRead;
float64 timeout=100;
DAQmxErrChk (DAQmxBaseCreateTask ("", &taskHandle));
printf("create task\n");
DAQmxErrChk (DAQmxBaseCreateCICountEdgesChan (taskHandle, counter, NULL, DAQmx_Val_Falling, initialCount, DAQmx_Val_CountUp));
printf("createCounterChan\n");
// Start Task (configure port)
DAQmxErrChk (DAQmxBaseStartTask (taskHandle));
printf("start task\n");
DAQmxErrChk (DAQmxBaseReadCounterU32 (taskHandle, numSampsPerChan, timeout, readArray, arraySizeInSamps, &sampsPerChanRead, NULL));
printf("Data read: 0x%X\n",readArray[0]);
Please helpHello nguyendyhung,
Thank you for posting to the discussion forum. Here is a KnowledgeBase that explains this error.
NI-DAQmx Base Error -200428
http://digital.ni.com/public.nsf/websearch/7705D38D59EF562886256F79007E4B5A?OpenDocument
This document is going to reference LabVIEW, but the theory is still going to be applicable with your code. You can get this error message if the task is not configured correctly.
Also take a look at some of the shipping examples that come with DAQmx Base. You can find them in the following folder:
C:\Program Files\National Instruments\NI-DAQmx Base\Examples
Please take a look at these resources and let us know it resolves your issue.
Regards,
Sandra T.
Applications Engineer | National Instruments -
Is there a way to generate a report of task errors? I have a "Load from Resource" task that generated errors but I don't want to go through each of the 7000+ pages to find the ~230 errors.
I have tried to create a new Task Report but it won't Save or Run.You might want to find the task and add a custom audit event on the task. If it's a default task you might be able to find it using audit log report.
-
File system task error ; Access to the path " " is denied
HI All,
I have created a simple package to copy xml files from multiple source folders to destination folder.
Folder names and paths are stored in a sql table. I use execute sql taks to get folder and path names. set the restult set to full result set in the execute sql task.
Then for each loop is used to loop through each file name. File system taks is inside the for each loop. Destination vairable and source varable were created and assigned them inthe file system task.
But I am getting an error message.
[File System Task] Error: An error occurred with the following error message: "Access to the path '\\cor\Groups\DN\Share2\Servicing \RESPONSE_FILES\Services' is denied.".
But I am able to do this if i design the package to move just one file. i.e without using variables. I get the error message only when I use variables.
Can anyone tell me how to fix this please?
Thanks
shamenHow to give the access please.
Ramu Gade
Login using a sysadmin account
Go to the folder right click security and you've the option to add new account. You should give account write access if you want to copy files to folder.
see
http://technet.microsoft.com/en-in/library/bb456988.aspx
Please Mark This As Answer if it solved your issue
Please Vote This As Helpful if it helps to solve your issue
Visakh
My MSDN Page
My Personal Blog
My Facebook Page -
Failed to load Execute Package Task error.
Hello Experts,
Excuse my newbie question.
Execute Package Task: Error: The task has failed to load. The contact information for the task is "Microsoft Corporation; Microsoft SQL Server; Microsoft corporation; All Rights Reserved http://www.microsoft.com/sql/support/default.asp:1"
We have a windows service running on our app server that deploys a package that executes other packages using execute package task. This package and rest of the packages are in the same folder at the same level under integration services
catalog. The package fails to execute with the above said error.
Execute package task is configured to run in 'in-process' mode. Changing delay validation to true/false in child packages didn't help.
ironically if the package is deployed using a console application from the app server the package gets executed just fine. I checked permissions, everything seem fine.
Is there anyway to get details of this error to understand the problem better? I am looking at reports > standard reports > all executions.
Thanks.As it turns out, the 63bit ExecPackageTask.dll was not found under "C:\Program Files\Microsoft SQL Server\110\DTS\Binn". Installing "SQL Server Data Tools" installed only 32 bit version of the component under "C:\Program Files (x86)\Microsoft SQL
Server\110\DTS\Binn".
Is there a way to get 64bit version of this component without installing "Integration Services" (to avoid possible license issues)?
Hi Jayakarthiks,
To make use of the 64-bit ExecPackageTask.dll, you also need the 64-bit SSIS runtime and 64-bit DTExec utility tool. To obtain the 64-bit SSIS runtime and tools, you have to install the SQL Server Integration Services service from your SQL Server 2012 install
media.
Reference:
http://msdn.microsoft.com/en-us/library/ms143731.aspx
Regards,
Mike Yin
If you have any feedback on our support, please click here
Mike Yin
TechNet Community Support -
Hi all,
I am having a list of files in a folder named datafiles and I am processing them one by one when I finish each one I want to move the file into a folder archive.
I am having a variable named filename and archivefilename and two fileconnections one is originalfiles and archivefiles
archivefilename=replace( @[User::filename],"datafiles","archive")
orginalfiles connection is an expression =@user:filename
archivefies connection is an expression=@user:archivefilename
the filename comes from reading the folder that contains those files
public void Main()
string[] filenames;
filenames = Directory.GetFiles(@"C:\luminis\datafiles\");
Array.Sort(filenames);
Dts.Variables["filelist"].Value = filenames;
Dts.TaskResult = (int)ScriptResults.Success;
The folder c:\luminis\archive\ exists
why I am getting this error
My filesystem task : destinationpathvariable =false
destinationconnection:archivefile
overwrite=true
operation=movefile
issourcepathvariable=false
sourceconnection=original file
why am i getting this error[File System Task] Error: An error occurred with the following error message: "Could not find a part of the path.".
sohairzakithere may be 2 problem...
1> specify a target directory only, not with the file name.
OR
2> Try using the unc,path format \\computername\sharename\
let us know your observation...
Let us TRY this | Mail me
My Blog :: http://quest4gen.blogspot.com/ -
Hi, After successfully testing connection to my source web service, while executing my web service task, I face the following error. Can anyone help me????
[Web Service Task] Error: An error occurred with the following error message: "Microsoft.SqlServer.Dts.Tasks.WebServiceTask.WebserviceTaskException: Could not load the proxy for the specified Web service. The error is: Could not load file or assembly
'iiglotg3.dll' or one of its dependencies. Access is denied..
at Microsoft.SqlServer.Dts.Tasks.WebServiceTask.WebMethodInvokerProxy.loadProxyInAppDomain()
at Microsoft.SqlServer.Dts.Tasks.WebServiceTask.WebMethodInvokerProxy.InvokeMethod(DTSWebMethodInfo methodInfo, String serviceName, Object connection)
at Microsoft.SqlServer.Dts.Tasks.WebServiceTask.WebServiceTaskUtil.Invoke(DTSWebMethodInfo methodInfo, String serviceName, Object connection, VariableDispenser taskVariableDispenser)
at Microsoft.SqlServer.Dts.Tasks.WebServiceTask.WebServiceTask.executeThread()".
Regards,
Njdeh TahmasianCould not load file or assembly 'iiglotg3.dll' or one of its dependencies.
Access is denied..
Looks like a permission issue or maybe the assembly don't exists on the server where the package is running; you should check that first.
Olaf Helper
[ Blog] [ Xing] [ MVP] -
I have an package with source , data flow and destination to execute on begin and commit.
in the below i have just used for questioning purpose with diagram removing my Data Flow task explaining my problem
on execution, i get error as
[Execute SQL Task] Error: Executing the query "COMMIT TRAN DimCompanyCode" failed with the following error: "The COMMIT TRANSACTION request has no corresponding BEGIN TRANSACTION.". Possible failure reasons: Problems with the query, "ResultSet"
property not set correctly, parameters not set correctly, or connection not established correctly.
as mentioned , i have checked the ResultSet, parameters , connection establish.. all are fine.
Kindly advice on what has to be done.
ShanmugaRajTo avoid this error, the RetainSameConnection property should set to 'True' for the Connection Manager - Application_DB.
Narsimha -
I am using the following query in Execute SQL Task
SELECT CASE(SELECT COUNT(*) FROM STG_APJ_APIW_DETAILS
WHERE source_filename = ?
AND lTRIM(RTRIM([BILLING DATE])) <> '') WHEN 0 THEN (SELECT CONVERT(VARCHAR(8), GETDATE(), 112) AS [YYYYMMDD])
ELSE
(SELECT TOP 1 [BILLING DATE] FROM STG_APJ_APIW_DETAILS
WHERE source_filename = ?
AND lTRIM(RTRIM([BILLING DATE])) <> '')
END
In parameter Mapping i have created two parameters and in result set i choose my variable.
Result set property is Single Row.
Following is the error message i received,
[Execute SQL Task] Error: Executing the query "SELECT CASE(SELECT COUNT(*) FROM STG_APJ_APIW_DETA..." failed with the following error: "Syntax error, permission violation, or other nonspecific error". Possible failure reasons: Problems
with the query, "ResultSet" property not set correctly, parameters not set correctly, or connection not established correctly.
SarvanI cant see where you've named resultset. try like below to make sure resultset has the name used in resultset tab
SELECT CASE(SELECT COUNT(*) FROM STG_APJ_APIW_DETAILS
WHERE source_filename = ?
AND lTRIM(RTRIM([BILLING DATE])) <> '') WHEN 0 THEN (SELECT CONVERT(VARCHAR(8), GETDATE(), 112))
ELSE
(SELECT TOP 1 [BILLING DATE] FROM STG_APJ_APIW_DETAILS
WHERE source_filename = ?
AND lTRIM(RTRIM([BILLING DATE])) <> '')
END AS [Billing Date]
Please Mark This As Answer if it helps to solve the issue Visakh ---------------------------- http://visakhm.blogspot.com/ https://www.facebook.com/VmBlogs -
SSIS - Using Variables in Execute SQL Task Error
The following query in my Execute SQL Task throws the following error when run - [Execute SQL Task] Error: Executing the query "SELECT @columnz = COALESCE(@columnz + ',[' + times..." failed with the following error:
"Must declare the scalar variable "@columnz".". Possible failure reasons: Problems with the query,
"ResultSet" property not set correctly, parameters not set correctly, or connection not established correctly.
Query:
drop table tmpNCPCNCDownstreamMaxUtilization3wks
select node, max(utilization) as max_Utilization, DATE
into tmpNCPCNCDownstreamMaxUtilization3wks
from stage_ncpcncdownstream_temporal
WHERE Date BETWEEN DATEADD(day, -20, GETDATE()) AND GETDATE()
group by node, date
order by node
go
alter table tmpNCPCNCDownstreamMaxUtilization3wks add Timestamp varchar(50)
go
update tmpNCPCNCDownstreamMaxUtilization3wks
set Timestamp = 'WeekOf_' + cast(left(Date, 11) as varchar)
go
--drop table tmpNCPCNC_DownstreamNodeUtilizationMaxPivot
--go
declare @columnz varchar (8000)
go
SELECT @columnz = COALESCE(@columnz + ',[' + timestamp + ']','[' + timestamp+ ']')
FROM tmpNCPCNCDownstreamMaxUtilization3wks group by timestamp order by timestamp
go
--pivot contents in @columns
declare @query varchar(8000)
SET @query ='select * into tmpNCPCNC_DownstreamNodeUtilizationMaxPivot from
(select node, timestamp, Max_Utilization from tmpNCPCNCDownstreamMaxUtilization3wks)a
pivot
sum(max_Utilization) for timestamp in('+ @columnz +')
)as p'
execute (@query)
--empty contents from NCPCNCDownstreamMaxUtilization3wks
update tmpNCPCNCDownstreamMaxUtilization3wks
set timestamp =''
truncate table tmpNCPCNC_MaxDownstreamNodeUtilzationChart3Week
--load to table to be joined to Node feature class
insert into tmpNCPCNC_MaxDownstreamNodeUtilzationChart3Week
(Node, TwoWeeksAgo, PreviousWeek, CurrentWeek)
select * from tmpNCPCNC_DownstreamNodeUtilizationMaxPivot
--calculate average utilization for all values in each record
update tmpNCPCNC_MaxDownstreamNodeUtilzationChart3Week
set average = (coalesce(twoweeksago, 0) + coalesce(previousweek, 0) + coalesce(currentweek, 0))/3
from tmpNCPCNC_MaxDownstreamNodeUtilzationChart3Week
ScottIssue is with variable @columnz.
Scope of variables is only limited to the batch and if batch is over Variable is no more accessible.
Reproduce Steps:
DECLARE @columnz int = 0
Go --Scope of @columnz ends here
SELECT @columnz -- Ends up with error
So you have to remove GO keyword. I have commented 2 of them in below:
DROP TABLE tmpNCPCNCDownstreamMaxUtilization3wks
SELECT node
,max(utilization) AS max_Utilization
,DATE
INTO tmpNCPCNCDownstreamMaxUtilization3wks
FROM stage_ncpcncdownstream_temporal
WHERE DATE BETWEEN DATEADD(day, - 20, GETDATE())
AND GETDATE()
GROUP BY node
,DATE
ORDER BY node
GO
ALTER TABLE tmpNCPCNCDownstreamMaxUtilization3wks ADD TIMESTAMP VARCHAR(50)
GO
UPDATE tmpNCPCNCDownstreamMaxUtilization3wks
SET TIMESTAMP = 'WeekOf_' + cast(left(DATE, 11) AS VARCHAR)
GO
--drop table tmpNCPCNC_DownstreamNodeUtilizationMaxPivot
--go
DECLARE @columnz VARCHAR(8000)
--GO
SELECT @columnz = COALESCE(@columnz + ',[' + TIMESTAMP + ']', '[' + TIMESTAMP + ']')
FROM tmpNCPCNCDownstreamMaxUtilization3wks
GROUP BY TIMESTAMP
ORDER BY TIMESTAMP
--GO
--pivot contents in @columns
DECLARE @query VARCHAR(8000)
SET @query = 'select * into tmpNCPCNC_DownstreamNodeUtilizationMaxPivot from
(select node, timestamp, Max_Utilization from tmpNCPCNCDownstreamMaxUtilization3wks)a
pivot
sum(max_Utilization) for timestamp in(' + @columnz + ')
)as p'
EXECUTE (@query)
--empty contents from NCPCNCDownstreamMaxUtilization3wks
UPDATE tmpNCPCNCDownstreamMaxUtilization3wks
SET TIMESTAMP = ''
TRUNCATE TABLE tmpNCPCNC_MaxDownstreamNodeUtilzationChart3Week
--load to table to be joined to Node feature class
INSERT INTO tmpNCPCNC_MaxDownstreamNodeUtilzationChart3Week (
Node
,TwoWeeksAgo
,PreviousWeek
,CurrentWeek
SELECT *
FROM tmpNCPCNC_DownstreamNodeUtilizationMaxPivot
--calculate average utilization for all values in each record
UPDATE tmpNCPCNC_MaxDownstreamNodeUtilzationChart3Week
SET average = (coalesce(twoweeksago, 0) + coalesce(previousweek, 0) + coalesce(currentweek, 0)) / 3
FROM tmpNCPCNC_MaxDownstreamNodeUtilzationChart3Week
-Vaibhav Chaudhari
Maybe you are looking for
-
Godaddy IMAP email no longer downloads with iOS 8.1
no problem sending, however, no new email will download. I rebooted, deleted account, added it (which it adds fine), it just no longer downloads email.
-
FI 606 No Commitment Item Selected during MB01
Dear All, I have a problem during GR/IR process in MB01. When logistic section want to post the GR process based on the PO reference, there is an error: No commitment items selected, message FI606. I already created the commitment item with financial
-
How can i get a photo book delivered to Belgium ? It only seems to work in Australia.
I did create a photo book with iPhoto. When i pressed "buy book", then the only allowed shipping addresses was in Australia. I would like to receive the book in Belgium. What should I do?
-
No messages seen in e.mail inbox I pad2?
No messages or photos seen in the e.mail inbox of my I pad2. Only header and title.
-
Hi Experts, I am getting following error in Reciever JMS adapter: I am using transport protocol is Acces JMS provider with JNDI Channel error occurred; detailed error description: com.sap.aii.adapter.jms.api.connector.ConnectorException: Error creati