Reply
 
LinkBack Thread Tools Display Modes
Old 10-02-2009, 08:13 PM   #1 (permalink)
CrystalHacker
Guest
 
Posts: n/a
Default Location Path Order

nkarthick,

Could you take a look at the last post on
Location in reports

I'm trying to figure out how to test to see if there is a Location Type named "Install Loc" and if so create code to not show it on sales reports. I never know if this Location is going to be used, but if it is is should not show on Sales Reports.

Install Loc is ALWAYS the most granular location. I assume this is the "5th" location. However if I only have 2 locations defined say Room & Install Loc, is Install Loc still 5 or is it 0?

I assume the Order is
0 - Campus
1 - Building
2 - Floor
3 - Room
4 - Closet or in our case Install Loc

Is Location 4 always Closet, even if only two locations, Room and Closet, are defined for the project? If so, then I know how to use your code to solve my problem.

However if Room is now (0) and Closet (1), I need to come up with a way to know if Closet (Install Loc) is defined in the project.

-ch
  Reply With Quote
Old 10-02-2009, 09:09 PM   #2 (permalink)
Senior Member
 
Join Date: Mar 2006
Location: Novato (20 miles north of San Francisco)
Posts: 445
fryeguy is on a distinguished road
Default

So is that to say that if an Item (ex: ABC Acoustics Amplifier) from your PDM is in Location "Theater: Install Loc" that you want to see this amp show on a sales report in Location Theater? Or do you not want it to show at all?
fryeguy is offline   Reply With Quote
Old 10-03-2009, 12:24 AM   #3 (permalink)
CrystalHacker
Guest
 
Posts: n/a
Default

Thanks for asking...

I would like for it to show "Theater".

However, if no "Install Loc" is defined and the location is something like
First Floor:Theater
I want this to show as is.

I only want to hide the Install Loc for Proposals. Our engineering staff uses Install Loc to create detailed wire pull lists. This level of detail while great for engineering creates havoc in the proposals. All of this is working in Si4. I am trying to get to Si5.

The big benefit of the Install Loc concept is that once the schematics are complete you can produce very accurate wire pull lists. Any place where a wire runs from is an Install Loc. The wire is connected via the schematic from one Install Loc to another. If the location changes your pull lists are automatically updated. No need to track down and redefine each Head End. You never have to count on Head End which is very unreliable.

If I knew that Locations were always in the same 0-4 positions then the problem is easy. I would always show 0-3 on proposals. However, I have no idea how the indexing works when only one or two locations are defined such as the example above.

In the above example is the index for First Floor 2 or 0? I don't know.

-ch

Last edited by CrystalHacker; 10-03-2009 at 12:26 AM.
  Reply With Quote
Old 10-05-2009, 10:22 AM   #4 (permalink)
Senior Member
 
Join Date: May 2009
Location: Chennai, India
Posts: 157
nkarthick is on a distinguished road
Default

Hi Ch,

I have created a Sales order custom report based on existing “Sales Order By Location” report which does not show the location “Install Loc”. This report ignores the location “Install Loc” irrespective of the location order or level in the project. It will consider the locations up to the location level which lies before the “Install Loc” location level.

You can download this custom report from here. Please import this report from the Export menu in the Orders & Scheduling report designer.

FYI
- Standard Reports use XML as Data source.
- Orders & Scheduling Reports use Dataset as Data source.


Custom Report Updates –
- Includes a new procedure called SetDataSource and it will be invoked from the Active Report Start “ActiveReport_ReportStart” event procedure.

- This procedure will add two new columns “CustomLocationOrder” and “CustomLocationPath” to the dataset.

- This procedure will iterate through all data rows in the dataset and populate this column based on the following logic:-
  1. If it’s finding the location “Install Loc” in the location path, then it will build the new custom location path and location order by ignoring the location level “Install Loc”.
  2. If it’s not finding the location “Install Loc” in the location path then it will assign the location path and location order as it is.
- Also updated the report designer to use the new columns “CustomLocationOrder” and “CustomLocationPath” to support this use case.
Hope it helps.
__________________
Narayana Karthik
nkarthick is offline   Reply With Quote
Old 10-05-2009, 02:07 PM   #5 (permalink)
CrystalHacker
Guest
 
Posts: n/a
Default

You DaMan! I would have never figured that out.

Thanks again!
  Reply With Quote
Old 10-05-2009, 02:38 PM   #6 (permalink)
CrystalHacker
Guest
 
Posts: n/a
Default

I assume I can use these procedures in the Line Item and Proposal reports as well.

Thanks again!

-ch
  Reply With Quote
Old 10-06-2009, 09:03 AM   #7 (permalink)
Senior Member
 
Join Date: May 2009
Location: Chennai, India
Posts: 157
nkarthick is on a distinguished road
Default

OOPS... You cannot use the procedure "SetDataSource" in the standard reports(Proposal or Line Item). Since this procedures is specific for sales order report (Business Manager reports) which uses dataset as datasource.

As I told already standard reports use XML as data source and Orders & Scheduling (Business Manager) reports use Dataset as Data source.

Since these procedures dealing with the dataset you cannot use this procedures in standard reports (Proposal or Line Item reports).

Hope you understand the concept.
__________________
Narayana Karthik

Last edited by nkarthick; 10-06-2009 at 09:06 AM.
nkarthick is offline   Reply With Quote
Old 10-06-2009, 02:05 PM   #8 (permalink)
CrystalHacker
Guest
 
Posts: n/a
Default

I was afraid of that...

Is there a way to accomplish this with the XML data? If I could test for "Install Loc" and then figure out the index order, I should be able to use the code you presented in other thread.

I have a few days to figure this out, before the Sales team gets revised projects from engineering with Install Loc defined.

-ch
  Reply With Quote
Old 10-06-2009, 02:08 PM   #9 (permalink)
CrystalHacker
Guest
 
Posts: n/a
Default

I sure wish D-Tools would use the SetDataSource for all reports. It provides so much more flexibility.

-ch
  Reply With Quote
Old 10-06-2009, 10:01 PM   #10 (permalink)
CrystalHacker
Guest
 
Posts: n/a
Default

nkarthick,

I'm thinking of adding a parameter to the Line Item report that would allow the user to Show or Hide Install Loc.

From the code you presented at
Location in reports
Is LocationOrder and LocationPath available to the Proposal reports?

I see from the example of how to extract one Location, but I am not sure how to eliminate one.

-ch
  Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Location in reports Memphix Reports and Reporting Center 10 09-28-2009 06:44 PM
Location Description? Longlist Reports and Reporting Center 2 07-14-2009 05:47 PM
Change order help Gurkha Business Manager 2 05-21-2009 09:01 PM
Location Property of D-ToolsSOItem ManjitS SDK 0 11-16-2006 09:46 PM
Line Item List Price Report by Location by Zone Sort order? jims SI4 Quick Tips and Customizations 15 08-22-2006 03:50 PM


All times are GMT. The time now is 09:04 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.3.0
D-Tools, Inc.