cancelar
Mostrando los resultados de 
Buscar en lugar de 
Quiere decir: 

scan from string does not recognize AM/PM flag

¡Resuelto!
Ir a solución

Hi,

 

I am using Labview 8.6. I want to parse a time string, with an AM/PM flag inside, but the "scan form string" time format code

"%<%d/%m/%Y %I:%M:%S %p>T" does not recognize the AM/PM flag. The remaining string containes the AM/PM flag.

 

best regards,

Friedrich Vollink.

 

 

0 kudos
Mensaje 1 de 8
5.435 Vistas

Example with default values.

0 kudos
Mensaje 2 de 8
5.428 Vistas

I think Format string is wrong..it should be "%<%H:%M:%S%2u%m/%d/%y>T"

Gaurav k
CLD Certified !!!!!
Do not forget to Mark solution and to give Kudo if problem is solved.
0 kudos
Mensaje 3 de 8
5.423 Vistas

It works now. I toggled AM/PM time format on my laptop (control panel/local settings).

 

Thanks for the reply.

 

Regards,

Friedrich Vollink 

0 kudos
Mensaje 4 de 8
5.417 Vistas
Solución
Aceptado por el autor del tema FriedrichV

The solution is:

 

define the AM and PM symbols in the control panel\regional settings\time  Pffffffffffffffffffffffffffff

 

Regards,

Friedrich Völlink

Mensaje 5 de 8
5.390 Vistas

I'm using LV2010 and the AM/PM flags are defined in the control panel/local settings, but I still have the same problem!

 

 

 

Format String:  %<%m/%d/%y %H:%M:%S%p >T

 

Input String:

 

05/06/11 02:15:56 PM

 

Output Time Stamp:

2:15:56.000 AM
5/6/2011

 

Remaining String:

PM

 

0 kudos
Mensaje 6 de 8
5.277 Vistas

Did you read the help for time format strings? You cannot use 'H' for 24 hour time and the am/pm flag.

Mensaje 7 de 8
5.265 Vistas

Thanks, Missed that!

0 kudos
Mensaje 8 de 8
5.247 Vistas