Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Description of API in win32API
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Divers
Thread ID:
00272307
Message ID:
00274651
Vues:
49
Hi again Francis,

After doing some research, I can't find a way to cause everything to re-load the registry settings, other than a system re-boot. I did find an MS KB article (Q103645) which tells how to change the default printer in Windows for all versions of VFP. It recommends the changing of the WIN.INI file that I mentioned in a previous post.

Since it seems that this is the only option, I hope you don't mind a bit of advice.

Personally, I approach changing the system settings of the computer with extreme caution. It is, after all, the user's computer, and they've got it setup to suit themselves. One of the things that I always do in this sort of situation, is follow what I call "Mom's Rule". As a kid my mother was always telling me (and I'm sure many UTers heard the same thing from their mothers) to, "Put things back the way you found them." When dealing with the system, it's a rule that I always follow.

In order to implement this, I'd wrap my INIFiles class in another custom class. One of the custom properties of this class would be the original default printer setting. In this class's Destroy event, I'd place a call to restore the original setting. This would free me from having to remember to, "Put things back the way I found them."
George

Ubi caritas et amor, deus ibi est
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform