Thursday, 30 April 2015

Master detail form - no records shown in detail form

I re-blog an older post today as I just came across the same issue again but I had forgotten about it. I wasted some time testing all sorts of things before I looked it up on the web finding my own posting!

When you create a Master Detail form Map needs to insert some records into certain system tables. Unfortunately with Map 2013 not all of those entries are created properly. You need to add missing ones manually to table TB_GN_DIALOG. Look up the record for your form and check the columns "detail_fieldname" and "master_fieldname". They need to refer to the FID columns of the tables involved.

You can navigate to the record in TB_GN_DIALOG more easily if you:
- open the master-detail form you need to rectify in preview mode in Map-Administrator
- click into the input text box of the detail form (just above the tool-bar)
- press Ctrl+D

The form for TB_GN_DIALOG will open and display the record you need to check/edit.

TB_GN_DIALOG - detail_fieldname is empty

Master-Detail form now functiong properly after fxing entries in TB_GN_DIALOG

Map 2103, SP2





Tuesday, 28 April 2015

AutoCAD Mechanical - Fatal error: unable to load the modeller dlls

I created a network deployment for Autodesk Factory Design Suite 2015. The deployment was installed on the user machine and a virtual machine as well. In both cases Mechanical crashed with error message "Fatal error: unable to load the modeller dlls" when trying to resize a circle. The issue did not occur with AutoCAD or AutoCAD Architecture.

We tried to find the reason and did perform several tests - but to no avail. Finally I re-created the deployment and reinstalled. The issue does not occur anymore. So - we spent quite some time on troubleshooting instead of just recreating the deployment....

Factory Design Suite 2015 

Can't see deleted files in Bin?

I just came across this. I had some files deleted early this morning and then needed to get some of them back - but for a strange reason my Bin was empty. 
As it turns out the issue is due to a bug in Windows 7. I have a codemeter usb stick plugged in and the company behind it provides a download link:

www.wibu.com/nc/faq-codemeter/question/single/why-are-deleted-files-no-longer-display-in-the-recycle-bin-if-a-cmdongle-is-plugged-in-139.html

which points to

http://support.microsoft.com/kb/2677246/en-us

"Assume that you connect a removable hard disk drive to a computer that is running Windows 7 or Windows Server 2008 R2. The removable hard disk drive is read-only and does not contain a Recycle Bin. In this situation, when you open the Recycle Bin on the desktop to restore some files, no deleted files are displayed in the Recycle Bin."

If you cannot install the hotfix - for Codemeter another solution exists by changing the codemeter configuration. 

Wednesday, 22 April 2015

Crystal Reports Designer "Save as" to Enterprise fails

We have already migrated quite a view reports from an older CR release to CR 2011 just by opening the report in CR Designer and saving it to Enterprise server.

Suddenly - with some reports - saving reports failed with error message : "internal error report application server failed".

Solution - activate "no printer" option Page Setup as described here:

http://scn.sap.com/thread/3433032



Tuesday, 31 March 2015

AIMS / MapGuide backup batch script

I used to create backups for the repository files and the library - by running the batch files provided by MapGuide manually and using the Admin web interface for creating a package. To simplify the process I have written one batch file for the whole procedure. As I'm not familiar with batch file scripting there is probably lots of space for improvements left. Here are some details:


1. make package 
I modified the existing "makepackage.php" script (...\Autodesk Infrastructure Web Server Extension 2013\www\mapadmin) in order to run it from command line. It needs some configuration parameters such as path to webconfig.ini and the Administrator's credentials (MapGuide Admin).

2. repository backup batch files
The backup scripts provided by MapGuide need a little modification - I added an "exit" at the end of each of the files I use and renamed them as well (kept the originals).

 ...  
 echo.  
 php -n RepositoryAdmin.php -c Restore -i "%cd%\..\BackupRepositories\Library\LastColdBackup" -o "%cd%\..\Repositories\Library"  
 echo.  
 exit  

  
3. batch script 
One batch script is needed to run all other scripts, for shutting down and restarting MapGuide service and for copying the backed up files to a different drive.

To run other batch files use:

 ...  
 start /wait call %batch_file_backup%  
 if ERRORLEVEL 1 goto error_start  
 ...  


This will run another batch file and wait until the batch file has finished. If the batch file does not finish succesfully you can catch an error code. A modification of the original batch files provided by Mapguide is required to get this to work - see above.

One click and files are backed up:


backup batch file in action

Script files are available here.

Install:

1) Copy files to "..\Autodesk Infrastructure Map Server\RepositoryAdmin" folder.
2) check and modify settings in "makepackagescript.php"
3) check and modify settings in "AIMS_backup.bat"
4) run "AIMS_backup.bat"

This should work for AIMS 2013 and the corresponding MGOS version.

Friday, 20 March 2015

Oracle Trigger - display debug information

Just for my own reference:

(1) within trigger use DBMS_OUTPUT.PUT_LINE, e.g.


 DBMS_OUTPUT.PUT_LINE(REC_INSP.FID || ' ' || REC_INSP.FID_BAUM);  

to display text in SQL Developer:

(2a) - open DBMS output panel 
(2b) - in DBMS-output panel : choose active Oracle connection

or:

(3) - run:

 SET SERVEROUTPUT ON  


(4) execute SQL in SQL Developer which fires trigger


>> Debug information will be displayed either in DBMS-output or Script output panel



SQL Developer - DBMS output panel

Source Code Formatter

Tuesday, 17 March 2015

MapGuide / AIMS - WMS layer and background transparency and opacity

We set up a few new FDO WMS data sources and created layers accordingly. For an unknown reason for layers from some data sources the background was not transparent. All WMS layers are provided by the same organisation, we set up all data sources and layers the same way.
I finally found out that changing settings in "Set coordinate system overrides" for the data source and re-creating the layers solved the problem. I just changed image format from png to something else and unchecked the "Transparent" checkbox, saved the changes and then set the original values back again and saved it. 

WMS data source - cs overrides does the trick....

When creating a layer for the modified data source afterwards background transparency was present again. It is probably sufficient to just uncheck the "Transparent" checkbox but I haven't tested that - wasted enough time already...

After this issue was solved the second question came up - can we now set an opacity for the WMS layer? No, we can't... It is possible in AutoCAD Map to apply opacity to a raster layer but this does not work for raster layers in AIMS/MapGuide (at least not with FDO Raster Provider) and for WMS based layers.
Would be a nice enhancement if it were possible...

"Opacity" with Map raster layers - here you will find further information (German language),

Map, AIMS 2013