There really isn't a clear distinction between a "code generator" and a "programming language." If you use software to generate code, you are doing programming, even if you don't understand the details. C++, Java, and C# are "code generators" in the sense that they get compiled into lower level languages, and those lower level languages themselves can be hand-coded if a programmer chooses to do so. Many programming languages start out as macro tools, and writing a script using an XML-based tool does not make it less of a "program" than if the same script is written in Perl, Python, or Ruby.
Generally speaking, saving time by using software to generate highly repetitive code is a good idea. The potential downside is that you may lock yourself into a platform--that is, you are limited to functionality that the code generator provides. Whether or not a code generator (or programming language) is worth using entirely depends on how effective it is for a given problem.
Don't fall for the mental trap of thinking that some formats like XML or even HTML are dead "data" and other formats like C++ and Python are "code". Data and code are interchangeable. Need an example of "code" in HTML? Consider the following:
HTML is a declarative language. In it you specify things that exist, in the manner of "here is a paragraph, here is a heading" and so forth. Python and other programming languages have imperative parts where you specify "now add x and y, now write x to memory" and so forth.
You can invert this relationship, however. In the case of HTML, it becomes imperative when fed through a browser. "Here is a paragraph with these properties" is interpreted by Firefox as "now render a body of text with these parameters." As a file, HTML is simply dead data, but in the context of an interpreter, it becomes live code. The same happens in reverse with Python. During execution, your Python instructions become directives to the interpreter, but the Python file itself is simply dead text. In a sense your Python program sits there as a collection of potential instructions in the form of data until you run it through the Python interpreter. In exactly the same way, and HTML sits as data in a file until it comes time for the browser to act on it.
XML is a data format, but instructions are a type of data. You can use XML to contain imperative statements, such as mathematical operations or function calls. Whether you interpret that XML as data or code depends entirely on the context; in a sense, all computer data is both data and code simultaneously. The distinction between data and code is a human convention, not a reality inherent to the computer.
Edit: I guess I should concede here that on the processor architecture level, there is often a very concrete distinction between code and data. Code is what gets fed through the processor core and changes the state of the machine. A typical architecture keeps the bits that are waiting for execution in a separate area of memory from other data which does not represent executable code. But this distinction quickly becomes blurred when you start talking about interpreters.