Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Write my invoices in Word?
Message
De
09/11/1998 04:59:52
 
 
À
09/11/1998 03:56:46
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Divers
Thread ID:
00155639
Message ID:
00155647
Vues:
27
>>Hi,
>>
>>I've been able to achieve some results with Word, things like merge letters a.s.o. Now I'd like to push my knowledge a bit further and print an invoice, with a nice header, detail lines and a nice footer.
>>
>>I know how to resolve the header and (propably) the footer parts. But for the lines, I need to build a table (in Word parlance). I gathered code from here and there and have a general idea of how to achieve that.
>>
>>But there are a few points that I need to resolve. How can I make sure that the table starts always at the exact same place on the paper sheet? And how do I handle multiple page invoices?
>>
>>Before reinventing the wheel, I'd like to know your suggestions.
>>
>>José
>Jose,
>There is some detailed stuff concerning mailmerge in another thread "Word Manipulation Through VFP". For invoice I would create a template file which has header, footer, company logo etc are already set in font and style of your choice + keep any static+one per invoice mergefield in header+footer area of word. This would provide a way to keep the table always start at a certain place (and end at a certain place per page). Pagetotal etc then could be in word-footer area freely manipulated. You could have "variables" for dynamic data in header and footer part and just change variable value. (oWord.variables("myvariable").value = newValue).
>And with selinfo(6) (word.basic - works in both word95 and 97) give vertical position. With it you could start to insert detail rows and when reached a certain point insert some other data (ie: pagetotal). Also if you knew how many rows a page would hold at max you could insert tables split per page.
>Cetin



In my view, Export to Excel is better than Word!

This is because Word Macros for Word 6.0/95 can't draw lines, square well.
It will get trouble unless you have an exteneral .dot file to do!

For excel, you can all done in VFP calling without using template to do, it will more easy to bold square or draw lines.

Anyway, just an advise!
The weak wait for chance, The strong bid for chance,
The clever notch up chance, but The merciful give you chance.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform