title: error C2220: warning treated as error - no 'object' file generated
body: <p>I have below class</p>
  
  <pre><code>class Cdata12Mnt
  {
  public:
      char IOBname[ID1_IOB_PIOTSUP-ID1_IOB_TOP][BOADNAM_MAX + 4];
      char ExIOBname[ID1_MAX_INF-ID1_EXIOB_U1TOP][BOADNAM_MAX + 4];
      char cflpath[256];
      char basetext[256];
      UINT database[ID1_MAX_INF];
      int State;
  
  public:
      char SelectPath[256];
  
  public:
      int GetIOBName(int slt,char *Name);
      Cdata12Mnt(char *SelectPath);
      virtual ~Cdata12Mnt();
      int     GetValue(int id);
      int     GetState() { return State; }
  };
  </code></pre>
  
  <p>And I have function as below</p>
  
  <pre><code>Cdata12Mnt::Cdata12Mnt(char *SelectPath)
  {
      SCTReg  reg;
      char    buf[256], *cpnt, *npnt, *bpnt1, *bpnt2;
      char    *startcode[] = {"CNTL_CODE ","SEGMENT "};
      char    *stopcode    = {"END_CNTL_CODE "};
      FILE    *fp;
      int     ii, infl;
  
      State = 0;
  
      for (ii = 0; ii &lt; (ID1_IOB_PIOTSUP - ID1_IOB_TOP); ii++) {
          strcpy(IOBname[ii], "");
      }
  
      for (ii = 0; ii &lt; (ID1_MAX_INF-ID1_EXIOB_U1TOP); ii++) {
          **strcpy(ExIOBname[ii], "");**
      }
  
      sprintf(cflpath, "%s\\%s", SelectPath, CDATAFL);
  
      if ((fp = fopen(cflpath,"r"))!=NULL) {
          for (ii = 0, infl = 0; fgets(buf, 256, fp) != NULL;) {
              if (infl == 0 &amp;&amp; strncmp(buf, startcode[0], strlen(startcode[0])) == 0) {
                  if ((cpnt = strchr(&amp;buf[strlen(startcode[0])],*startcode[1])) != NULL) {
                      if (strncmp(cpnt,startcode[1], strlen(startcode[1])) == 0) {
                          infl = 1;
                          continue;
                      }
                  }
              }
  
              if (infl == 0) {
                  continue;
              }
  
              if (strncmp(buf,stopcode,strlen(stopcode))==0) {
                  if (ii == ID1_EXIOB_U1TOP) {
                      for (int nDataNumber = ii; nDataNumber &lt; ID1_MAX_INF; nDataNumber++) {
                          database[nDataNumber] = 0;
                      }
                  }
  
                  infl = 0;
                  continue;
              }
  
              if (strncmp(&amp;buf[14], " DD ", 4) == 0) {
                  if ((cpnt=strchr(buf, ';')) != NULL) {
                      *cpnt = '\0';
                  }
  
                  if (ii &gt;= ID1_IOB_TOP &amp;&amp; ii &lt; ID1_IOB_PIOTSUP) {
                      if ((bpnt1 = strchr(cpnt + 1,'(')) != NULL &amp;&amp; (bpnt2=strchr(cpnt + 1,')'))!=NULL &amp;&amp; bpnt1 &lt; bpnt2) {
                          *bpnt2 = '\0';
                          *(bpnt1 + BOADNAM_MAX + 1) = '\0';
                          strcpy(IOBname[ii-ID1_IOB_TOP], bpnt1 + 1);
                      }
                  }
  
                  if (ii &gt;= ID1_EXIOB_U1TOP &amp;&amp; ii &lt; ID1_MAX_INF) {
                      if ((bpnt1 = strchr(cpnt + 1, '(')) != NULL &amp;&amp; (bpnt2=strchr(cpnt+1,')'))!=NULL &amp;&amp; bpnt1 &lt; bpnt2) {
                              *bpnt2='\0';
                              *(bpnt1+BOADNAM_MAX+1)='\0';
                              strcpy(ExIOBname[ii-ID1_EXIOB_U1TOP], bpnt1 + 1);
                      }
                  }
  
                  for (cpnt = &amp;buf[18]; cpnt != NULL;) {
                      if ((npnt=strchr(cpnt, ',')) != NULL)
                          *npnt='\0';
                  }
  
                  if (strchr(cpnt,'H')!=NULL) {
                      sscanf(cpnt,"%XH",&amp;database[ii]);
                  } else {
                      database[ii]=atoi(cpnt);
                  }
  
                  ii++;
                  cpnt = npnt;
  
                  if (cpnt != NULL) {
                      cpnt++;
                  }
              }
          }
      }
  
      fclose(fp);
  } else {
      State=-1;
  }
  </code></pre>
  
  <p>When I compile this function in Visual studio 2008, it gives me error at <code>strcpy(IOBname[ii],"");</code> as below</p>
  
  <blockquote>
    <p>error C2220: warning treated as error - no 'object' file generated</p>
  </blockquote>
  
  <p>How to fix this error?</p>