Issue importing dates with CSV

Issue importing dates with CSV

avatar

Hi,

I'm trying to do a mass import of sessions via csv, which seems to go fine until I add the a column to import the Purchase date, at which time RDM complains:

Unexpected error has occurred. Please check the execution log.


CSV Contents:

Host,MetaInformation\OS,MetaInformation\ServiceTag,MetaInformation\SerialNumber,MetaInformation\PurchaseDate
BLHPOS4,Microsoft Windows 7 Professional,10AHCTO1WW,PC069F6N,2015-08-07



The date format appears to be correct according to the help:

MetaInformation\PurchaseDate
Purchase date in a ISO8601 format, i.e. yyyy-mm-dd


[/table]


Error text from the execution log below:

[31/08/2015 8:48:25 AM]ERROR SILENT System.ArgumentException: Object of type 'System.String' cannot be converted to type 'System.Nullable`1[System.DateTime]'.
at System.RuntimeType.TryChangeType(Object value, Binder binder, CultureInfo culture, Boolean needsSpecialCast)
at System.RuntimeType.CheckValue(Object value, Binder binder, CultureInfo culture, BindingFlags invokeAttr)
at System.Reflection.MethodBase.CheckArguments(Object[] parameters, Binder binder, BindingFlags invokeAttr, CultureInfo culture, Signature sig)
at System.Reflection.RuntimeMethodInfo.InvokeArgumentsCheck(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at System.Reflection.RuntimePropertyInfo.SetValue(Object obj, Object value, BindingFlags invokeAttr, Binder binder, Object[] index, CultureInfo culture)
at System.Reflection.RuntimePropertyInfo.SetValue(Object obj, Object value, Object[] index)
at Devolutions.Utils.ReflectionUtils.SetPropertyValue(Object obj, String propertyName, Object value, Boolean allowNull)
at Devolutions.RemoteDesktopManager.Business.BusinessHelper.SetPropertyDirect(Object source, String containerName, String propertyName, Object value)
at Devolutions.RemoteDesktopManager.Business.CsvFormat.CsvImport.ImportFromCsv(String fileName, String rootFolder, Connection connectionTemplate, String& errorMessage, List`1 importCanditates)
at Devolutions.RemoteDesktopManager.Forms.FrmImportCsvWizard.ImportFromCsv(String fileName, String destGroup)

And as I mentioned, as soon as I pull out the column for date the data imports perfectly. Any ideas?

All Comments (4)

avatar

Hi,
Looks like a bug with the datetime conversion. I will ask JP to enter a bug and assign it.

David Hervieux

avatar

Hello,

This bug will be fixed in the next version of RDM beta.

Regards,

Hubert Mireault

avatar

Hi,

The CSV import appears to be fixed, however if the items are re-factored into VNC it somehow loses the host field & crashes the client if you try and connect (warns it cant connect to the data store, asks to go offline?).

I've found if you go to the properties dialog and click in the host field it copies across the correct value, however this is a bit taxing with so many computers.

I re did the import with a template specifying VNC and it seems to be fine - must be to do with the Re-Factoring?

Error:
NullReferenceException - Object reference not set to an instance of an object.

at Devolutions.Vnc.VncCustomControl.OnResize(EventArgs eventargs)
at System.Windows.Forms.Control.OnSizeChanged(EventArgs e)
at System.Windows.Forms.Control.UpdateBounds(Int32 x, Int32 y, Int32 width, Int32 height, Int32 clientWidth, Int32 clientHeight)
at System.Windows.Forms.Control.UpdateBounds()
at System.Windows.Forms.Control.WmWindowPosChanged(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

avatar

Hello,

The issue with the type conversion (using the Change Type menu) not keeping the host will be fixed in the next version of RDM.

As for the other error, we'll talk with our VNC guy and see what the issue is.

Regards,

Hubert Mireault