Jump to content

Problem reading line with " (inch)


avguy
 Share

Recommended Posts

When I tried to read this line from a *.csv file

4" x 4" WIRE DUCT

I got,

"4"" x 4"" WIRE DUCT"

Would somebody please point out why?

Here is the script,

=====

$file = FileOpenDialog("Choose file...", $csv_dir ," (*.csv)", 4)

;$dir = @WorkingDir

;Test if file opened successfully

If @error = 1 Then

MsgBox(0, "WARNING", "NO File Has Been Selected!!!")

Exit

EndIf

;open text file to overwrite existing content if any

$textfile = FileOpen($script_dir & "\Fill_Block.scr", 2)

FileWrite($textfile, "")

;Check if file opened for writing OK

If $textfile = -1 Then

MsgBox(0, "Error", "Unable to open the BOM_Update.scr file.")

Exit

EndIf

FileWrite($textfile, ";This script was created at " & _NowTime() & " ON ")

FileWrite($textfile, _NOWDATE() & " By " & @UserName & @CRLF & ";;;;;;;;;;;;;;;;" & @CRLF)

For $i = 1 To ($Num_Row) Step 1

$ATT_row = FileReadLine($file, $i)

If @error = -1 Then ExitLoop

$Row_Content = StringSplit($ATT_Row, ',', 1)

Next

;Use this to test only

_ArrayDisplay( $Row_Content, "Attributes")

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...