TurboCAD Forums

The Ultimate Resource for TurboCAD Knowledge

Register
 
When posting a problem be sure to include which version you are using.  Give as much information as possible.  If the problem is with a specific file be sure to attache it to your post.

What happens after a UE error or TC crash?
Read 3859 times
September 18, 2010, 05:58:07 AM
Here's a question that may not have an easy answer, but it might be useful to know:  When TurboCAD encounters an Unhandled Exception error (with error message) or crashes (TC instantly disappears), does something change in the program/configuration itself?  Or should one be able to restart the program (or restart the computer) and have everything go back to the way it was before the UE/crash?

Here's the situation that led to my question:  Yesterday, while answering a question on the forum, I attempted to load TC.  Without realizing it, I clicked on TC while my anti-virus program was downloading an apparently large update, and I think there was a conflict.  This lead to TC not showing up, then me re-clicking TC, then two or three separate UE error screens.  After the program update ended, I reloaded TC  and my file with a Parametric Part, then tried to draw new lines with constraints in the normal workspace on the default workplane.  The instant I hit (any) constraint button, TC completely disappeared.  I tried it multiple times with the same result, then restarted the computer, but even then TC would disappear.

The problem finally ended after I restarted TC and started a new drawing and used constraints there first.  From then on, I could use constraints in the old file just fine, even though I have not saved any modifications.  The old file is just the same as it was before the crashes started.  And I just tried it again now--everything seems to be working okay.

So, that brings me back to my initial question--does anyone know why such things happen?  Does TurboCAD change itself somehow after a crash in such a manner that even a computer restart doesn't fix it?

Thanks for any insight...

Logged
Josh T.
meatballrocketry.com
TC Pro 18.2 & Platinum 2016


* September 18, 2010, 06:24:02 AM
#1
I do know at times TC becomes corrupt after a crash.... so I always replace the config files with ones that I have backed up for just such occasions.

The first thing I do after installing a new version of TC and getting it configured the way I want is to backup those fresh config files. I also have a copy of those "good" config files on my hard drive, and a bat file that I run to replace those possible corrupt ones with the good ones each and every time that TC crashes. It just becomes a habit.. as soon as TC crashes, I run the bat file, and restart TC.

Logged
AMD Phenom 1090T
8GB RAM
Radeon 5450 1GB
Windows 7
Redsdk  - Off
Editing History - On
v19.2 Platinum, x64


September 18, 2010, 09:06:00 AM
#2
The habit sounds fairly simple, Greg...  but what's involved in creating & setting up a BAT file?

And separately storing/reloading the last good config settings sounds like something TC should be able to accomplish automatically after a crash, but perhaps I'm missing something.

Logged
Josh T.
meatballrocketry.com
TC Pro 18.2 & Platinum 2016


* September 18, 2010, 01:23:25 PM
#3
If you're not familiar with the good ole DOS days... you may want to do a search on how to create a .bat(batch) file. It's really very simple, it's just a txt file that has the commands in it that you want run and saved with a .bat extension. You then create a shortcut to run the batch file. If you didn't save a copy of your config files before TC crashed, you will want to create some new ones.

As far as TC doing this automatically... the files shouldn't be getting corrupted in the first place... never understood why they do.

Logged
AMD Phenom 1090T
8GB RAM
Radeon 5450 1GB
Windows 7
Redsdk  - Off
Editing History - On
v19.2 Platinum, x64


September 18, 2010, 01:52:34 PM
#4
If you're not familiar with the good ole DOS days... you may want to do a search on how to create a .bat(batch) file. It's really very simple, it's just a txt file that has the commands in it that you want run and saved with a .bat extension. You then create a shortcut to run the batch file. If you didn't save a copy of your config files before TC crashed, you will want to create some new ones.

As far as TC doing this automatically... the files shouldn't be getting corrupted in the first place... never understood why they do.

I had not yet separated out any config files since reloading TC from scratch, since I had not yet made any changes to the Built-Ins.  I was trying to wait and see what sort of problems I ran into before changing anything.  I'm hoping I don't have to reinstall everything again just to get a non-corrupt configuration to save.

Aside from the specific command language in the BAT file, are you basically just deleting the old, then copying the replacement file into the old one's place?  And just to be clear, is it only the TCW17_xml.ini file that needs to be replaced?  (That's the one John R. seems to refer to a lot).  There are two other files in my Built-in folder that are labeled "Configuration Settings", as well.

If I'm missing part of the procedure, please let me know.  Thanks.  :)

Logged
Josh T.
meatballrocketry.com
TC Pro 18.2 & Platinum 2016


* September 18, 2010, 02:21:14 PM
#5
If you have made no changes to the settings in TC, you can just delete the TCW17_xml.ini (delete the desktop18.ist as well... might as well be safe), and TC will rebuild them from scratch. If you plan on making changes to TC's configuration, I would do it at this point, and then copy/backup the two files mentioned above. I would do this before opening any drawings, since the name of the drawings will for always be in the file pulldown if you don't.

As far as deleting the old and replacing with the new... pretty much  ;D

Logged
AMD Phenom 1090T
8GB RAM
Radeon 5450 1GB
Windows 7
Redsdk  - Off
Editing History - On
v19.2 Platinum, x64


September 18, 2010, 04:19:57 PM
#6
Thanks, Greg...   I have not yet rebooted anything, but I seem to have come up with a BAT file that works using the REPLACE command.  Obviously, my file paths will not work for someone else.  In the command, the source file path and filename is listed first, the destination path (no file name) second.  I added a couple of 'pause' lines in there so I could see what was going on.  The quotes are necessary due to the spaces in the path.  Thanks again for the suggestion!

@echo off
echo Replace TurboCAD v17 INI Configuration File
pause
replace "C:\Documents and Settings\Josh\My Documents\CAD\TC Docs\TC_Config_Settings\TCW17_xml.ini" "C:\Documents and Settings\Josh\Application Data\IMSIDesign\TurboCAD\17\Professional\Profiles\Built-in"
pause

Logged
Josh T.
meatballrocketry.com
TC Pro 18.2 & Platinum 2016


September 18, 2010, 05:36:07 PM
#7
Let me add that I hope the file replacements will now work for me in v17; leading up to my complete reinstall a couple weeks ago, I was only occassionally successful in restoring a previous TCW17_xml.ini file during some tests.  Quite often nothing would visibly change after replacing a newer file with an old one, but hopefully I got rid of that problem when I reinstalled.

Which brings me to a related question-- why do we only replace the TCW17_xml.ini file and not the other two ini files?

Logged
Josh T.
meatballrocketry.com
TC Pro 18.2 & Platinum 2016


* September 18, 2010, 10:08:10 PM
#8
re: ...why do we only replace the TCW17_xml.ini file and not the other two ini files?

I've got four INI files, but the TCW17_xml.ini file is the main one. It contains all the settings you see in TCExplorer and there are also settings you don't see. The ones you don't see won't appear in the INI file until you use a particular tool or do something. Sometimes they get written improperly. In the old days, you could open the file in Wordpad and search for the error (if you were so inclined) or you could delete the file and let TC build a fresh one. Nowadays, it's easier to delete or replace it.



re: Quite often nothing would visibly change after replacing a newer file with an old one…

If you reinstall or patch the program, you have to run it once, then you can replace the INI file. The first time TurboCAD is run after a reinstall or Update, everything in the Built-in folder is destroyed and built anew. If you paste a copy of your INI in there before running the program, it gets tossed as soon as the program starts. Most times I just skip doing a reinstall and just wipe out the contents of the Built-in folder; sort of a cheap reinstall. I'll paste in a copy of my saved INI file and let TC build the rest. Once TC is running, I can go to the Options page and load my custom Workspace.

I hope some of this is helpful.

Logged
John R.

V17—V21, 2015—2018
Designer, Deluxe, Expert, Basic, Platinum
RedSDK enabled
Windows 10 Pro, 64-bit


* September 19, 2010, 03:40:38 AM
#9
Looks like John answered your questions... but I would like to add one thing. Although you may not see anything visibly change in TC after replacing the ini file, the file could still be corrupt... and the problems start happening at the most inopportune times too.  I just go ahead and replace the file every time TC crashes just to be safe... since it always comes back to bite me in the butt if I don't.

Logged
AMD Phenom 1090T
8GB RAM
Radeon 5450 1GB
Windows 7
Redsdk  - Off
Editing History - On
v19.2 Platinum, x64


September 19, 2010, 05:06:50 AM
#10
Thanks, guys.  I appreciate the insight into how the program operates.

John, I don't believe the problems I was having (prior to my reinstall) were related to a patch or update.  I think I performed the operation well after the fact.  I think the problem (not being able to replace the ini file effectively) was similar to the problem I had earlier on trying to change the built-in settings in TC Explorer--sometimes I could and sometimes I couldn't.

So I still don't know what the source of that problem was, but I'm hoping that reinstalling TC from scratch took care of it.  It seems that I had corruption somewhere due to all my prize add-ons that I had installed and/or then uninstalled.  I uninstalled the rest before reinstalling TurboCAD.  I'm going to leave the program clean for now, aside from updating my TCExplorer settings.

Many thanks for the help... So it's safe to completely wipe the contents of Built-In, eh?  And you can copy the xml_INI file in there AFTER wiping the contents, but BEFORE loading the program (assuming no reinstall)?

Logged
Josh T.
meatballrocketry.com
TC Pro 18.2 & Platinum 2016


* September 19, 2010, 07:05:17 AM
#11
Don't forget to make a backup of your ini file after you make the TCExplorer changes... otherwise... everything we have discussed thus far is moot  ;D

Yes... you need to copy the ini file before running TC... but I have never tried that after wiping out the entire folder.... as I only delete the two files I mentioned above.

Logged
AMD Phenom 1090T
8GB RAM
Radeon 5450 1GB
Windows 7
Redsdk  - Off
Editing History - On
v19.2 Platinum, x64


* September 20, 2010, 02:27:25 AM
#12
re: So it's safe to completely wipe the contents of Built-In, eh?  And you can copy the xml_INI file in there AFTER wiping the contents, but BEFORE loading the program (assuming no reinstall)?

Yep.

Logged
John R.

V17—V21, 2015—2018
Designer, Deluxe, Expert, Basic, Platinum
RedSDK enabled
Windows 10 Pro, 64-bit


September 20, 2010, 04:22:47 AM
#13
re: So it's safe to completely wipe the contents of Built-In, eh?  And you can copy the xml_INI file in there AFTER wiping the contents, but BEFORE loading the program (assuming no reinstall)?

Yep.

John, do you wipe the contents and replace the xml_INI file each and every time you want to replace the xml_INI file, or is that only a rare occasion (in other words, do you usually only replace just the one file without wiping the contents)?

Logged
Josh T.
meatballrocketry.com
TC Pro 18.2 & Platinum 2016


* September 20, 2010, 05:16:30 AM
#14
Most times I'll replace just the xml_INI. If things seem worse than usual, then it all goes.

I remember that 1st Pricing was creating problems at one point, but since that has been removed, TC hasn't been too bad.  ::)

Logged
John R.

V17—V21, 2015—2018
Designer, Deluxe, Expert, Basic, Platinum
RedSDK enabled
Windows 10 Pro, 64-bit


September 20, 2010, 06:38:54 PM
#15
Thanks guys.  Good info.  :)

Logged
Josh T.
meatballrocketry.com
TC Pro 18.2 & Platinum 2016