+ Reply to Thread
Results 1 to 3 of 3

Conditionally calculate the data and paste it, if condition Matches

  1. #1
    Forum Contributor
    Join Date
    05-10-2020
    Location
    india
    MS-Off Ver
    2013
    Posts
    221

    Conditionally calculate the data and paste it, if condition Matches

    Hello Everyone, I am Looking for a macro and i have putted the details Below

    If column B of sheet4 of sample2.xlsx match with column I of sample1.xls then look column D of sheet4 of sample2.xlsx & if column D of sheet4 of sample2.xlsx has > then calculate 1% of column D of sample1.xls & subtract it with column D of sample1.xlsx & put that data in column D of sample1.xls Or if column D of sheet4 of sample2.xlsx has < then calculate 1% of column D of sample1.xls & add it with column D of sample1.xlsx & put that data in column D of sample1.xls

    Plz Note
    All files are located in a different path (So in the macro the path will be hardcoded, Assume any path & I will edit the path manually by myself)
    Sheet name can be anything
    Macro will be putted in a vba.xlsm

    Plz see the file that I have attached below
    I have pasted the result in Column K for understanding purpose& that data will be in column D after runing the macro
    Attached Files Attached Files

  2. #2
    Valued Forum Contributor Eastw00d's Avatar
    Join Date
    02-29-2020
    Location
    Breda, NL
    MS-Off Ver
    2016, 2019
    Posts
    833

    Re: Conditionally calculate the data and paste it, if condition Matches

    Hi, maybe this could work for you:
    Please Login or Register  to view this content.
    Cheers
    Erwin
    I started learning VBA because I was lazy ...
    Still developing.... being more lazy...

  3. #3
    Forum Contributor
    Join Date
    05-10-2020
    Location
    india
    MS-Off Ver
    2013
    Posts
    221

    Re: Conditionally calculate the data and paste it, if condition Matches

    Thnx Alot Eastw00d

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Conditionally copy paste the data
    By dumdumbum in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 05-11-2020, 09:52 AM
  2. Macro to Conditionally Paste Data into New Tab
    By Please_Help_ in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-17-2018, 02:51 PM
  3. If condition matches copy data from one sheet to another
    By ravindra2k13 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 03-14-2018, 06:14 AM
  4. [SOLVED] Condition 2 matches or partial match Data retrieve
    By irajeev in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 07-21-2016, 04:58 PM
  5. [SOLVED] copy and paste values to another sheet if value in one column matches condition
    By KK1234 in forum Excel Programming / VBA / Macros
    Replies: 13
    Last Post: 11-05-2013, 11:36 AM
  6. Conditionally Copy/Paste Data from one Workbook to another
    By justin19 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 07-02-2013, 04:48 PM
  7. How do you count data that matches more than one condition?
    By ryesworld in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 11-08-2005, 09:00 PM

Tags for this Thread

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