Skip to main content

All Questions

Tagged with
-1 votes
1 answer
44 views

Reading Excelsheets using openpyxl and Python

I have a folder with >1000 .xlsx-files containing data. I want to merge all that data into one sheet to process it further. Every .xlsx-file has 4 sheets called (Sheet 1, Sheet 2, Sheet 3 and Data)....
Cliff's user avatar
  • 79
-1 votes
2 answers
147 views

How to remove the duplicated values from the Excel using openpyxl

I'm trying to read the values of the columns in an excel sheet, and I want to skip the duplicated row by comparing it to the previous values of the column, and then I want to write the values in two ...
anu's user avatar
  • 35
1 vote
0 answers
393 views

How to merge empty cells in a pivot table using python

Ive a pivot table like this : table = pd.pivot_table( df, values="D", index=["A", "B"], columns=["C"], ...
Ravindra Reddy's user avatar
0 votes
1 answer
45 views

Excel workbook not closing Python Excel COM

The below code excel application is opening but not closing for some reason.Help me on this. import win32com.client as win32 Filepath = r"C:\New_Technicals\Excel_devp_Test\Model_Variable_Pah_v1....
Joseph Stalin Pillai's user avatar
0 votes
0 answers
61 views

how to calculate the nearest location to locations in excel sheet from another locations un another excel sheet using Lat and Long using python

i'm trying to calculate the nearest location from group of data to other group of data from excel sheets so far that's what I wrote, however I'm troubled with the below issue: File "C:\Users\...
Mohamed Hassan's user avatar
0 votes
1 answer
84 views

Excel COM API for reading the cell index using Python

I am wiritng a Python script using Excel COM APIs. I wanted to search for a string in a excell cell ,once found I want to return the cell index(like A2 or B3). what is the API I have to use for this.. ...
Joseph Stalin Pillai's user avatar
0 votes
1 answer
105 views

Write a list of lists into csv and having UnicodeEncodeError in python

I am converting an xlsm file to csv using the openpyxl library. I have the problem that when I try to pass the list of lists to the csv python returns the following error: Traceback (most recent call ...
Jordi Lazo's user avatar
1 vote
2 answers
276 views

Saving data in excel by cell rather than semi-colon with python

***Edit: I am originally saving the code to a .csv file but then later converting it to a .xlsx file. I am trying to change my code to save the values in separate cells verses in the same cell ...
user avatar
1 vote
1 answer
919 views

Pandas Freeze column names

I want to freeze the column names and like from large files when I'm scrolling down to have always the name of the columns. This is my script where I'm also creating the excel file with multiple ...
Champs's user avatar
  • 121
0 votes
1 answer
1k views

python showing import error while import openpyxl

while using python openpyxl , it is showing error , while openpyxl is updated . [root@localhost callflowv2]# python Python 2.7.5 (default, Nov 16 2020, 22:23:17) [GCC 4.8.5 20150623 (Red Hat 4.8.5-44)...
Abhishek's user avatar
  • 119
0 votes
1 answer
180 views

Saved dataframe as file in a directory does not work?

I tried to save a dataframe in a directory I created but It is not working. The directory and file are created but not on the same directory. I run a script exec.py which is supposed to used a script ...
emma's user avatar
  • 363
0 votes
2 answers
774 views

How to replace words in excel file using python

Is it possible to replace "firstword' with 'BBBBB' in all rows that contain 'firstword' ? Please, what is wrong in my code ? It would fiind the word I select from the most_occur1, and would print ...
madacmjtr's user avatar
0 votes
1 answer
2k views

python Get excel sheet names in array, and put it in condition

What I want is load excel sheet which is ("gx_projectid.xlsx") for my example. After then get the sheet names and put them in an array. After then if these sheet names ending with "_ID&...
BARIŞ DURAK's user avatar
0 votes
1 answer
3k views

Write Dataframe row to excel sheet using Pandas

How do I save returned row from dataframe into excel sheet? Story: Am working with large txt file (1.7M rows), containing postal codes for Canada. I created a dataframe, and extracted values I need ...
MuchStack's user avatar
  • 131
0 votes
1 answer
39 views

how to append in excel sheet and process further

Below program will open the excel file I saved in local, and open the url one by one in delay of 2 seconds. I need to change with item name instead of URL. Example: previous input is https://www....
Dilip Anand's user avatar

15 30 50 per page
1
2 3 4 5
21