Forum Discussion

NisHera's avatar
NisHera
Valued Contributor
5 years ago

Saving XL file gives disc full error

Hi,

When I' saving excel file in script gives "disck full" error.

have around 45GB file is just 75KB.

 

following is code...

function WriteExcelSheet(){
var todayD, hireDate ;
  var xlRange,rowCount,adjtTotal;
  var app = Sys.OleObject("Excel.Application");
  var book = app.Workbooks.Open(dtaFile);
  var sheet = book.Sheets('mySheet');
  todayD = aqDateTime.Today();
  hireDate = aqDateTime.AddDays(todayD, -85);
  Log.Message(aqConvert.DateTimeToStr(myDate));
  app.DisplayAlerts = false;
  app.Visible = true;
  //xlRange = app.Range('A1').Activate(); 
  
  rowCount = sheet.UsedRange.Rows.Count+1
  Log.Message('Number of rows = '+rowCount);

  for(j=11;j<rowCount;j++){
      app.Cells(j,10) = hireDate;
       }
  book.Save();
  Delay(7000);
  app.Quit();
}

the error fire at  book.Save();

 

This dosn't happen ervery time but after running long time randomly

5 Replies

  • tristaanogre's avatar
    tristaanogre
    Esteemed Contributor

    I'm wondering if "Disc Full" is not exactly the correct erro, even if that's what's being returned.  I tcould be permissions or access on the folder in question.

      • NisHera's avatar
        NisHera
        Valued Contributor

        not sure ..!

        there are security changes being happeing ..so could be it.