Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Setting Printer Properties Beta Testers Needed
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Produits tierce partie
Versions des environnements
Visual FoxPro:
VFP 9
Divers
Thread ID:
01050441
Message ID:
01051843
Vues:
17
Hi Barbara,

>I was just thinking you might have meant that you were wondering if I was going to finish the DeviceCapabilities checking. Actually, I don't think I am. I'm currently checking that the printer has the paper bin that you're trying to set. Many of the other properties are checked via the BITAND function against the dmFields from the DEVMODE structure (i.e. duplex, orientation). For some, I'm not sure which constant to use for DeviceCapabilities, nor the length of the string for the buffer.
>

Sorry for jumping in. I think your class is great. The sample works fine too! Since you said you're not sure about the length of string, I've looked through your code for the buffer:
    * First call DeviceCapabilities in a way that returns the size of the buffer we need
*   lnBuffer = DeviceCapabilities(lcPrinterName, lcPort, tnValue, 0, 0)
*   The above call is only returning 2.  Need to figure out why it's not correct.

lnBuffer = 1024
lcIDBuf = REPLICATE(CHR(0), lnBuffer)
lnDCCnt = DeviceCapabilities(lcPrinterName, lcPort, tnValue, @lcIdBuf, 0)
I think the return value from the first call is correct. Can you tell a bit more why do you think it is not? What printer you use to test it?
Try to compare the return value from the first call with the second call. Both calls should return the same value

Regards
Herman
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform