Welcome! Log In Create A New Profile

Advanced

[WD12] WDModFic and CS

Posted by Louis Verbraak 
Louis Verbraak
[WD12] WDModFic and CS
June 10, 2009 02:08PM
Hello to you all,

I use WDModFic to change the structue of my files. This works well in HF Classic mode, but I can't get it working in HF C/S. In my database I've subfolders for each administration and I want to change the structure of the files of one administration at a time. I use the following statement:

lsConversie=""C:\WinDev 12\Programs\WDModfic.exe" /WDD="D:\Vemasoft\Exe\Vemasoft.WDD" /SERVER=Administrator:vemasofthfcs@Server01:4900/Vemasoft /apply"
lbGeopend=ExeRun(lsConversie,exeActive,exeWait)

lbGeopend returns TRUE, but when I look at my files nothing has changed!
I've tried to use the parameter /DIR=".\adm0001", but that didn't work either.

Can anybody tell me what I'm doing wrong?
Aad Gouka
Re: [WD12] WDModFic and CS
June 10, 2009 03:36PM
Hello Louis,

This is the way I did it and it's working fine with the only difference -subdir parameter. In my case WDModfic is changing all the subdirs as well.

Maybe you can compare my version against yours.


IF gbClientServer = 0
ExeRun("wdmodfic.exe -subdir -report -nobackup /US /WDD="+fCurrentDir + "\Winvve.WDD /DIR="+DriveIni+"\winvve",exeMaximize,exeWait)
ELSE
ExeRun("wdmodfic.exe -subdir -report -nobackup /US /WDD="+fCurrentDir + "\Winvve.WDD /SERVER=Admin:@"+gsServer+"/winvve",exeMaximize,exeWait)
END



Good luck.

Regards,

Aad
Louis Verbraak
Re: [WD12] WDModFic and CS
June 10, 2009 04:16PM
Hello Aad,

Thanks for your suggestion. Because of the -report-parameter I get an answer which I didn't expect: 'No files to modify'! I'm quite sure there must be a differrence between my files and the analysis.

Perhaps you can tell me where I make a thinking mistake ('denkfout' for the dutch). I wonder where the original analysis of the created files is written. Because when I import the files in CS, I need to give the analysis-file. Is this file imported in the CS or isn't it nessecary anymore? In my programdirectory there still is the (new) wdd-file.

Thanks in advance.
Louis Verbraak
Re: [WD12] WDModFic and CS
June 10, 2009 04:40PM
Hello,

I changed my code so the wizard automatically started (-wizard-parameter). Then the wizard indeed started and by default he didn't see the files of my database to change. In the wizard I manually connected to my database and then he saw the changed files.

Perhaps this can give anyone a clue to an answer?

Thanks again.
Aad Gouka
Re: [WD12] WDModFic and CS
June 10, 2009 05:47PM
Hi Louis,

I use the .wdd from the projectdir and copy it to the programmap of my application. I also copy WDModfic into the programmap of the users computer. As you can see I don't use any paths other then the fCurrentdir.

Did you change the standard Admin password in Administrator ??


Rgrds, Aad

Louis Verbraak
Re: [WD12] WDModFic and CS
June 10, 2009 06:05PM
Hello Add,

I do the same concerning the wdd-file and yes I've changed the name of the admin.
I can't get it right by automatic modification, only when I use the wizard?!
Arie
Re: [WD12] WDModFic and CS
June 10, 2009 08:58PM
Louis,
what does /apply do?
I don't see it in the help.
I'm using wdmodfic from within my software without any problems. Like you do, using commandline parameters and/or via the wizard (whatever the user wants).
BTW: I'm using HFCS, but NO subdir.

IF bAuto THEN
// Full name of the WDD with its path (here, in the same directory)
FullWddName is string = CompleteDir(fExeDir())+"Easy4U.wdd"
IF NOT fFileExist(FullWddName) THEN
FullWddName = fSelect("", FullWddName, "Select analysis", "Analysis"+TAB+"*.wdd", "wdd", fselOpen+fselExist)
END

// No file selected
IF FullWddName = "" THEN
RETURN
END

sCommandLine = """" + WdModficExe + """" + " /US" + " /WDD=""" + FullWddName + """" + "/SERVER=" + sUser + sPassword + "@" + HFServerAddress +"/" + DatabaseName + " /REPORT /ERROR"
ELSE
sCommandLine = """" + WdModficExe + """" + " /US" + " /WIZARD"
END

Arie
Louis Verbraak
Re: [WD12] WDModFic and CS
June 10, 2009 11:35PM
Hello Arie,

I didn't see any difference in using /apply or not.

I got it from the help:

Quote
Using WDModFic for a Hyper File Client/Server database

// Parameters for the automatic file modification
// Directory containing WDModFic
WDModifDirectory is string = "C:\Program Files\WinDev 11\Programs\"
// Full name of the WDD with its path (here, in the same directory)
FullWddName is string = CompleteDir(fExeDir())+"MyAnalysis.wdd"
// User name and password on the Hyper File server
// (with rights for modifying the file structure)
User is string = "guest"
Password is string = ""
// IP address or DNS name of the machine that hosts the Hyper File server
AddressOrHFServerName is string = "MachineName"
// Port of the Hyper File server
HFServerPortNum is int = 4900
// Name of the database where
// the files to modify are located
DatabaseName is string = "MyAnalysis"
CommandLine is string
// Build the command line
// Remove /apply to not get
// a dialog box at the end
CommandLine = StringBuild([
"%1WDModFic.exe" /WDD="%2" /SERVER=%3:%4@%5:%6/%7 /apply

,CompleteDir(WDModifDirectory
FullWddName,User,...
Password,AddressOrHFServerName,...
HFServerPortNum,DatabaseName)

// For test purposes the command line can be displayed here
// in order to perform a visual check
// //Info(sCommandLine)
// Start the automatic modification while waiting for the end
IF NOT ExeRun(CommandLine,exeActive,exeWait) THEN
// Launch failure, display error
Error("Unable to run the automatic modification"+...
" data: ",ErrorInfo(),...
"Command line used: ",CommandLine)
ELSE
//Automatic modification performed
END]
Stefan Bentvelsen
Re: [WD12] WDModFic and CS
June 11, 2009 08:53AM
Hi Louis,

have you also copied the files 'WD120Util.wdk' end 'WDMod120.dll' to your programdirectory ?
At first, that was the problem in my case when I start to use WDModfic.exe from code in my program.
Arie
Re: [WD12] WDModFic and CS
June 11, 2009 09:01AM
See Jimbo's post on the SaaS subject, regarding subdir and some other issues with wdmodfic and the rep-file.
[forum.mysnip.de]


Arie



Edited 1 time(s). Last edit at 06/11/2009 09:19AM by Jimbo.
Louis Verbraak
Re: [WD12] WDModFic and CS
June 11, 2009 10:02AM
Hello Stefan,

Yes I have. Thanks.
Louis Verbraak
Re: [WD12] WDModFic and CS
June 11, 2009 10:04AM
Hello Arie,

I've seen that post already and I don't use a REP-file. Thanks.
Jimbo
Re: [WD12] WDModFic and CS
June 11, 2009 10:22AM
Quote
Louis Verbraak
Hello Arie,

I've seen that post already and I don't use a REP-file. Thanks.

Kind regards,

Louis.

Hi Louis, I don't use a REP-files too since 2006 because of the described inconsistencies. Whenever there's time, I'll re-test the old problems and try to find out whether these problems still exist, new ones have been added, or, wonder of wonders, some of them were fixed in the meantime.

The SaaS-issue had been subdirectories to a single database. In 2006, I had to accept that it is impossible to use several subdirectories containing identical sets of datafiles corresponding to the same analysis - I rather had to switch to a separate database for each set of files.

Kind regards, Guenter
Louis Verbraak
Re: [WD12] WDModFic and CS
June 11, 2009 11:02AM
Hello Guenter,

For now I stay with my structure of subdirectories in one database. I'll try to find a workaround for the datamodification (I understood that Stefan copies the files to another directory) or block that routine for CS-users.

Is it possible to connect the CS-files in the Classic way (HChangeDir/HChangeName) while the server is running?
Jimbo
Re: [WD12] WDModFic and CS
June 11, 2009 11:42AM
Quote
Louis Verbraak
Hello Guenter,

For now I stay with my structure of subdirectories in one database. I'll try to find a workaround for the datamodification (I understood that Stefan copies the files to another directory) or block that routine for CS-users.

Is it possible to connect the CS-files in the Classic way (HChangeDir/HChangeName) while the server is running?

Kind regards,

Louis.

Hi Louis, I'd suspect that troubles are waiting in the background when choosing such an approach (rights, users). Moreover, on some servers (e.g. Windows 2005 / 2008 Small Business) you will not be able to do a ChangeDir(..) from a client computer. Connection only by LDAP or by IP. I'd recommend to HCopyFile(..) the files to a local directory and do a restructure there and copy the files back to the server. That has BIG disadvantages because WDMODFIC will 1 - add /change / remove sets of stored procedures 2 - will take care of the integrity.fic file in database subdirectory _system 3 - will add / change / remove links. You could do that by H-commands too .. but, just to add my 2 cents: don't repair a bad design by further adding possible future trouble. Drop the current subdir-design and invest into a clear multi-database design as I did.
Kind regards, Guenter
Louis Verbraak
Re: [WD12] WDModFic and CS
June 11, 2009 11:52AM
Hello Guenter,

Thanks for your help. In the mean time I've tried to use WDModFic with the classis-way and this returns errors because the files are in use. For now I block the automatic dataconversion.

For everybody who answered: THANKS for your time.
Author:

Your Email:


Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: