Tip Bank

DevX - Software Development Resource

Query to a Text File

Question: I would like to create a stored procedure that runs a query and outputs the results to a text file and allows me to add extra delimeters and static

DevX - Software Development Resource

Indexing Remote Views

Question: We have to connect VFP to SQL Server, and we have a lot of non-structural index files for tables. We’ve created remote views for the tables and need to

DevX - Software Development Resource

Faster string appending with Mid$ command

As you probably know, the “&” operator is rather slow, especially with long strings. When you have to repeatedly append chucks of characters to the same variable, you can speed

DevX - Software Development Resource

Export to a text file with quoted fields

As explained in another item in this Tip Bank, you can use the Recordset’s GetString method to export a Recordset to a comma-delimited or tab-delimited text file. However, if you

DevX - Software Development Resource

Clone a Font object

When you want to assign a control’s Font to another control, the first obvious way is to assign the Font property directly, as in: Set Text2.Font = Text1.Font but in

DevX - Software Development Resource

Replicate a string of any length

The String$ function can replicate only 1-char strings, so it seems that you need a loop to duplicate strings that contain 2 or more characters. However, this is a one-liner