A
Arno
Hi all,
Have a question regarding an import issue I have when using VBScript
to programmatically import an Access table into a worksheet.
Using the macro recorder, I imported an Access database (1 table).
I took the code, adjusted it to be VBScript compatible, no other
changes(!), and ran my VBScript.
My import runs fine, except for the following: when importing Date
fields from Access using VBScript, dates are displayed as the actual
number values in Excel - I have to manually set the format of those
columns to date type to get the 'proper' date display.
This does not happen when I import manually manually, or run the macro
recorded from the VBE.
However, my VBScript code is an *exact* copy of that code, only
adjusted to overcome minor language issues (such as translating
xl<Enum> constants to their native values and using
<myworkbook>.Worksheets(<x>) instead of ActiveSheet).
Is there anyone who could shed some light on this? Does it perhaps
make a difference being inside or outside the Excel UI?
tia
arno
Have a question regarding an import issue I have when using VBScript
to programmatically import an Access table into a worksheet.
Using the macro recorder, I imported an Access database (1 table).
I took the code, adjusted it to be VBScript compatible, no other
changes(!), and ran my VBScript.
My import runs fine, except for the following: when importing Date
fields from Access using VBScript, dates are displayed as the actual
number values in Excel - I have to manually set the format of those
columns to date type to get the 'proper' date display.
This does not happen when I import manually manually, or run the macro
recorded from the VBE.
However, my VBScript code is an *exact* copy of that code, only
adjusted to overcome minor language issues (such as translating
xl<Enum> constants to their native values and using
<myworkbook>.Worksheets(<x>) instead of ActiveSheet).
Is there anyone who could shed some light on this? Does it perhaps
make a difference being inside or outside the Excel UI?
tia
arno