Dammit! :-)
Marcelo Palladino Brasil Twitter: @ProgrammerHead Blog (pt-BR): http://programmerhead.wordpress.com
Dammit! :-)
Marcelo Palladino Brasil Twitter: @ProgrammerHead Blog (pt-BR): http://programmerhead.wordpress.com
makumazan84, when PIEBALDconsult talked about blood, I thought that exact scene you described. Kill Bill is a masterpiece ... and the code, of a very particular way, it is also. As you get dizzy, I think in Visual Studio that could be solved with several sections #region. :cool:
Marcelo Palladino Brasil
hahaha, this is not my code, but you gave a good idea. Can I even do versioning of my sources here...
Marcelo Palladino Brasil
Hey, bleedingfingers, had not thought of this ... but now that you said, I was testing. I was testing ... :thumbsup:
Marcelo Palladino Brasil
You're right, PIEBALDconsult. Excuse me for this, okay? (Sorry, guys!) I wanted to give a dramatic effect and, as a big fan of Tarantino, exaggerate the amount of blood. :) I have this code posted on a blog on wordpress. You think I should edit my post and replace the entire code for a link pointing to the post in wordpress?
Marcelo Palladino Brasil
You got my points, Rob. :-D And Yes, it's a real life horror!
Marcelo Palladino Brasil
This code is based on true and real CRITICAL application. **In memory
private void ProcessaNota(TextReader txt, string cDestino)
{
string baseDir = InfoApp.PastaSchemas() + "\\nfe_v1.10.xsd";
if (!File.Exists(baseDir))
{
this.cMensagemErro += "Arquivo: " + baseDir +
" não encontrado" + Environment.NewLine;
return;
}
DataSet dsNfe = new DataSet();
dsNfe.ReadXmlSchema(baseDir);
dsNfe.EnforceConstraints = false;
DataRow dremit = dsNfe.Tables\["emit"\].NewRow();
DataRow drdest = dsNfe.Tables\["dest"\].NewRow();
DataRow drPISOutr = null;
DataRow drPISST = null;
DataRow drCOFINSOutr = null;
DataRow drCOFINSST = null;
DataRow drtransporta = null;
DataRow drIPITrib = null;
DataRow drVol = null;
string idprod = "";
int iControle = 1;
int nElementos;
int iLeitura;
string\[\] dados;
Int64 iTmp = 0;
bool vNovaNota = false;
bool vTiraxFant = false;
bool transpAdd = false;
this.nNF = 0;
int DIid = 0;
int prodID = 0;
int idcomb = 0;
int volid = 0;
int indadicid = 0;
while (cLinhaTXT != null)
{
cLinhaTXT = this.ConvertToOEM(this.cLinhaTXT);
//cLinhaTXT += "!@#$%^&\*()\_+";
bool reLe = false;
for (int x = 0; x < cLinhaTXT.Length - 1; ++x)
if (/\*char.IsSymbol(cLinhaTXT, x) ||\*/ char.IsControl(cLinhaTXT, x))
{
this.cMensagemErro += "Linha \[" + this.iLinhaLida.ToString() +
"\] coluna \[" + (x + 1).ToString() + "\] contem o caracter \[" +
cLinhaTXT.Substring(x, 1) + "\] que não é permitido" +
Environment.NewLine;
//this.cMensagemErro += "\\t"+cLinhaTXT + Environment.NewLine;
cLinhaTXT = txt.ReadLine();
iLinhaLida++;
reLe = true;
break;
}
if (reLe)
continue;
dados = cLinhaTXT.Split('|');
dados\[0\] = dados\[0\].ToUpper();
nElementos = dados.GetLength(0) - 1;
for (int n = 0; n < nElementos; ++n)
dados\[n\] = dados\[n\].Trim();
#region -- Segmentos
switch (dados\[0\])
{
case "NOTAFISCAL":
case "NOTA FISCAL":
break;
case "A":
#region -- A
if (this.nNF > 0)
{**
Hi! Personal, I need an council for an application that I am developing here in Brazil. In this application I have the need to create a type of server of instant messages, only that based on business rules. For instance, imagine that an user parameter the software to accept only sale requests whose profit is superior to 20%, and in case it is inferior, somebody (a list of users) it should authorize the smaller profit. I already saw like this some things, based on TCP and formatted strings. Wants to say, this is not very elegant.... I was analyzing a little the entails P2P of WCF and I think a good road...., but I admit that am not sure. Does anybody have some idea on this? Thank´s advance,
Marcelo Palladino Brazil
Well coming to the club! Once I wrote for Steve McConnell and he said something as: Boy, would I like to help, but don't you know anybody what can write for you? :laugh: Marcelo Palladino
Well coming to the club! :-D Marcelo Palladino
Hi, In the last twelve months, together with a team of 6 people, I developed a software that will assist it a base of customers that our company. They are approximately 400 customers with characteristics very different from operation and activity branch. My problem now is to try to organize an outline of distribution of this software. I admit that I personally don't have any practical experience in this subject and I am with some fear of turning the very bureaucratic or inefficient process. Some characteristics that can help to understand the problem: Windows Forms Application 32 binary (among executables and dlls) Database objects (triggers, constraints, udfs, procedures...) The one that I already have in mind is that I will probably have two versions. A stable one (that will just receive corrections) and an unstable one (where they will happen the corrections and new implementations). Now, how to do this? Will it be that I will have to maintain two trees of code source? Obs: I use StarTeam to control the versions of the files. Does anybody have some experience, some book or site that I can aid myself to plan this outline? Thank´s in advance, Marcelo Palladino
"Visual Studio 2005 Team System" This will be their most beautiful butterfly of all. I use Star Team of Borland, but for the that I walked sells thereabout... (there migration of the environment production comes again!) Marcelo Palladino -My headboard lately- Code Complete, Second Edition[^] Writing Secure Code, Second Edition[^] The Da Vinci Code[^] Angels & Demons[^]
To :bob: or not to :bob:...
Don't understand each other badly, I don't speak this for you, it is a comment on which I see everyday. That badly there is in a person to say (literal or not) that is better than the other ones in some thing. This happens in a lot of areas, but it seems that in ours when somebody makes that is very worse. I felt never offended reading Raymond's blog but I know several people that don't read because they find him arrogant... Marcelo Palladino
In this subject the romantic side also exists. People that think to be changing the world for better. To share knowledge is a thing (open) to give the software free is totally other different (free). For instance, a software that controls the safety of a nuclear power station difficultly it will be free, but it can, and perhaps, depending on the country, owe, to be open. There is not evil in this, since to be open (in a restricted circle) it turns more safer. Forum is this: The THING begins a race horse and it finishes as a camel with two heads and six paws. Marcelo Palladino
dnh wrote: What my post was about, is that linux's UI/API/whatever is appereantly a reason to smile and kiss my WinXP CD. Man, I don't get to sleep more after imagining you kissing a WinXP CD. :-D:-D:-D Marcelo Palladino
Rocky Moore wrote: Linux is getting much closer to a Windows replacement. There are still a few things you have to do without though. They do not have some applications such as Quicken or Photoshop. While you might find close products, they are not replacements yet. DRM for online content is another area. I do not see hollywood trusting Linux for quite some time. Another point to consider is the ENORMOUS POWER of research and development in Microsoft. Only to mention some examples: Avalon, Indigo, WinFS, etc, etc. A lot people can think are just appeals of a good marketing but it is not true. Indigo, it should break valid paradigms for many years. A true revolution (leaning in OS, integrated in fact). highest, I am fan of Linux, use home, in projects (eventual) but to accompany the redmond guys is very complicated, it is to be always a step behind. (that is only a opinion) Marcelo Palladino
Perhaps this is a stupid question, but I sought plenty and I didn't get to find. Imagine that there is an enumeration as the one that proceeds:
[Flags ()]
public enum AnyOptions
{
Option1 = 1,
Option2 = 2,
Option3 = 4
}
Now there is a property in a specialization of System.Windows.Forms.TextBox
public class MyCustomTextBox: System.Windows.Forms.TextBox
{
private AnyOptions options = AnyOptions.Option1;
\[Browsable(true)\] //this is the point!!
public AnyOptions Options
{
get {return this.options;}
set {this.options = value;}
}
}
Question: As I do for this property to have a "normal" behavior in the properties window. I imagine that it is some editor type, I don´t know. Thanks in advance, Marcelo Palladino Brazil
Don't I know I understood if well the problem, but and if you force the shot of the event?
protected override void OnResize(EventArgs e)
{
base.OnResize (e);
using (Graphics g = this.CreateGraphics())
{
this.OnPaint(new PaintEventArgs(g,
this.ClientRectangle));
}
}
protected override void OnMove(EventArgs e)
{
base.OnMove (e);
using (Graphics g = this.CreateGraphics())
{
this.OnPaint(new PaintEventArgs(g,
this.ClientRectangle));
}
}
Marcelo Palladino Brazil
Friday: Worked up to 2 of the dawn. Saturday, 9:20hs of the morning: Correction of bugs "created" during the previous dawn. Executive summary: Most of my bugs is created after at 22:00hs o'clock. :zzz::zzz::zzz: Good weekend!!!! Returning to the coffee... wants to say... code. Marcelo Palladino Brazil