Skip to Content
เมนู
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
คำถามนี้ถูกตั้งค่าสถานะ
2 ตอบกลับ
2862 มุมมอง

Hi everyone, I have a problem with code.

In this part:

qty_position = scan_barcode.find('-')

I need replace symbol - with symbol

qty_position = scan_barcode.find(''')

the problem is that with this new symbol, code after change like if is it:

""" Text """

How I can do?

Thanks very much

อวตาร
ละทิ้ง
ผู้เขียน คำตอบที่ดีที่สุด

Thanks Hassan, it work!

Can I ask an other question, If I need:

qty_position = scan_barcode.find("'" or "*")

it's possible to do this? What's the correct code?

Thanks

อวตาร
ละทิ้ง

qty_position = scan_barcode.replace("'", "").replace("*","")

Can you make my answer as solved?

ผู้เขียน

Hi Hassan, thanks for you help! I would like make your answer as solved, but I can not because forum need 5 Karma for make it, and I have not its. I don't know how I can do

คำตอบที่ดีที่สุด
qty_position = scan_barcode.replace("-", "'")
อวตาร
ละทิ้ง
Related Posts ตอบกลับ มุมมอง กิจกรรม
2
ก.ย. 24
1453
2
ส.ค. 25
2394
1
ก.ค. 25
898
1
ส.ค. 25
1151
0
พ.ค. 25
1339