Error using xlwt in maya

Okk guys i am making a small tool in maya for which i need to store my data in a database
I choose excel…
I found that there are python modules available for the purpose at http://www.python-excel.org

When i run my code… i am able to save my file on local drive
but when i change my path to a server address it gives me an error
Can anyone please help??

Also i would like to know if excel is the right tool to manage a database??
I basically need it to store small texts thats it…

Anways here is the script editor text from maya

from tempfile import TemporaryFile
from xlwt import Workbook
book = Workbook()
sheet1 = book.add_sheet('Sheet 1')
book.add_sheet('Sheet 2')
sheet1.write(0,0,'A1ss')
sheet1.write(0,1,'asasB1')
row1 = sheet1.row(1)
row1.write(0,'A2')
row1.write(1,'B2')
sheet1.col(0).width = 10000
sheet2 = book.get_sheet(1)
sheet2.row(0).write(0,'Sheet 2 A1')
sheet2.row(0).write(1,'Sheet 2 B1')
sheet2.flush_row_data()
sheet2.write(1,0,'Sheet 2 A3')
sheet2.col(0).width = 5000
sheet2.col(0).hidden = True
book.save('\\KANISHK-PC\Games\Fsdfdsf\dummy.xls')
# Error: IOError: file C:\Program Files\Autodesk\Maya2013\Python\lib\site-packages\xlwt\CompoundDoc.py line 261: 2 # 

Thank you
Kanishk Chouhan
www.pixel-architect.blogspot.com

Since it’s an IOError you could check whether you have write access at the remote deployment location or not. Just a shot in the dark…

We have made the best experience out of using mssql server + pyodbc and are using that for our in-house asset pipeline solution. It might be a bit heavyweight for your purpose but you could try it.

Ummm i guess thats nt the case… I have the read/write access on the folder…
Infact thats my pc’s location only…

Do i need to import some os module or add something in env path???
Am sorry am kinda new to this thing…

as written here your path is not escaped so it has bad characters in it. Try

book.save('\\\\KANISHK-PC\\Games\\Fsdfdsf\\dummy.xls')

or


book.save(r’\KANISHK-PC\Games\Fsdfdsf\dummy.xls’)

Heyyy man thanx a lot… it worked…
both the solutions are working absolutely fine :)))
thank u soo much once again…

Regards
Kanishk Chouhan
www.pixel-architect.blogspot.com