Iron Speed Technical Forums
Register Latest Topics
 
 
 


Reply
  Author   Comment  
webdevguy

Registered:
Posts: 140
Reply with quote  #1 
I added a new class to the app_code directory. For some reason though I can't access it through other pages. Any ideas why?

Code:

Public Class PDFHelper
    Public Sub New()
    End Sub
    Public Shared Function GetFormFieldNames(pdfPath As String) As Dictionary(Of String, String)
...


The following code produces error "PDFHelper is not declared. It may be inaccessible due to its protection level."

Code:

Dim formFieldMap = PDFHelper.GetFormFieldNames(pdfPath)



miles

Avatar / Picture

MVP Consultant
Registered:
Posts: 1,656
Reply with quote  #2 
did you save this class into it's own file?  Have you done a rebuild all in Iron Speed and/or in Visual Studio.  Off hand the code looks good, other than your variable declaration, which should be:

Dim formfieldmap As Dictionary(Of StringString) = pdfhelper.GetFormFieldNames("")

HTH,

Note: I created this same code and it works for me.

__________________
Miles Gibson, MScIS
Iron Speed MVP
Senior Consultant, Principal
Milestone Software Inc.

http://www.ironspeedmvp.com\localizer 
Email: miles@milestone.ca
Milestone Localizer: Full Localization for your Iron Speed applications!
webdevguy

Registered:
Posts: 140
Reply with quote  #3 
Quote:
Originally Posted by miles
did you save this class into it's own file?  Have you done a rebuild all in Iron Speed and/or in Visual Studio.  Off hand the code looks good, other than your variable declaration, which should be:

Dim formfieldmap As Dictionary(Of StringString) = pdfhelper.GetFormFieldNames("")

HTH,

Note: I created this same code and it works for me.


Thanks for your response! Yes, the class is it's own file. I also did a rebuild all in VS with no problem. (After I commended out the lines with references to this class.) See below. "Report" is the reference to iTextSharp.

SS.JPG 

webdevguy

Registered:
Posts: 140
Reply with quote  #4 
It turns out that there was something weird in the class. I recreated the class (using the same code, which is confusing) and all of a sudden saw compile errors. I addressed those and then I was able to access the class, methods, etc...
miles

Avatar / Picture

MVP Consultant
Registered:
Posts: 1,656
Reply with quote  #5 
Great, glad it worked!
__________________
Miles Gibson, MScIS
Iron Speed MVP
Senior Consultant, Principal
Milestone Software Inc.

http://www.ironspeedmvp.com\localizer 
Email: miles@milestone.ca
Milestone Localizer: Full Localization for your Iron Speed applications!
Previous Topic | Next Topic
Print
Reply

Quick Navigation:

Easily create a Forum Website with Website Toolbox.

Download Iron Speed Designer

Terms of Service Privacy Statement