PDA

View Full Version : Need help with VBA



Ibragimov
07-25-2023, 09:48 PM
Hi everybody!
I've a userform as frmsettings in mainbook, this mainbook calculates data from another 3 sub workbooks. in local drive it works perfect but when i share this workbook to another users my VBA code gives debug and I'd found a reason.
mainBookPath = "D:\Onedrive\KHANTEX\mainbook.xlsm"book2Path = "D:\Onedrive\KHANTEX\subbook1.xlsx"
book3Path = "D:\Onedrive\KHANTEX\subbook2.xlsm"
book4Path = "D:\Onedrive\KHANTEX\subbook3.xlsm"
frmSettings.Image1.Picture = LoadPicture("D:\Onedrive\Towels" & fileName) - here I've a pictures of my products when I click command Button I can choose one of them and name and picture of choosen
product appears in userform.
does anybody can help me to change workbook path from local to WEB like https://onedrive.com/KHANTEX/ or another way which can works properly by shared link from not logged in PC to my onedrive account.

June7
07-25-2023, 10:48 PM
Review https://answers.microsoft.com/en-us/msoffice/forum/all/direct-link-to-image-in-onedrive/ba6e82ee-0b38-4862-80ed-1a3c3603f850 and https://www.reddit.com/r/windows/comments/40jwyq/is_there_a_way_to_directlink_images_from_onedrive/