LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

.NET date picker object is not working on executable (URGENT)

I've created a program to save a new staff particulars. The problem I have is when I'm entering the hired date (which is the system date) for the staff, it shows up as "1/1/1904" when running it as an executable. It works normally when running as a normal vi. Can anyone help me please? It's urgent as this is my last day of intern at my company doing this.

0 Kudos
Message 1 of 7
(3,634 Views)

It would be easier to help, if you shared all necessery files. Zip the whole project, and attach it. I cannot even run your VI since it is broken due to missing typdefs...

0 Kudos
Message 2 of 7
(3,581 Views)

My bad. Here's all of the necessary files

0 Kudos
Message 3 of 7
(3,575 Views)

I wonder how do you create the EXE? You do not have any project in the zip...

Why do you need to use .NET DateTimePicker? You could just use a simple Timestamp control...

 

edit: and put your Date_Time control into an Event case, so if the user changes the date/time, it fires the Event case, and you update the indicator.

As I see you have also many bad design desicions in this code, possible race conditions (you use an indicator as data storage for example...)

 

 

Message 4 of 7
(3,571 Views)

Apologies. You can try compile the single vi as an executable.

 

I have tried using the standard LabVIEW timestamp control beforehand but it still gave me the same result.

 

As for using indicators for data storage, I only need the data when the user hit save and it will be stored to the database (Access file) with SQL queries

 

I did not have any training or whatsoever in LabVIEW. It was 100% self-learnt.

0 Kudos
Message 5 of 7
(3,559 Views)
When you run your app as an exe, the default time value (1904) will appear in your time/date string indicator after executio. If you put this date control and associate with an Event case, it should fix the problem i guess...
0 Kudos
Message 6 of 7
(3,547 Views)

There are several bugs in the VI:

  • cannot add new user, always get a msg: "User already exist"
  • there is no way to exit and close the application, i had to kill whole LabVIEW from task manager...

 

0 Kudos
Message 7 of 7
(3,533 Views)