top button
Flag Notify
    Connect to us
      Facebook Login
      Site Registration Why to Join

Facebook Login
Site Registration

In Python, How to extract the Object and print all the attributes?

0 votes
46 views

I need to print the Dictionary in a detailed way.

Current When am print the dictionary am getting like below.

<Details.Value: object at 0x0000027062245160>
posted Jan 3 by Nikita Sehgal

Share this question
Facebook Share Button Twitter Share Button LinkedIn Share Button

1 Answer

0 votes

Using __dict__ you can print with all attributes.

Example:

employeeList = {'name':'John','age':28}

print (employeeList .__dict__)
answer Jan 3 by Mishthy Mukherjee
Similar Questions
+3 votes

I am trying to count the number of files in a folder with python script but not getting the appropriate script. In which I can change the path and can find out the count of other folder files.

It doesn't matter for me how long the script is but need the clear script and it would be better if you can explain it also.

+3 votes

I have the following script however when the clipboard contents are greek letters it fails to print them right.
I have used all posible encoding for greek letters including utf8 but to no avail so i just stay with latin1.

Can you suggest a solution?

Here is the script:

import win32clipboard
win32clipboard.OpenClipboard()
data = win32clipboard.GetClipboardData()
win32clipboard.CloseClipboard()
data = data.decode('latin1')
send = 'ccc|=:='+data
print data
print send 
Contact Us
+91 9880187415
sales@queryhome.net
support@queryhome.net
#280, 3rd floor, 5th Main
6th Sector, HSR Layout
Bangalore-560102
Karnataka INDIA.
QUERY HOME
...