A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Using Forms
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

button to open form export to Excel and close form



 
 
Thread Tools Display Modes
  #1  
Old June 24th, 2008, 09:08 PM posted to microsoft.public.access.forms
deb
external usenet poster
 
Posts: 898
Default button to open form export to Excel and close form

I have a form called fBuyer and a form called fAdmin. I would like to have a
button on fAdmin to...
open the form fBuyer, export it to excel and close the form fBuyer.

How can I do this?

Thanks
--
deb
  #2  
Old June 24th, 2008, 10:26 PM posted to microsoft.public.access.forms
bhicks11 via AccessMonster.com
external usenet poster
 
Posts: 529
Default button to open form export to Excel and close form

Hi Deb,

Why do you need to open a form to export data? You don't export a form to
excel, you export data either a table or query.

Bonnie

http://www.dataplus-svc.com

deb wrote:
I have a form called fBuyer and a form called fAdmin. I would like to have a
button on fAdmin to...
open the form fBuyer, export it to excel and close the form fBuyer.

How can I do this?

Thanks


--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/For...forms/200806/1

  #3  
Old June 25th, 2008, 02:27 PM posted to microsoft.public.access.forms
deb
external usenet poster
 
Posts: 898
Default button to open form export to Excel and close form

Let me re-word...
I need to click a button and have the data export to Excel, from the
form"fBuyer" which is a form that is a datasheet view.

It sounds like you already know what I needed, but I was not able to explain
it the way you wanted.

Thanks
--
deb


"bhicks11 via AccessMonster.com" wrote:

Hi Deb,

Why do you need to open a form to export data? You don't export a form to
excel, you export data either a table or query.

Bonnie

http://www.dataplus-svc.com

deb wrote:
I have a form called fBuyer and a form called fAdmin. I would like to have a
button on fAdmin to...
open the form fBuyer, export it to excel and close the form fBuyer.

How can I do this?

Thanks


--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/For...forms/200806/1


  #4  
Old June 25th, 2008, 02:56 PM posted to microsoft.public.access.forms
bhicks11 via AccessMonster.com
external usenet poster
 
Posts: 529
Default button to open form export to Excel and close form

Sorry Deb. I wasn't trying to be snotty, it really is easy to be
misunderstood via the written word especially when you are talking about
things that can be worded so differently by different people.

So, to export to excel: On the button's OnClick event, put something like
this (customize to your table/queries, etc names):

DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel8, TableName,
FileNameto,HasFieldNames,


Look in the VBA help under TransferSpreadsheet if you have syntax problems.

Bonnie

http://www.dataplus-svc.com

deb wrote:
Let me re-word...
I need to click a button and have the data export to Excel, from the
form"fBuyer" which is a form that is a datasheet view.

It sounds like you already know what I needed, but I was not able to explain
it the way you wanted.

Thanks
Hi Deb,

[quoted text clipped - 12 lines]

Thanks


--
Message posted via http://www.accessmonster.com

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 06:24 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.