Convert labview date/time to excel date/time

How do I convert the "seconds since 1904" from the function "Get Date/Time in Seconds" to an MS Excel date/time format? The application runs in the Solaris environment.

hi, I am not sure about Solaris env.
Maybe this will help in one way or another.
Regards
ian.f
Sg/My
Ian F
Since LabVIEW 5.1... 7.1.1... 2009, 2010
依恩与LabVIEW
LVVILIB.blogspot.com
Attachments:
GetDatenTime_to_File.vi ‏48 KB

Similar Messages

  • Is it possible to convert LabView data into OLE variant?

    Hi. I'm using Activex Data Objects (ADO) to communicate with MySQL. Some ActiveX methods give OLE variant output, with "Variant Type" like "VT_ARRAY|VT_UI1", "VT_UI1" or "VT_BSTR". With some deduction and trial and error is relatively simple to extract data from this OLE variants and convert them to LabView data types. The problem is when I try to input variant data to some ActiveX methods, it almost always give me errors, I suppose because it expects the same type of the outputs, this is: OLE variants. Now, the question is: ¿Is there any way to convert LabView data into OLE variant data? ¿How?
    I've been searching and found a lot of posts about problems when passing variant data into ActiveX, saying that sometimes SAFEARRAYs are needed, sometimes saying that there were some bugs in LV6, giving some workarounds to this bug and saying that it is fixed in LV7.1, but the supposed workarounds don't work and the bug is still present in LV7.1, if it is really a bug.
    I think that if I could put LV data into OLE variant shape I may find an answer and solution to this matter.
    Thank you
    Daniel R.
    UdeC - Chile

    Below I describe how to handle OLE Variants, but I wanted to mention that LabVIEW does have a Database Connectivity toolkit (http://sine.ni.com/nips/cds/view/p/lang/en/nid/6429) that has already created a set of VIs for ADO. You might check that out first.
    However, handling OLE Variants in LabVIEW is automatic. LabVIEW itself has a variant datatype. When you use the ActiveX property or invoke nodes and one of the parameters is an OLE Variant, it is automatically converted to a LV Variant. You can then use the LV Variant VIs (such as "Variant to Data" and "To Variant").
    Brian Tyler
    http://detritus.blogs.com/lycangeek

  • How to convert labview data into opc tag

    Hi all,
    Can any one please tell me how i can convert the labview data global into a OPC tag? I have some data globals reading and writing data to the globals. Now i wanted to use a PLC device to send its outputs to the field.
    The PLC device will supports the OPC tags so i wanted t create OPC recognised tags in my labview. Is it possible. I saw that labview also having OPC functinalities. Please any one guide me in doing this.
    I will be very thankful to them
    Ramme..

    As I said, I believe you can do this for globals as well by opening its front panel (double click the global) and using a DS connection for the control that represents that specific global.
    As for other alternatives:
    NI sells the DSC module which comes with an OPC server and with better tags.
    You can use a common protocol like Modbus to interact with the PLC.
    You can use the custom protocol used by the PLC.
    The last two would require that you would change your program structure, so you would only want to use them under certain conditions.
    I believe the practical limit for OPC tags with DS is a few hundred tags, but I never used it myself so I didn't run into it. You can try searching the forums to find out more.
    Try to take over the world!

  • To develop an VI to aquire data of thermocouples from a remote chamber in labVIEW real time, should use NIDAQ or NIDAQmx?

    Hai
    I need to develop an VI to aquire data at real time. Am using LabVIEW RT as the OS and i need to know, if i can use NIDAQ 7.0 or should i use NIDAQmx? what is the diffrence between the two? is it just that NIDAQmx makes job simpler?
    Also can anybody please tell me, how to access a channel in labVIEW? am not clear about the path to follow to get the physical channel as a virtual channel on the LabVIEW.
    I am using a 8186 PXI with labVIEW RT and a SCXI, with both scxi and daq card on the same chassis.
    the development will be done on Windows XP which will be the host machine.
    Thanx in advance for any answers
    Arun

    Arun,
    DAQmx is our new Data Acquisition driver and should be considered as the primary option when writing new applications because of supportability in the future.
    DAQmx does make Data Acquisition tasks much simpler, abstracting many of the board implementation details and giving you a common API for 99% of the tasks you might want to accomplish.
    There are a couple of minimum requirements for using DAQmx on LabVIEW Real Time:
    - You will need LabVIEW Real-Time 7.1 (or higher)
    - You will need DAQmx 7.2 (or higher)
    These requirements are mentioned in the following Knowledgebase:
    Is NI-DAQmx Supported in LabVIEW Real-Time?
    The other thing you might want to make sure of is that DAQmx supports the DAQ hardware you already have or are planning to use. DAQmx does support most of the existing DAQ and SCXI hardware products, and reading thermocouples should become a very simple task.
    With DAQmx you can use physical channels, Global Channels (Aliases for preconfigured physical channels, equivalent to the Traditional DAQ Virtual Channels) or DAQmx Tasks (Preconfigured Data Acquisition tasks that include channel, timing and triggering information). A good place to start to learn about these features could be:
    Advantages of NI-DAQmx
    The following link might be useful to check Hardware support:
    http://www.ni.com/support/daq/versions.htm
    The driver can be downloaded by following these links:
    ni.com -> Support -> Drivers and Updates -> Current Software Versions -> Multifunction DAQ -> NI-DAQ Version 7.3 for Windows 2000/NT/XP
    This includes the latest version of DAQmx and our Traditional DAQ driver. Please note that DAQmx base is also listed but that's our Register-Level Programming (RLP) driver, which provides DAQ support for previously unsupported platforms.
    I hope this helps,
    Alejandro

  • How to convert the date time from MM-DD-YYYThh:mm:ss to YYYY-MM-DDThh:mm:ss format

    Hi All,
    I have a requirement in my project like to convert the date time from one format to another.my situation is like to convert the date time from MM-DD-YYYThh:mm:ss to YYYY-MM-DDThh:mm:ss format. I am using the soa suite 11.1.1.6.
    Can any one suggest me how to convert in the BPEL transformation.
    Thanks,
    Sanju.

    Hi Sanju,
    Store the date to be converted into a variable viz. dateVar. Now, process an expression in assign as: xp20:format-dateTime($dateVar,'[Y0001]-[M01]-[D01] [h]:[m01]:[s01]').
    Regards

  • Converting a date time to a date only

    Post Author: Dockman
    CA Forum: Formula
    I am working on a report that has a running total field.  The running total field keeps a running total and resets every time that a date changes.  the problem is that my dates include times, therefore the running total resets on every line.  How can I convert my date (in date time format) to be only a date so that it does not reset on every line?
    Obviously, I am not a programmer so I apologize if this is a stupid question.

    Post Author: yangster
    CA Forum: Formula
    if you are doing it inside crystal you can use the date functiondate({your.datetimefield})if you are doing it at the db level in a command this will vary depending on your db

  • Convert Epoch Date Time to Date Time format

    I am trying to convert Epoch Date time in GMT to Human Readable Date time format in UTC. I used the one below but it returns just the date in GMT but how can get datetime in UTC ?
    select To_Char( To_Date( '01.01.1970 06:00:00','DD.MM.YYYY HH24:Mi:Ss') + STARTIME / 86400,'DD.MM.YYYY HH24:Mi:ss') FROM HQ_AVAIL_DATA_RLE;
    I refered a couple of forums and applied everything, but still I wouldn't get the timestamp.
    Please note that i'm looking for datetime stamp, not just the date.
    Thanks in advance!
    Edited by: 830754 on Jan 27, 2011 11:18 AM
    Edited by: 830754 on Jan 27, 2011 11:19 AM

    Works for me. I see date and time (submitted 1000 for STARTTIME):
    select To_Char( To_Date( '01.01.1970 06:00:00','DD.MM.YYYY HH24:Mi:Ss') + 1000 / 86400,'DD.MM.YYYY HH24:Mi:ss')
    from dual
    TO_CHAR(TO_DATE('01
    01.01.1970 06:16:40Or do you mean something else?

  • Convert XMP Date and Time

    Hi, in my script I am trying to read the Date and Time using the XMP functions of a selected file in bridge.  Then, I want to convert that date and time into a format that looks like: "01/12/10 | 01:23 PM" and write that to another metadata field like the description.  Im stuck on trying to convert the date and time into what I want it to look like?  Can anyone help, thanks!
    Here is the part of the code I'm having trouble with:
    When I read the dateTimeOriginal property of the file, it is in an unfriendly format.  It looks odd and shows the time zone.  The commented lines is code that I have tried, but didn't work.  I was trying to convert the XMPDateTime object into a Date object so I can adjust the format, but I haven't been successful.
    var myXmpFile = new XMPFile( selectedFile.fsName, XMPConst.UNKNOWN, XMPConst.OPEN_FOR_UPDATE);      
          var myXmp = myXmpFile.getXMP();   
          var Name = myXmp.getProperty(XMPConst.NS_EXIF, "DateTimeOriginal");
          var date = new XMPDateTime(new Date(Name));
          var date2 = new Date(date);
          //dateFormat.masks.portfolioDate = 'mm/dd/yy "|" hh:MM TT';
    //date.format("portfolioDate");
    //date2.format("mm/dd/yy");
    alert(date2.toString());
    Name.convertToLocalTime();
    Name.toString();
    alert(Name);

    Thanks for helping me out Paul.  I just have one more small problem.  I am trying to access the Headline XMP property, and I know i need to use the IPTC Core property, but it doesn't seem to work.  Here is my current code, can you help me out?
    var selectedFile = thumb.spec;   
    var myXmpFile = new XMPFile( selectedFile.fsName, XMPConst.UNKNOWN, XMPConst.OPEN_FOR_UPDATE);      
    var myXmp = myXmpFile.getXMP();   
    var xmpString = myXmp.getProperty(XMPConst.NS_EXIF, "DateTimeOriginal").toString();
                alert(xmpString);
    var xmpString2 = myXmp.getProperty(XMPConst.NS_IPTC_CORE, "Headline").toString();
    alert(xmpString2);
    var dat =xmpString.match(/(\d+).(\d+).(\d+).(\d+).(\d+).(\d+)/);
    var amOrPm = "AM";
    var hours = Number(dat[4]);
    if (hours > 11) amOrPm = "PM";
    if (hours > 12) hours = hours - 12;
    if (hours > 11) amOrPm = "PM";
    if (hours < 10) hours = '0' + hours;
    var dateString = dat[2]+"/"+dat[3]+"/"+dat[1].substr (2) +" | "+ hours +':'+dat[5]+ ' ' +amOrPm;

  • Function module for converting German Data/Time to Indian Date/Time

    Dear All,
    My requirement is to convert German date and time to Indian date and time. Is there any function module available or any way we can get it?
    Thanks and regards,
    Atanu

    hi,
    first get the timezone of that country
    CALL FUNCTION 'TZON_LOCATION_TIMEZONE'
          EXPORTING
            if_country        = p_it_userid-zcountry
          IMPORTING
            ef_timezone       = l_tzone
          EXCEPTIONS
            no_timezone_found = 1
            OTHERS            = 2.
    then use the below statements
    -- Convert from server time to GMT
          CLEAR l_tstmp.
          CONVERT DATE l_datum
                  TIME l_ctime
             INTO TIME STAMP l_tstmp TIME ZONE sy-zonlo.
    *-- Convert from GMT to user backup time
          CONVERT TIME STAMP l_tstmp TIME ZONE it_usr_timezone-ztzone
            INTO DATE it_usr_timezone-zdate
                 TIME it_usr_timezone-ztime.

  • Convert util.Date to sql.Date with time being displayed!

    Hi all,
    I want to convert util.Date to sql.Date for passing the same to Database. (i donot want to use Timstamp, for some reasons)
    java.sql.Date sqldate =
    new java.sql.Date(new java.util.Date().getTime());
    This simple code truncates the Time component and the result will be only Date. But my requirement is for Data and Time, both.
    Request anyone to suggest how to go abt this problem.
    Thanx.

    You can use the class java.text.DateFormat (java.text.SimpleDateFormat) for displaying. For example like this.
    java.sql.Date sqldate = new java.sql.Date(new java.util.Date().getTime());
    java.text.SimpleDateFormat formatter = new java.text.SimpleDateFormat("yyyy.MM.dd 'at' HH:mm:ss z");
    String str = formatter.format(sqldate);
    System.out.println(str);

  • I have a string 2012-05-22T23:23:42.263-07:00. so i want to convert in date with indian time zone   can any one help me out

    i have a string 2012-05-22T23:23:42.263-07:00. so i want to convert in date with indian time zone   can any one help me out

    What does this have to do with iPhone tech support?

  • ABAP statement for converting UTC date/ time to local date/time

    Hi
    Is there any abap statement or any function module in BW which converts UTC date and UTC
    time into local date and local time according to specific country.
    Regards,
    Kate

    Hi,
    and to convert the country to a timezone first use: TZ_LOCATION_TIMEZONE
    /manfred

  • Data Socket Server installation on Labview run-time PC

    How do I install data socket server on a PC with Labview run-time licence only? Is it part of the installer?

    Yes, this will install entire DataSocket software. This includes: DataSocket Server, Manager, and Help.
    Zvezdana S.

  • Converting UTC dates to local time

    Hello all. I have some data I imported that has a date column containing dates spanning a number of years. The dates are in the UTC timezone.
    I need to display the dates in the local time zone that was in effect at the time. I've seen many fine examples of converting from one time zone to another. But I need it to be smarter than that. For example, date/times (this year) prior to 03/09/2008 2AM should display in EST (my zone in effect then), while date/times on/after then should display in EDT.
    Are there any Oracle built-in functions to do this, or will I need to gather the data of when daylight savings time begins/ends for the years I have dates and write my own function? I don't need help for the latter; I just don't want to reinvent the wheel. Also, I don't want to convert the data; I append to it regularly.
    Thanks for your help and consideration.

    Sergiusz, thanks again. When I added a very recent date, I saw the effect. But perhaps something is wrong with my local 10gR1 "play" database. It seems the DST start point is not correct. Should it not start showing -4 offset at row# 4? I didn't see a change until I added the last date. But I believe DST began on 3/9/2008 at 2am local, which is 7am UTC.
    ~Pete
    SQL> DROP   TABLE imported_events;
    Table dropped.
    SQL> CREATE TABLE imported_events (event_date TIMESTAMP(0) WITH TIME ZONE);
    Table created.
    SQL> BEGIN
      2  INSERT INTO  imported_events VALUES ( '10-JAN-08 2:00:00 PM UTC');
      3  INSERT INTO  imported_events VALUES ( '08-MAR-08 2:00:00 PM UTC');
      4  INSERT INTO  imported_events VALUES ( '09-MAR-08 6:59:00 AM UTC');
      5  INSERT INTO  imported_events VALUES ( '09-MAR-08 7:01:00 AM UTC');
      6  INSERT INTO  imported_events VALUES ( '09-MAR-08 2:00:00 PM UTC');
      7  INSERT INTO  imported_events VALUES ( '10-MAR-08 2:00:00 PM UTC');
      8  INSERT INTO  imported_events VALUES ( '09-JUN-08 2:00:00 PM UTC');
      9  COMMIT;
    10  END;
    11  /
    PL/SQL procedure successfully completed.
    SQL> COLUMN ROWNUM         FORMAT 99
    SQL> COLUMN event_date_utc FORMAT A25
    SQL> COLUMN offset_local   FORMAT 99
    SQL> COLUMN offset_eastern FORMAT 99
    SQL> SELECT ROWNUM
      2        ,event_date event_date_utc
      3        ,TO_CHAR(CAST((event_date AT LOCAL) AS DATE),'YYYY-MM-DD HH24:MI:SS') date_local
      4        ,(CAST((event_date AT LOCAL) AS DATE) - CAST(event_date AS DATE))*24 offset_local
      5        ,TO_CHAR(CAST((event_date AT TIME ZONE 'US/Eastern') AS DATE),'YYYY-MM-DD HH24:MI:SS') date_eastern
      6        ,(CAST((event_date AT TIME ZONE 'US/Eastern') AS DATE) - CAST(event_date AS DATE))*24 offset_eastern
      7    FROM imported_events
      8   ORDER BY 1;
    ROWNUM EVENT_DATE_UTC            DATE_LOCAL          OFFSET_LOCAL DATE_EASTERN        OFFSET_EASTERN
         1 10-JAN-08 02.00.00 PM UTC 2008-01-10 10:00:00           -4 2008-01-10 09:00:00             -5
         2 08-MAR-08 02.00.00 PM UTC 2008-03-08 10:00:00           -4 2008-03-08 09:00:00             -5
         3 09-MAR-08 06.59.00 AM UTC 2008-03-09 02:59:00           -4 2008-03-09 01:59:00             -5
         4 09-MAR-08 07.01.00 AM UTC 2008-03-09 03:01:00           -4 2008-03-09 02:01:00             -5
         5 09-MAR-08 02.00.00 PM UTC 2008-03-09 10:00:00           -4 2008-03-09 09:00:00             -5
         6 10-MAR-08 02.00.00 PM UTC 2008-03-10 10:00:00           -4 2008-03-10 09:00:00             -5
         7 09-JUN-08 02.00.00 PM UTC 2008-06-09 10:00:00           -4 2008-06-09 10:00:00             -4
    7 rows selected.
    SQL>

  • Convert into Data Table issue from Excel Sheet Table

    Hi 
    i've excel file where 10-12 sheets are available in that excel file.one of the sheet is named as summary.there are 8-10 tables(named as Table1,Table2,Table3....) in that summary sheet as well. 
    i've to actually get the Table1 from the summary sheet into the DataTable. 
    So,i've written a following method to read "summary" sheet and then i checked if the Table1 exist then break the loop.My problem is i've found Table1 but i am not able to convert it into the DataTable.Can anyone tell me how to do it.
    private void GetProjectTable(string ExcelFileUrl)
    string sheetName = "Summary";
    string value = null;
    // Open the spreadsheet document for read-only access.
    try
    String siteURL = SPContext.Current.Site.Url;
    SPSecurity.RunWithElevatedPrivileges(delegate()
    Stream dataStream = null;
    using (SPSite site = new SPSite(siteURL))
    using (SPWeb web = site.OpenWeb())
    SPFile file = web.GetFile(ExcelFileUrl);
    dataStream = file.OpenBinaryStream();
    using (SpreadsheetDocument document =
    SpreadsheetDocument.Open(dataStream, false))
    // Retrieve a reference to the workbook part.
    WorkbookPart wbPart = document.WorkbookPart;
    Sheet theSheet = wbPart.Workbook.Descendants<Sheet>().
    Where(s => s.Name == sheetName).FirstOrDefault();
    // Throw an exception if there is no sheet.
    if (theSheet == null)
    throw new ArgumentException("sheetName");
    WorksheetPart wsPart =
    (WorksheetPart)(wbPart.GetPartById(theSheet.Id));
    DocumentFormat.OpenXml.Spreadsheet.Table table = null;
    DataTable dt = null;
    foreach (TableDefinitionPart tdp in wsPart.TableDefinitionParts)
    if (tdp.Table.DisplayName == "Table1")
    table = tdp.Table;
    break;
    catch (Exception ex)
    Note: I am using this code in the Visual Web Part for SharePoint

    Hi hellofragrance,
    According to the description, you want to convert to the table in Excel to DataTable using Open XML SDK.
    As far as I know, there is no such API we can achieve the goal directly. However, we can write custom code to complete the job. Here are some major steps for your reference:
    1. Get the information of the table we wanted to convert. For example, column information and the range address for the table. And we can get the these information via the
    Table object of
    TableDefinitionPart Class
    2. Then we can create a DataTable via the column information we get from step1 and initialize the data table via read the data from range of table.
    In addition, here is helpful article about read the value of specific cell for your reference:
    How to: Retrieve the values of cells in a spreadsheet document (Open XML SDK)
    Regards & Fei
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

Maybe you are looking for

  • How to output PDF files in a crystal Report

    Hello, I've some data stored in a database, they are PDFs files data. How can I include them in a report For example I've a Table MyTABLE with 2 Cols (Name STRING, data byte[]) (in fact it's a .NET/DataSet) I would like to display the content of my t

  • Table for customer cr exposure

    Hi All, Could any body let me know about the table where can I see the amount of customer credit exposure? regards Meenakshi

  • Ask - how to draw diagonal border on XMLPublisher report?

    Hi all, I need to draw diagonal border on my XML Publisher report. xsl attributes I tried are: <xsl:attribute xdofo:ctx="block" name="border-diagonal">1pt solid #000005</xsl:attribute> <xsl:attribute xdofo:ctx="block" name="border-diagonaldown">1pt s

  • Web Dynpro for ABAP iVIew's Namespace parameter

    Hi Gurus, I am trying to create Web Dynpro for ABAP iVIew in portal There I have confusion while giving namespace say I m trying to create iView for standard WD4ABAP Application which lies in SICF at below location /default_host/sap/bc/webdynpro/sap/

  • Plz hlp me in understanding thz  report and function modules used in it

    TABLES: BKPF,         BSEG,         KNA1,         SKAT,         USR02,         T001W. SELECTION-SCREEN: BEGIN OF BLOCK HEAD WITH FRAME TITLE TEXT-T01. PARAMETERS    : WERKS LIKE T001W-WERKS OBLIGATORY,               : HKONT LIKE BSEG-HKONT OBLIGATORY