Jump to content

Automatically populating Estimate Lines with a relevant set of items from GoodsAndServices


This topic is 4575 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

Hello,

I'm trying to find a way to do the following:

I wish to generate an Estimate based on a type of Client ( I anticipate four types of Clients)

Because the four types of Estimates based on the four types of Clients generally have a standard set of items (and pricings), I wish to find a way to create a new Estimate and have it populate automatically with items from my GoodsAndServices table.

(Also I realized it is easier to delete EstimateLines than it is to input from a lengthy popup menu.

In my GoodsAndServices table, I have the list of goods and services, each record tagged with field called "Category" which will have the value of "A"; "B"; "C"; or "D".

I am sure there is a way for me to have it prepopulate an Estimate with all the items of that set (as well as the costs, description, ID, etc)

My problem is I currently have a layout in the context of Estimates; with a portal displaying records from EstimateLines. I did it this way, as it will automatically input the EstimateIDfk with each EstimateLine record. I've been hammering away at a way to achieve this goal, but alas....

I wish to maintain this layout; but now I am thinking it is not possible to do this in this layout. -- I might have to do this in a layout that is in the context of the table EstimateLines.

Can anyone provide me some advice regarding the context I should be trying this in? And perhaps direct me what scripts I should be utilizing?

Thank you....

Posted

There are a few ways you could script this, e.g. looping through the portal. One way you might try is with an import:

1. Create your Estimate record and grab the ID and category in variables (e.g., $id, $cat)

2. Go to the product list and find for the appropriate category ($cat A, B, C, etc.)

3. Go to Estimate Lines and import from product list

4. Do a Replace in the EstimateIDfk with $id from step 1.

5. Go back to the estimate

Posted

Thank you Fitch for the direction.

I'm going to try this today...

Very new to scripts; I think I can follow what you are saying...

Thank you again!

Posted

Fitch,

I think I have this running smoothly, until I have to import the found set from the product list into the Estimate Line(s)

Is it best to export this found set and then import?

Is there a simpler, more direct way, without the exporting and importing?

If there is no way around the exporting/importing, would the best route be using Save Records as Excel? As this seems to be the only one with a way of exporting a found set?

Or am I wrong?

Thank you.

Posted

Is it best to export this found set and then import?

No, it's not necessary to export.

Is there a simpler, more direct way, without the exporting and importing?

As I said above, you don't need to export, so yes to that.

Is there a way to do it without using import? Sure, I can think of several.

Are those ways simpler/more direct? I would say no.

If there is no way around the exporting/importing, would the best route be using Save Records as Excel? As this seems to be the only one with a way of exporting a found set?

Kind of a moot point if you've read this far, but the command you're looking for is: Export Records.

This topic is 4575 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.