从Excel 2010到2016,宏功能无法正常工作 [英] Macro function not working correctly from Excel 2010 to 2016

查看:534
本文介绍了从Excel 2010到2016,宏功能无法正常工作的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

嗨Guy's

这可能在某些时候被提及,但我似乎无法找到解决方案。

This has probably been mentioned at some point, but I cannot seem to find a solution.

我有创建了一个电子表格,可以将数据传输到下一个选项卡上的跟踪器,除了2016之外,它在Excel上的所有其他版本都很有效。

I have created a spreadsheet that transfers the data to a tracker on the next tab, and it works great with all the other versions on Excel except 2016.

我不知道为什么会发生这种情况。

I don't know why this is happening.

我希望有人有任何想法。

I hope someone has any ideas.

https://www.dropbox.com/s/h44pjegncxtb230/Asset%20Form%20Tracker%20back%20up.xlsm?dl=0

https://www.dropbox.com/s/h44pjegncxtb230/Asset%20Form%20Tracker%20back%20up.xlsm?dl=0

提前致谢

标记

推荐答案

如果你改变它会更好

It works better if you change

   范围("B4")。复制

    Range("B4").Copy

    ws.Range(" B4")。复制

    ws.Range("B4").Copy

以及将单元格从ws复制到ws1的其他行的类似内容。或者替换

and similar for the other lines that copy a cell from ws to ws1. Or replace

    ws.Range(" B4")。复制

    ws1.Range(" A& nextrow).PasteSpecial xlPasteValues

    ws.Range("B4").Copy
    ws1.Range("A" & nextrow).PasteSpecial xlPasteValues

with

    ws1.Range(" A"& nextrow).Value = ws.Range(" B4")。Value

    ws1.Range("A" & nextrow).Value = ws.Range("B4").Value

等。顺便说一句,我认为该行

etc. By the way, I think the line

如果ActiveCell = [H2]那么

If ActiveCell = [H2] Then

是没用的。


这篇关于从Excel 2010到2016,宏功能无法正常工作的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆