Is it possible to code the “Register Table” command with specific column formatting rather than having to do so manually?
Using this command,
Register Table "M:\Pulls\Set.xlsx" TYPE XLS Titles Range "ExternalData_1" Interactive Into "M:\Pulls\Set.TAB"
has the table structure window appear so the user can select column formats.
I’d like to code in the column formats so that is skipped, if possible.
Thank you.
Hi Matthew
Have you tried omitting the Interactive keyword from your statement?
From the help:
Specifying the Interactive keyword for the XLS type, instructs the interface to display the Set Field Properties window when importing Excel files.
MapInfo Pro will inspect the data and come up with the best match.
If you want to change this, you could open the tab file created using the Register Table statement, and change the column types defined here.
By open I mean, open it as a file through MapBasic and writing out a new file with the changed column types.
This would of course require that you know which column types to change
From: mapi...@googlegroups.com <mapi...@googlegroups.com>
On Behalf Of Matthew Hirsch
Sent: 16. september 2021 22:01
To: mapi...@googlegroups.com
Subject: [MI-L] Registering excel - code to define columns automatically
This message originated Externally. Use proper judgement and caution with attachments, links, or responses. |
--
--
You received this message because you are subscribed to the
Google Groups "MapInfo-L" group.To post a message to this group, send
email to mapi...@googlegroups.com
To unsubscribe from this group, go to:
http://groups.google.com/group/mapinfo-l/subscribe?hl=en
For more options, information and links to MapInfo resources (searching
archives, feature requests, to visit our Wiki, visit the Welcome page at
http://groups.google.com/group/mapinfo-l?hl=en
---
You received this message because you are subscribed to the Google Groups "MapInfo-L" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
mapinfo-l+...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/mapinfo-l/SJ0PR04MB7501218FDC83C9790A1A0308ABDC9%40SJ0PR04MB7501.namprd04.prod.outlook.com.