p2p.wrox.com Forums

Need to download code?

View our list of code downloads.


Go Back   p2p.wrox.com Forums > Microsoft Office > Other Office > BOOK: Professional InfoPath 2003
I forgot my password Register Now
Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
BOOK: Professional InfoPath 2003
This is the forum to discuss the Wrox book Professional InfoPath 2003 by Ian Williams, Pierre Greborio; ISBN: 9780764557132

Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Professional InfoPath 2003 section of the Wrox p2p Programmer to Programmer discussion community. This is a community of more than 40,000 computer programmers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining our free Wrox p2p community you can post your own programming questions and respond to other programmers’ questions. Registered users also don't have to see the ads that are displayed to guests. Registration is fast, simple and absolutely free so please, join today!
Join today and post to win prizes! Post more to increase your chances of being Wrox’s top poster of the month.

Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old November 14th, 2007, 04:53 PM
Registered User
 
Join Date: Nov 2007
Location: Elizabeth City, NC, .
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default export to existing excel spreadsheet

Hello:

I need to create a button in an InfoPath 2003 form that will insert the data into an existing excel spreadsheet.

I found this code that will do exactly what I want but I need it in jscript (I didn't set programming language to VB prior to creating form, 2007 will remove code but haven't found how to do so in 2003):

__________________________________________________ __________________________________________________ _

Answer
You can try this variation of the code:
Sub CopySelection()
  Selection.Copy
  Windows("Destination.xls").Activate
  With Sheets("Sheet1").Range("A1").CurrentRegion.End(xlD own)
      .Offset(1, 0).Select
      ActiveSheet.Paste
      .Offset(1, 0).Value = .Value + 1
  End With
End Sub
This can give an error if the value of column A is not a number, but this shouldn't be the case.

Hope this helps,
Miguel
__________________________________________________ __________________________________________________ ___



Can someone provide much the same in jscript?

Thanks,

Mary Potter



Mary Potter
__________________
Mary Potter
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
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
Trackbacks are Off
Pingbacks are On
Refbacks are Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Export Table data into an Excel SpreadSheet hewstone999 Access VBA 0 March 3rd, 2008 07:00 AM
Export all tables in Access to a SpreadSheet hewstone999 Access VBA 0 February 29th, 2008 11:27 AM
Export to existing excel file with headings Neal Access VBA 0 February 27th, 2008 03:31 PM
Export a spreadsheet Corey Access 0 November 22nd, 2005 03:42 PM
Spreadsheet Export Sizes rweide Classic ASP Basics 0 February 25th, 2005 03:51 PM



All times are GMT -4. The time now is 06:03 AM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
© 2008 Wiley Publishing, Inc