public void AddUpdateAppLicenseData(String appName, HashMap licCount){
		// Locate where to write, if you find a cell with the same name on the app that this one the update, if not, as you get an empty cell create it
		// For copying cells use copyRow() capable of copying full rows
		// A new app can be copied from the worksheet DataValidationValues rows 50-57
		
		try{
			
	          
	        XSSFSheet worksheet = book.getSheetAt(1); //Accesing the second tab
	        XSSFSheet dataValworksheet = book.getSheetAt(2); //Accesing the second tab
	          
	        Cell cell = null; // declare a Cell object
	        
	        int i=0;		       
	        boolean found = false;	        	        
	        
	        if(worksheet.getRow(13) != null){
		        cell = worksheet.getRow(13).getCell(0);   // Access the second cell in second row to update the value	          
		        String thisAppName = cell.getStringCellValue();	        
		        //System.out.println("Cell Contents: "+thisAppName);
		        
		        
		        for(i = 0 ; worksheet.getRow(13+(i*8))!=null ; i++){	        	
		        	cell = worksheet.getRow(13+(i*8)).getCell(0);   // Access the second cell in second row to update the value	          
			        thisAppName = cell.getStringCellValue();	        
			        //System.out.println("Cell Contents: "+thisAppName);
			        if(thisAppName.equals(appName)){
			        	// Update agent lic usage
			        	System.out.println("Updating "+appName);
			        	found=true;
			        	for(int k=0;k<8;k++){
			        		String type =  worksheet.getRow(13+(i*8)+k).getCell(3).getStringCellValue();
			        		Integer lics = (Integer)licCount.get(type);
			        		if(lics!=null)
			        			worksheet.getRow(13+(i*8)+k).getCell(4).setCellValue(lics);
			        	}
			        }
		        }
	        }
	        
	        if(!found){
	        	// Create a new entry
	        	System.out.println("Creating "+appName);	        	
	        	for(int j = 0; j< 8; j++){
	        		copyRow(book, dataValworksheet, 50+j, worksheet,(13+i*8)+j);	
	        		//worksheet.getRow(13+(i*8)+j).getCell(2).setCellValue("=B"+(13+(i*8)));
	        		worksheet.getRow(13+(i*8)+j).getCell(2).setCellFormula("B"+(14+(i*8)));
	        		String type =  worksheet.getRow(13+(i*8)+j).getCell(3).getStringCellValue();
	        		//System.out.println("type: "+type);
	        		Integer lics = (Integer)licCount.get(type);
	        		//System.out.println("ExcelManager - "+type+": "+lics+" "+licCount.size());
	        		if(lics!=null)
	        			worksheet.getRow(13+(i*8)+j).getCell(4).setCellValue(lics);
	        	}
	        	worksheet.getRow(13+(i*8)).getCell(0).setCellValue(appName);	        		        	
	        }
	        	        	        
		}catch(Exception e){
			e.printStackTrace();
		}
		
	}