avpatil
11th June 2005, 04:23
Hi,
I have a requirement where I need to create a file where fields are enclies in double quotes. If I have field say item description and it contains the quote I need the field in file like this

item description- 1" X 2 surface
in field I needed like this
"1""X2 surface"

Is there a way to add a quote in fron of the quote.

Thanks

Arvind

Hitesh Shah
11th June 2005, 16:18
If I understand correctly, u simply need the double quote in a string . If that be the case u can use extra double quotes to include " in the string.

Following illustration will explain this clearly.


string var1(6)
var1 = """""AA"""
|var1 will have the value ""AA"


Think this is what u need.

avpatil
11th June 2005, 17:21
Hi Hitesh,
My requirment is that wherever the quote in the screen, I needed to add one more quote to it e.g

String1 1"X2" screw

the string should look like-
1""X2"" screw

Arvind

Hitesh Shah
11th June 2005, 17:59
Assuming 1 double quote in the string u can use the following statement. U may loop for repeating double quotes until u finish all double quotes in the string.

string1 = string1(1;pos(string1,"""")-1) & """" & string1(pos(string1,""""))

avpatil
11th June 2005, 18:04
Hitesh,
I already did my own function that will add the double quote before the quote, buy looping a for loop. I was trying to see if there is some standard Baan function that may be avialble. This required esp when generating csv files.

Arvind