Solved

Need Filtered Lookup

Posted on 2010-08-26
6
865 Views
Last Modified: 2013-11-24
I need to lock down the pop up box that appears when I click Customers on the Order form.  A pop up box appears with a drop down box for Accounts or Contacts.  The default is Accounts (which is what I want).  I want to lock down the drop down list on the popup box so that only Accounts appear (no option for Contacts)

The url that appears is for the pop up box is:
https://apollo7.space.net//_controls/lookup/lookupsingle.aspx?class=BasicCustomer&objecttypes=1,2&browse=0&ShowNewButton=1&ShowPropButton=1&DefaultType=0

I copied this url into a new browser window and discovered that if I change 'BasicCustomer&objecttypes=1,2' to BasicCustomer&objecttypes=1, then I only show Accounts.  

(Note: If I change it to BasicCustomer&objecttypes=2, then I only see Contacts)

Is there a way to modify/filter lookupsingle.aspx (just for Orders) so that it will only show Accounts in the drop down list?

Thanks
0
Comment
Question by:apollo7
  • 3
  • 3
6 Comments
 
LVL 27

Expert Comment

by:Chinmay Patel
ID: 33535308
Hi apollo7,
I would not suggest to modify the .aspx file. Rather than that onLoad event of case you can change the filtered lookup.
What I suggest is to write a JavaScript that will change the URL as per your requirements i.e. a script that can set objecttypes=1
Regards,
Chinmay

0
 
LVL 1

Author Comment

by:apollo7
ID: 33536669
Chinmay - I think I have some examples of this / I will try one and post any questions and errors.
0
 
LVL 1

Author Comment

by:apollo7
ID: 33653467
Chinmay - thought I had some examples of this but cannot find them. Can you provide a link or example of  how to restrict the Customers lookup on the Order form.  The lookup shows both Accounts and Contacts..I want to show only Accounts as a lookup option.

Thanks
0
PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

 
LVL 27

Accepted Solution

by:
Chinmay Patel earned 500 total points
ID: 33655843
Hi apollo7,
On form load event, write this statement : 
crmForm.customerid.lookuptypes = 1;
Regards,
Chinmay

0
 
LVL 1

Author Closing Comment

by:apollo7
ID: 33665503
Thanks Chinmay, works great and I can see other places I can use this method
0
 
LVL 27

Expert Comment

by:Chinmay Patel
ID: 33667641
You are welcome. :) 
0

Featured Post

Control application downtime with dependency maps

Visualize the interdependencies between application components better with Applications Manager's automated application discovery and dependency mapping feature. Resolve performance issues faster by quickly isolating problematic components.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When CRM stops functioning propperly or mysteriously disappears then this is something you should always check. This can be useful when looking at an end users machine or your own machine if you are the end user. It may be fairly obvious to some but…
Automatically creating a Trello card using data from a Microsoft Dynamics CRM record turned out to be an easy project that yielded great results.  Here's how I did this for an internal team at General Code.
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

932 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now