DB local instance  Topic is solved

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

Re: DB local instance

Postby Riyaz » Tue Aug 21, 2018 1:55 pm

Hi Scott

How do I refer to the below in v 7.2

JiwaApplication.JiwaSearch.SearchOption
Riyaz
Kohai
Kohai
 
Posts: 254
Joined: Wed Dec 02, 2015 2:05 pm
Topics Solved: 2

Re: DB local instance

Postby Scott.Pearce » Tue Aug 21, 2018 2:02 pm

JiwaApplication.JiwaSearch.SearchOption inherits from JiwaApplication.JiwaCollectionItem, therefore you should use the JiwaCollectionItem factory to instantiate such an object thus:

Code: Select all
JiwaFinancials.Jiwa.JiwaApplication.JiwaSearch.SearchOption searchOption = Manager.CollectionItemFactory.CreateCollectionItem<JiwaFinancials.Jiwa.JiwaApplication.JiwaSearch.SearchOption>();


I assume you already have a Manager object to use for making the call to the factory.
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: DB local instance

Postby Riyaz » Tue Aug 21, 2018 2:35 pm

Yep I do have a Manager, I tried your suggestion but it won’t compile, pls see attached
Attachments
PNG image.png
Riyaz
Kohai
Kohai
 
Posts: 254
Joined: Wed Dec 02, 2015 2:05 pm
Topics Solved: 2

Re: DB local instance

Postby Scott.Pearce » Tue Aug 21, 2018 2:38 pm

Your code is different. Look carefully at the type you are declaring and passing to the factory compared to my code.
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: DB local instance

Postby Mike.Sheen » Tue Aug 21, 2018 2:56 pm

Riyaz wrote:Yep I do have a Manager, I tried your suggestion but it won’t compile, pls see attached


You've copied C# code into a VB.NET plugin.
Mike Sheen
Chief Software Engineer
Jiwa Financials

If I do answer your question to your satisfaction, please mark it as the post solving the topic so others with the same issue can readily identify the solution
User avatar
Mike.Sheen
Overflow Error
Overflow Error
 
Posts: 2583
Joined: Tue Feb 12, 2008 11:12 am
Location: Perth, Republic of Western Australia
Topics Solved: 807

Re: DB local instance

Postby Scott.Pearce » Tue Aug 21, 2018 2:59 pm

I didn't notice that. Here's the VB version:

Code: Select all
Dim searchOption As JiwaFinancials.Jiwa.JiwaApplication.JiwaSearch.SearchOption = Manager.CollectionItemFactory.CreateCollectionItem(Of JiwaFinancials.Jiwa.JiwaApplication.JiwaSearch.SearchOption)
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: DB local instance

Postby Riyaz » Tue Aug 21, 2018 3:01 pm

Thanks Mike and Scott
Riyaz
Kohai
Kohai
 
Posts: 254
Joined: Wed Dec 02, 2015 2:05 pm
Topics Solved: 2

Previous

Return to Technical and or Programming

Who is online

Users browsing this forum: No registered users and 3 guests