>Hey John,
> I'm having problems trying to get my putfile to fire off. When I step through the following code, I see that the value I'm sending as a result of putfile command line is capturing the entire path. Is my syntax incorrect?
>
>IF MESSAGEBOX ("Do you wish to save this record?" , 4 + 32 + 0, "Save CDC Id" ) = 6
> G_TmpFile = PUTFILE('Save CDC Id As..',G_TmpFile, 'Txt;Dbf;Xls')
> SET STEP ON
> DO CASE
> CASE G_TmpFile = G_TmpFile + '.Xls'
> COPY TO G_TmpFile TYPE XLS
> CASE G_TmpFile = G_TmpFile + '.Dbf'
> COPY TO G_TmpFile TYPE FOX2X
> ENDCASE
>ELSE
> ThisForm.Btn_Create.VISIBLE = .T.
>ENDIF
Are you sure the " G_TmpFile = G_TmpFile + '.Xls'" expression will ever evaluate to .t.? You may be better off with FoxTools function JustExt:
Case lower(justext(g_TmpFile))="xls"