Ik zou graag van alle klanten een export maken van gekochte producten bijvoorbeeld in excel, bijv. om via email te sturen enz. Probleem is dat je in filemaker nergens kunt aangeven dat de bestandsnaam van het te exporteren bestand gebaseerd moet zijn op een bepaald veld (bijv. klantcode).
ook plugins als Save-it (stuurt blijkbaar een textveld door), en Atfiler (plugin werkte niet correct)
Ik vond dan ergens deze oplossing. Vraag: is er geen betere oplossing?
mvg
Luk
If you're running this app on a Windows box you can do it with a batchfile
and a couple of fields. I did a similiar real estate app a few years ago.
The first version used a little qbasic app I wrote to parse out the one big
exported text file and save it in chunks... it didn't work very well. I did
the second version sorta like this...
create a batchfile called go.bat in the same dir as your *.fp5 file(s) like
this:
@echo off
copy %1 %2
cls
note the "@echo off" and the "cls" lines are to make the batcfile pretty and
close automatically. You may want to add those lines after you get
everything working.
I made each html document's name the property's mls number (text or number
Question
luk
Tja,
weer zoiets. (ik werk met windows)
Ik zou graag van alle klanten een export maken van gekochte producten bijvoorbeeld in excel, bijv. om via email te sturen enz. Probleem is dat je in filemaker nergens kunt aangeven dat de bestandsnaam van het te exporteren bestand gebaseerd moet zijn op een bepaald veld (bijv. klantcode).
ook plugins als Save-it (stuurt blijkbaar een textveld door), en Atfiler (plugin werkte niet correct)
Ik vond dan ergens deze oplossing. Vraag: is er geen betere oplossing?
mvg
Luk
If you're running this app on a Windows box you can do it with a batchfile
and a couple of fields. I did a similiar real estate app a few years ago.
The first version used a little qbasic app I wrote to parse out the one big
exported text file and save it in chunks... it didn't work very well. I did
the second version sorta like this...
create a batchfile called go.bat in the same dir as your *.fp5 file(s) like
this:
@echo off
copy %1 %2
cls
note the "@echo off" and the "cls" lines are to make the batcfile pretty and
close automatically. You may want to add those lines after you get
everything working.
I made each html document's name the property's mls number (text or number
field called mls_number)
create a calc field called go_calc like this:
"go.bat c:\yourdir\temp.html " & "c:\yourotherdir\"&mls_number&".html"
the resulting calc should look like this:
go.bat c:\yourdir\temp.html c:\yourotherdir\1234567.html
c:\yourdir\temp.html = the %1 variable
c:\yourotherdir\1234567.html = the %2 variable
Now create a script that basically does this....
sort
goto record first
set a global field (let's call it g)_conter) to 1
omit
find omited
export records to tab delimited file called temp.html
pause 1 second (give the computer time to settle down)
send message based on field value go_calc
loop
find all
goto record field value of g_counter
set field g_value = g_value + 1
omit
find omited
export records to tab delimited file called temp.html
pause 1 second
send message based on field value go_calc
end loop
I don't actually think this is how I did that loop since I haven't figured
1 answer to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.