Your question is not at all clear and may therefore be closed. What I believe, however, you are asking about is why the examples you have given are considered "incorrect" in formal writing.
The first point is that such usages occur all the time in spoken English. But a spoken language has many features, e.g., tone of voice, facial expression, the ability to interrupt when confused, etc., that do not exist in written language. Therefore, the possibility of confusion is much higher in written communication than in spoken communication. Furthermore, it is much easier socially to stop reading when something seems confusing or boring than it is to walk away from someone whose spoken words are boring or confusing.
I have heard so many times when criticizing an aspect of someone's writing "Well, the reader can understand what I meant." That is not necessarily true: the reader may not be able to decipher what was clear in the context of an unexpressed idea. And, in any case, the reader may not bother to engage in deciphering what appears to be gibberish. The job of the writer is to convey ideas accurately and concisely, not rely on the reader to engage in mind reading. The recommended rules of formal writing are designed with that purpose in mind, and they are much more stringent than the rules of speech.
The most common function of a participial phrase is to act as an adjective to describe a noun. "The woman, laughing at the confusion, never noticed that her purse was stolen." It is very clear that "laughing ..." relates to the woman. In English, we tend to keep nouns and their associated modifiers very close together.
In your examples, the participial phrases, called "dangling modifiers," do not relate to an adjacent noun and so are are hard to decipher. In the first example, it is possible to work out that the phrase probably refers to the "I" of the sentence (although it is not at all clear what the "I" is actually going to try to do). In the second example, the positioning of the modifying participial phrase seems to imply that the company is both female and amateurish.
With respect to the first sentence, I cannot figure out what was intended. With respect to the second, I can figure it out if I care enough to do so, but I may give up in disgust at the idea that companies are male or female and merely conclude that this writer is an idiot. To express the author's meaning clearly, write something like "At the company's meeting, he attacked her for amateurish programming."
Dangling modifiers (participial phrases not adjacent to the noun being modified) may confuse the reader, at least temporarily. Alternatively, they may indicate that the writer is confused. In either case, dangling modifiers impede quick and accurate communication. Avoid them.
EDIT: I notice that your question implies that the first example is bad writing whereas the second is good writing. Actually, both are examples of dangling modifiers and, in terms of recommended prose style, "incorrect." The second example can, however, be parsed to clarify what the author intended to say without a great deal of work. The first example may mean something, but only the gods may know what that meaning is. The dangling modifier in the first sentence does not convey any meaning whereas the dangling modifier in the second sentence just causes some brief, initial confusion. Thus, the first example is very bad, abut the second is bad only to a very minot degree. But why try to distinguish between severity of error when it can be avoided altogether.