Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Submitting comma delimited data
Message
De
11/05/2011 14:24:25
 
 
À
11/05/2011 14:12:20
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Versions des environnements
Visual FoxPro:
VFP 9
Divers
Thread ID:
01510319
Message ID:
01510363
Vues:
54
>>>>>>>
>>>>>>>*Copy data from cursor to Excel file
>>>>>>>COPY TO ("C:\test\"+[bn]+m.bn+[T2.xls])
>>>>>>
>>>>>>you've got the endfor in the wrong place, it should be after the copy to
>>>>>
>>>>>
>>>>>I just tried that too and get the same result... I don't get it.
>>>>
>>>>
>>>>For debugging step through and see what NumberOfRecords is
>>>
>>>
>>>I didn't go through the debugger, but I did set NumberOfRecords to a messagebox and it shows as "1" after I hit export. It's just not seeing any other input.
>>>
>>>I don't know if this means anything, but I tried kind of combining your code with part of what Tore suggested:
>>>
>>>
NumberRecords = GETWORDCOUNT(m.bnin, ',')
>>>
>>>I added the ',' there and then it ignores the first number I type in and exports the second one after the comma. Basically it exported whatever the last record was, I tried three numbers at the same time and it only exported the third. I don't know if that's of any use for figuring this out but it's something different I noticed.
>>
>>what does m.bnin look like?
>>
>>If I do this in my command window I get 3 displayed:
>>
>>?GETWORDcount("1,2,3",",")
>>
>>which indicates 3 words have been found so that code should be OK
>
>Do you mean what do the numbers I'm trying to enter look like, or what is the program actually seeing? Probably what the program is seeing, I'm not sure how to debug it the way it's set up, there is a ton of code for a bunch of other pages in here and this is just one function in the whole thing. I'll see if I can figure it out.

You need to work out what the program is seeing. Set a breakpoint on the line of code where you need the program to stop, by double clicking in the grey border of the program to the left of the line (a red dot will appear and the debug window will open) and then run the program, it will stop at that point and then you'll be able to hover your mouse over the variables and see what values they have. Alternatively add in SET STEP ON to the code.
Frank.

Frank Cazabon
Samaan Systems Ltd.
www.samaansystems.com
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform