.NET

.NET

Reply
Active Contributor
bkenyon13
Posts: 45
Registered: ‎04-20-2012
Message 1 of 2 (101 Views)
Accepted Solution

fatal error resolved but still having issue

101 Views, 1 Replies
05-25-2012 09:44 AM

I found the line that was causing the fatal error that I was getting, but I am now having another issue.

 

I have code that looks as follows:

For Each psent As DBDictionaryEntry In psd
                            id = psd.GetAt(psent.Key)
                            Dim ps As PlotSettings = id.GetObject(OpenMode.ForRead)
                            Dim curps As PlotSettings = New PlotSettings(False)
                            curps.CopyFrom(ps)
                            curps.AddToPlotSettingsDictionary(db)
                            curps.DowngradeOpen()
                            trns.Commit()
                            curps.Dispose()
                            Exit For
                        Next

 This will only copy one pagesetup, how ever I have multiple pagesetups that I need to have copied. I can accomplish that by removing the curps.dispose().

however if I remove that then I start getting the fatal error back.

 

is there a way that I can close the curps plotsettings without using dispose or close?

finally figured it out.

 

I used:

using curps....

(did work)

end using

this eliminated the fatal error and also copied all the page setups

Active Contributor
bkenyon13
Posts: 45
Registered: ‎04-20-2012
Message 2 of 2 (98 Views)

Re: fatal error resolved but still having issue

05-25-2012 10:09 AM in reply to: bkenyon13

finally figured it out.

 

I used:

using curps....

(did work)

end using

this eliminated the fatal error and also copied all the page setups

Post to the Community

Have questions about Autodesk products? Ask the community.

New Post
Announcements
Do you have 60 seconds to spare? The Autodesk Community Team is revamping our site ranking system and we want your feedback! Please click here to launch the 5 question survey. As always your input is greatly appreciated.