NAV Text Object Handler

2»

Comments

  • janpieterjanpieter Member Posts: 298
    That is verry usefull info. I will deffinatly go and rewrite those calls.
    (although i'm verry confused why these functions work different but never mind)

    Vielen dank for your input!
    In a world without Borders or Fences, who needs Windows and Gates?
  • jonwlongjonwlong Member Posts: 11
    RE:gerdhuebner's Option Caption workaround.

    Nice! Thanks,
    Jon Long - ArcherPoint
    MCP - Dynamics NAV
  • jonwlongjonwlong Member Posts: 11
    RE:gerdhuebner's Option Caption workaround.

    This indeed addresses the caption issue but I'm still seeing differing results.

    EX:
    Imported via Object Designer ...
    ESM=Direcci�n;

    Imported via ObjectHandler ...
    ESM=Direcci¢n;

    In table 5050, for instance, there are several instances like these in CaptionML, OptionCaptionML and Text constants.

    An earlier post by SNielsen suggested that it is related to encoding. I'm still digging for a solution for this.
    Jon Long - ArcherPoint
    MCP - Dynamics NAV
  • jonwlongjonwlong Member Posts: 11
    Encoding issue solved! It wasn't an issue with the Object Handler. It was my code that I was using in one of my unit tests in .Net. I needed to set the Encoding to default.

    When constructing my StreamWriter object I changed:

    StreamWriter sw = new StreamWriter(SaveToPath);

    to

    StreamWriter sw = new StreamWriter(SaveToPath, false, Encoding.Default);

    Finally. Now, Objects are identical regardless of Exporting via Object Designer or ObjectHandler.

    Thanks everyone for your help. I'd be glad to share a sample app for anyone interested. It might take a bit of time to pretty it up.
    Jon Long - ArcherPoint
    MCP - Dynamics NAV
  • codebasedcodebased Member Posts: 0
    Hi there,

    I'm getting the following error from .Net call getExport...

    Does someone else got the same issue?

    Please help as I really want to use this wonderfull tool.

    Microsoft Business Solutions-Navision
    Object reference not set to an instance of an object.
    OK
  • dsatriadsatria Member Posts: 80
    SNielsen wrote:
    Right now it will grab the first NAV instance from the Running Object Table, so no it does not support multiple running NAV versions at the same time.

    I have an example for a all object exporter that queries the user like the Developers Toolkit does, so you can select what NAV client to export objects from (check the blog during this coming week).

    Another interesting thing, is it allows you to extract objects to text without the use of a developer license! For importing though it honors the permissions, and throws a:
    "HRESULT = 0x8004005 : You do not have permission to run the 'File, Import, Text' System"

    But it will give end users access to do some object comparison, and version management. When we get a tool together for it.
    Hi Nielsen! Can you confirm your statement that I put in bold?
    Because after I imported the object (Form 91300) to Dynamics NAV 5.0 Demo database and then I tried to export an object (Table 700 - BA Database) it also generated an error "HRESULT = 0x8004005 : You do not have permission to read..."

    Thanks
  • jonwlongjonwlong Member Posts: 11
    Anybody still working on this project? I've found that in Windows 7(64 bit) there may be some issues casting an "object" created from the ROT into an IObjectDesigner as defined in the otherwise stable interface, i.e., it works in all versions of NAV on all versions of Windows OS(32 bit).

    This code returns null:
    this._objectDesigner = getObj as IObjectDesigner;

    This code returns error:
    this._objectDesigner = (IObjectDesigner)getObj;
    Jon Long - ArcherPoint
    MCP - Dynamics NAV
  • janpieterjanpieter Member Posts: 298
    Jonwlong, I don't think 64 bit is a problem when you compile your project for x86 platform. See configuration manager in visual studio. Although I think you're problem might be more related to user priviliges. If you Run Navision in Administrator mode an application in non elevated mode that tries to refference a ROT object won't succeed. And running your application in elevated mode won't succeed in referencing a Navision ROT object which is run as a normal user.

    I'am not aware of further development of this interface but if so I would also be very interested. I tried some experiments although they all failed.
    In a world without Borders or Fences, who needs Windows and Gates?
  • jonwlongjonwlong Member Posts: 11
    janpieter - Thanks for the suggestion. I tried that and still get the same result. The cast returns null, even though it is not null prior to the cast. I've mirror debugged in 32 bit OS and everything looks exactly the same as in the 64 bit until the cast. It may be a user rights issue, but, I'm at a roadblock.

    Other than that, I've added quite a bit of accessories. I would be happy to show you. The code is a mess, but I have a solid demo app that at least demonstrates the basic functionality.
    Jon Long - ArcherPoint
    MCP - Dynamics NAV
  • jonwlongjonwlong Member Posts: 11
    I got it! The solution was to set the build property in .Net to “x86”. I had it set to “Any CPU”.
    Jon Long - ArcherPoint
    MCP - Dynamics NAV
  • ICS123ICS123 Member Posts: 4
    Hi,
    I m able to export the object as text file with client profile license. But when i tried to import the object with same license its throwing error 'You do not have permission'.
    Can we import the object as text file with limited client profile license, if yes please suggest us...
    :?: :?: :?:
    Thanks in advance
    SNielsen wrote:
    Right now it will grab the first NAV instance from the Running Object Table, so no it does not support multiple running NAV versions at the same time.

    I have an example for a all object exporter that queries the user like the Developers Toolkit does, so you can select what NAV client to export objects from (check the blog during this coming week).

    Another interesting thing, is it allows you to extract objects to text without the use of a developer license! For importing though it honors the permissions, and throws a:
    "HRESULT = 0x8004005 : You do not have permission to run the 'File, Import, Text' System"

    But it will give end users access to do some object comparison, and version management. When we get a tool together for it.
  • janpieterjanpieter Member Posts: 298
    ICS123 wrote:
    Hi,
    I m able to export the object as text file with client profile license. But when i tried to import the object with same license its throwing error 'You do not have permission'.
    Can we import the object as text file with limited client profile license, if yes please suggest us...
    :?: :?: :?:
    Thanks in advance
    SNielsen wrote:
    Right now it will grab the first NAV instance from the Running Object Table, so no it does not support multiple running NAV versions at the same time.

    I have an example for a all object exporter that queries the user like the Developers Toolkit does, so you can select what NAV client to export objects from (check the blog during this coming week).

    Another interesting thing, is it allows you to extract objects to text without the use of a developer license! For importing though it honors the permissions, and throws a:
    "HRESULT = 0x8004005 : You do not have permission to run the 'File, Import, Text' System"

    But it will give end users access to do some object comparison, and version management. When we get a tool together for it.

    No the txt import is restricted by what is supported by your Navision license unlike importing a FOB file.
    In a world without Borders or Fences, who needs Windows and Gates?
  • ICS123ICS123 Member Posts: 4
    edited 2013-05-09
    Thanks for reply,
    With same client license i m able to export object as *.txt file using 'navobjectHandler'.dll.
    And when we import the same exported object txt file its throwing an error(using 'navobjectHandler.dll')
    Without 'navobjectHandler.dll' we could not export or import object file as *.txt in object designer using
    client license
  • ICS123ICS123 Member Posts: 4
    Thru coding(in navision or automation dll) we want to import the object text file
    using client license not developer license,
    Please let us know what are the different options we have
  • janpieterjanpieter Member Posts: 298
    ICS123 wrote:
    Thru coding(in navision or automation dll) we want to import the object text file
    using client license not developer license,
    Please let us know what are the different options we have

    You can't import object text because it is modifying your object and perhaps table structures. You will never be able to build full working version management with just a client license. You can however archive changed objects although you can't restore a previous version if you don't have the required permissions. I know because I have created a version management system based around this. :wink:

    Secondly you should just get a developer license I think you might be disobeying your MBS Navision license agreement if you somehow managed to work around your license limitations.
    In a world without Borders or Fences, who needs Windows and Gates?
  • ICS123ICS123 Member Posts: 4
    Thanks for reply @Janpieter,

    if that is the case, how we were able to export the object as text files.
    We have tested and exported object as text file using navobjectHanlder.dll
    with client profile license only...
    If export is possible, there should be a possibility of import also
Sign In or Register to comment.