Macro error

ahovander1213

New Member
Joined
Oct 13, 2018
Messages
10
I have a macro that works on my pc perfectly. When I try to run on other users pc I get the same error.
Section below in red font is my issue.

When I have other users run I get a DEBUG error and the red font highlights in Yellow. (Sorry I couldn't figure out how to hightlight in this website to match)

Initial thought was that other users did not have read/write permissions to the folder specified. I have triple checked that they do have the rights.
Now I am thinking that Excel needs to be tweaked in Trust Center.

Any and all assistance is greatly appreciated.

Sub GS_Push()
'
' GS_Push Macro
'

'
Application.Goto Reference:="R19C28"
Range("AB19").Select
Selection.Hyperlinks(1).Follow NewWindow:=False, AddHistory:=True
ActiveSheet.ExportAsFixedFormat Type:=xlTypePDF, Filename:="\\a-ca-App01\SmartSearchImport\Order\29\QC Sales " & Range("n2") & "." & Range("t2").Value _
, Quality:=xlQualityMedium, IncludeDocProperties:=True, _
IgnorePrintAreas:=False, OpenAfterPublish:=False

ActiveWorkbook.Save
ActiveWorkbook.Close
 

Excel Facts

When did Power Query debut in Excel?
Although it was an add-in in Excel 2010 & Excel 2013, Power Query became a part of Excel in 2016, in Data, Get & Transform Data.
Do they have a hyperlink set up on cell AB19? The code does not set the hyperlink, so it appears they would have toi do that manually for each new user of the macro.
 
Upvote 0
Macro is run off a excel template form. Everyone starts in file A, macro open file B then saves to location as a pdf, save, close.. Back to file A
 
Upvote 0
Code:
When I try to run on other users pc I get the same error.

while the template might be the same on all systems, the code is user specific. If the user has not explicitly set cell AB19 to the same hyperlink that exists on your PC then they will not get the same results. If you had posted the error message you are getting, it would help to make a better analysis. We don't need to see a picture of the dialog box, just the error number or brfief summary of the error message.
 
Upvote 0
Error code is

Microsoft Visual Basic
Run-time error '1004':

Is there a way for the 2 of us to email each other. This way I can attach screenshots of my issue
 
Upvote 0
If you look below this text you will see the word Attachments in large orange letters. click on that and then follow the results to find the methods of attaching images to these threads. i do not accept and offline email requests because it deprives others of the ability to learn by what others on this site do. The 1004 run time error is a general error message usually caused by erroneous user input such as misspelled words or missing parts of constants such as a range reference with only a column and no row, or missing punctuation in some cases.
 
Last edited:
Upvote 0

Forum statistics

Threads
1,223,893
Messages
6,175,248
Members
452,623
Latest member
cliftonhandyman

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top