Plugin Purchase Order Generation Reorder Method - error  Topic is solved

Discussions relating to Jiwa 7 plugin development, and the Jiwa 7 API.

Plugin Purchase Order Generation Reorder Method - error

Postby neil.interactit » Tue May 05, 2015 3:47 pm

Hi guys,

This error is occurring on site, but if I take a database copy and load it up on my dev box everything is fine ...

image001.png
image001.png (14.5 KiB) Viewed 2934 times


There is obviously a path issue, but the error seems to be upon compile - so is the fix likely to be within the plugin code, or changing something in the onsite environment?

Cheers,
Neil.
neil.interactit
Kohai
Kohai
 
Posts: 232
Joined: Wed Dec 03, 2014 2:36 pm
Topics Solved: 6

Re: Plugin Purchase Order Generation Reorder Method - error  Topic is solved

Postby Scott.Pearce » Tue May 05, 2015 4:06 pm

Jiwa generates a path into which the plugin will be compiled. This path is generated based on attributes like the name of the database, the version of Jiwa, and the Jiwa username of whoever is logging in. This allows compiled plugins to co-exist peacefully on a multi-user system, where each user may be accessing multiple databases, each with plugins having the same name.

To illustrate, when I log in to a demo database on my local machine, load up a plugin, and press the compile button, a .DLL is spat out at:

"C:\ProgramData\Jiwa Financials\Jiwa 7\7.0.117\localhost\JiwaDemo\Plugins\admin\Compile\Purchase Order Generation Reorder Method - Replenish to Minimum\"

The name of the .DLL is "Purchase Order Generation Reorder Method - Replenish to Minimum.dll". So, the full path ends up as:

Code: Select all
C:\ProgramData\Jiwa Financials\Jiwa 7\7.0.117\localhost\JiwaDemo\Plugins\admin\Compile\Purchase Order Generation Reorder Method - Replenish to Minimum\Purchase Order Generation Reorder Method - Replenish to Minimum.dll


That's 218 characters already. Use a longer machine name (as opposed to "localhost" in the example above), and login to Jiwa as a user with a username longer than "admin" (again, as used in the example above), and we will soon find ourselves hitting the 260 char limit imposed by the OS!

In your case, I would recommend simply renaming the plugin. "Purchase Order Generation Reorder Method - Replenish to Minimum" is quite long (and yes, I realise we named it!). Maybe rename it to "PO Generation Reorder Method - Replenish to Min".
Scott Pearce
Senior Analyst/Programmer
Jiwa Financials
User avatar
Scott.Pearce
Senpai
Senpai
 
Posts: 765
Joined: Tue Feb 12, 2008 11:27 am
Location: New South Wales, Australia
Topics Solved: 230

Re: Plugin Purchase Order Generation Reorder Method - error

Postby neil.interactit » Tue May 05, 2015 4:31 pm

Ah, the simplest of fixes. Thanks Scott!
neil.interactit
Kohai
Kohai
 
Posts: 232
Joined: Wed Dec 03, 2014 2:36 pm
Topics Solved: 6


Return to Technical and or Programming

Who is online

Users browsing this forum: No registered users and 6 guests