UtterAccess.com
X   Site Message
(Message will auto close in 2 seconds)

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> Export of Table to Excel    
 
   
hsotb
post Sep 15 2006, 09:47 AM
Post #1

UtterAccess Addict
Posts: 276
From: Chicago, Illinois



I'm using the DoCmd.SendObject to send a table in excel format via email. Im using the MicrosoftExcelBiff8(*.xls) and run into the following problem.

A field in the table is formatted as Memo but when it gets transfered it goes to Text (255 limit). But when I do just a TransferSpreadsheet it remains a Memo field.

Here is the complete command that I'm using

DoCmd.SendObject acTable, "Table_name", "MicrosoftExcelBiff8(*.xls)", "Myemail@mail.com","","","File attached","", False, ""

Now I also did some testing and did the sendobject in a macro and it worked just fine, but for some reason the VBA version is not working..

Any suggestions would be helpfull.

Thanks
Go to the top of the page
 
+
freakazeud
post Sep 15 2006, 09:57 AM
Post #2

UtterAccess VIP
Posts: 31,413
From: NC, USA



Hi,
did you convert the macro to VBA to check the arguments and see if they match up to what you have?
HTH
Good luck
Go to the top of the page
 
+
hsotb
post Sep 15 2006, 10:00 AM
Post #3

UtterAccess Addict
Posts: 276
From: Chicago, Illinois



Yes I did.

They match perfectly......
Go to the top of the page
 
+
freakazeud
post Sep 15 2006, 10:16 AM
Post #4

UtterAccess VIP
Posts: 31,413
From: NC, USA



If you want to continue to use the outputto/sendobject method then check this.
If you don't care then use the transferspreadsheet method...and attach the outputted file to an automated email using automation code (search UA for many samples). The sendobject method is very limited anyway.
HTH
Good luck
Go to the top of the page
 
+
hsotb
post Sep 16 2006, 08:08 AM
Post #5

UtterAccess Addict
Posts: 276
From: Chicago, Illinois



Thanks for the link it will be very helpfull.

Just to get it out I'm using the macro, not the best way but hey it works.
Go to the top of the page
 
+
freakazeud
post Sep 16 2006, 09:38 AM
Post #6

UtterAccess VIP
Posts: 31,413
From: NC, USA



Glad you got it sorted out.
Good luck on future projects!
Go to the top of the page
 
+

Thank you for your support! Reply to this topicStart new topic

Jump To Forum:
 



RSS Go to Top  ·  Lo-Fi Version Time is now: 22nd May 2013 - 12:37 AM