I saw that if, in the providence of God, wealth has been acquired, there is no sin in possessing it; and if no opportunities present themselves to use this means to advance the cause of God, there is no sin in still possessing it. But if opportunities are presented to the brethren to use their property to the glory of God and the advancement of His cause, and they withhold it, it will be a cause of stumbling to them. In the day of trouble that which was their hoarded treasure will be an offense unto them. Then all opportunities will be past for using their substance to the glory of God, and in anguish of spirit they will cast it from them to the moles and to the bats. Their gold and their silver cannot save them in that day. It falls upon them with crushing weight, that an account must be given of their stewardship, what use they have made of their Lord's money. Self-love made them believe that it was all their own, and that they might want it all; but they then feel, bitterly feel and…
"Your gold and silver is cankered; and the rust of them shall be a witness against you, and shall eat your flesh as it were fire. Ye have heaped treasure together for the last days."
Both passages discuss the futility of hoarding wealth and the negative consequences of doing so, especially in the end times. The imagery of gold and silver being worthless and even harmful is present in both.
"Lay not up for yourselves treasures upon earth, where moth and rust doth corrupt, and where thieves break through and steal: But lay up for yourselves treasures in heaven, where neither moth nor rust doth corrupt, and where thieves do not break through nor steal:"
Both passages address the principle of not storing up earthly treasures but rather investing in heavenly ones. EGW expands on this by connecting it to stewardship and using wealth for God's cause.
"For the love of money is the root of all evil: which while some coveted after, they have erred from the faith, and pierced themselves through with many sorrows."
Both passages address the dangers of the love of money. While EGW focuses on the failure to use wealth for God's work, and 1 Timothy focuses on the love of money leading to straying from faith, the underlying principle of the danger of misusing or loving money is present in both.