Click here to Skip to main content
14,219,033 members
Rate this:
Please Sign up or sign in to vote.
See more:
Is there a way to add a link in a lookup field (dropdownlist that displays)that would open the NewForm of the lookup's source? I have a app that has the user select the project name in one list, but there will be times when the project won't be added yet, it would be prefered to have a way they can just click "AddNew" in the dropdown list instead of backing out of the record and then going back in after they create a project.

I did this in 2007 I thought, but can not for the life of me figure this out in 2010, can anyone help?

Thanks
M.
Posted

1 solution

Rate this:
Please Sign up or sign in to vote.

Solution 1

One way is to use a UNION in your SELECT (assuming that you are using SQL):
SELECT CompanyName FROM Suppliers
 UNION SELECT "Add New"

Or, of course:
SELECT "Add New"
  UNION SELECT CompanyName FROM Suppliers


This can become problematic if you are selecting more than one column from the database though.
   
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)




CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100