look for file update over the internet (2 Viewers)

smig

Registered User.
Local time
Today, 17:02
Joined
Nov 25, 2009
Messages
2,209
To answer some of the recent points i need to do a bit of a preamble

My earlier conditional compilation code written around 2011-14 was both over-complex but also in the wrong order. At the time I used
Code:
#If VBA7 Then
…
#ElseIf Win64 Then
…
#Else
…
#End If

However using that meant the Win64 section never actually ran as all 64-bit Office versions used VBA7. Later I reversed the order before belatedly realising that the Win64 section wasn't usually necessary.

I wasn't alone in such contortions. For example arnelgp used to use
Code:
#If VBA7 Then
  #If Win64 Then
...
#Else
...
#End if
#Else
...
#End If

He also now uses a simplified approach

Now for Office versions remember #Win64 is always a subset of #VBA7. The converse isn't necessarily true.

The OS version isn't directly relevant though of course whilst you can have 32 bit Office in 64-bit Windows, the reverse isn't possible.
So 64-bit Office always means #If Win64 is true. Otherwise its 32-bit Office even if the OS is 64-bit.

I hope that has clarified things rather than add to any possible confusion

Thanks a lot for all the help here :)
what made me confused is using the word [B"]Win"[/B]to refer to the Office version.
theDBguy pointed me to the correct explanation of this:
You distinguish the Office version by the way the compiler run the code :D:D:D
 

smig

Registered User.
Local time
Today, 17:02
Joined
Nov 25, 2009
Messages
2,209
Thank you Both @Colin and @theDBguy for all the help here :)
It's all clear now.

Back to start of topic.
I used my own code for downloading the file from the internet, as I already had the code I needed.

Colin sure gave me the right direction of having a small text file containing the latest file version number, which in my case is part of the final file I need to download.
This way I don't need to look into the names of the files on the Internet.
 

theDBguy

I’m here to help
Staff member
Local time
Today, 07:02
Joined
Oct 29, 2018
Messages
21,477
Thank you Both @Colin and @theDBguy for all the help here :)
It's all clear now.

Back to start of topic.
I used my own code for downloading the file from the internet, as I already had the code I needed.

Colin sure gave me the right direction of having a small text file containing the latest file version number, which in my case is part of the final file I need to download.
This way I don't need to look into the names of the files on the Internet.
Hi. Congratulations! Glad to hear you got that part worked out as well. Good luck with your project.
 

isladogs

MVP / VIP
Local time
Today, 15:02
Joined
Jan 14, 2017
Messages
18,241
I have to say, rehashing all this made me think carefully about what each part means.
So thanks again for pointing out the convoluted APIs in my original code as well as querying what each part meant.

I expect there are other example apps based on APIs that I wrote in the past that still need updating. As and when a thread like this occurs, I check and fix old code. It would help if MS did the same!
 

Users who are viewing this thread

Top Bottom