← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #263844]: how to read single row from csv file using python in sikuli

 

Question #263844 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/263844

RaiMan posted a new comment:
this is your current version

import csv

original = file('D:\\Sikuli\\example1.csv', 'rU')

reader = csv.reader(original)

# List of Data
#Presedence, Sno, STP-testcaseno, Test_id, Scenario, Simulator, Comport
= []

count = 0

def southparkinfo():
   for row in reader:
       count += 1
       if Presedence == 1:
           row[0] = Presedence
           print row[0] # Presedence (ex. 0 or 1)
           print "----------------"
       else :
           row[6] = Simulator
           print row[6] # Simulator (ex. Simplex or Ifen)
       return

#reader.close()

-- 
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.