Results 1 to 4 of 4

copy-paste from one xl wbook in to another and then save it as a .txt file.

Threaded View

biggles copy-paste from one xl wbook... 10-29-2007, 08:35 AM
biggles Sob! sob!! No Response 10-30-2007, 11:53 AM
rylo Hi See if this gets you... 10-30-2007, 09:30 PM
biggles Danke! Rylo 10-31-2007, 01:29 PM
  1. #1
    Registered User
    Join Date
    09-17-2007
    Posts
    31

    copy-paste from one xl wbook in to another and then save it as a .txt file.

    hi tech wizards,

    help!elp!elp! (dont throw a life bouy just yet. haha)

    just a beginner with this thingy called macros(rocketscience?)

    i want to take some data from an excel sheet(which is updated frequently) and copy-paste it in another file and save it as a .txt file. i want to do it every one minute.

    so i tried out a macro but it isnt going any where. it looks something like this

    Sub macro1()
    '
    ' macro1 Macro
    ' Macro recorded 29/10/2007 by Jerry 
    '
    ' Keyboard Shortcut: Ctrl+Shift+K
    '
        Sheets("original").Select
        Columns("A:A").Select
        Selection.Copy
        Sheets("output required").Select
        Columns("A:A").Select
        ActiveSheet.Paste
        Sheets("original").Select
        Columns("B:B").Select
        Application.CutCopyMode = False
        Selection.Copy
        Sheets("original").Select
        Columns("G:G").Select
        Application.CutCopyMode = False
        Selection.Copy
        Sheets("output required").Select
        Columns("C:C").Select
        ActiveSheet.Paste
        Sheets("original").Select
        Columns("E:E").Select
        Application.CutCopyMode = False
        Selection.Copy
        Sheets("output required").Select
        Columns("D:D").Select
        ActiveSheet.Paste
        Sheets("original").Select
        Columns("D:D").Select
        Application.CutCopyMode = False
        Selection.Copy
        Sheets("output required").Select
        Columns("F:F").Select
        ActiveSheet.Paste
        Columns("G:G").Select
    End Sub






    actually what i wanted to do was

    -start this macro ---- time;end at ---- time
    -copy col A and paste in another workbook as col A
    - replace colB with todays date minus 500 days+counter(initial posn is zero)

    ( preferabe if 500 figure could be selectable)

    - copy colE and paste as colD
    -copy colD and paste as colE
    -copy colG and paste as colC
    -colF= average of colD and colE
    -copy colH and paste as colG
    -save the workbook as the date set in colB.txt (todays date minus 500 days+counter. eg C/my doc/20060705.txt ( preferably location be selectable)

    run this macro again after one minute
    (now the counter will add one to the date)

    end


    is it possible or am i trying for too much, pse forgive as new to this science.


    so could a kind soul pse help.

    thanks a million

    biggles
    Attached Images Attached Images
    Last edited by VBA Noob; 10-29-2007 at 10:02 AM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1