Home | Forums | Contact | Search | Syndication  
 
 [login] [create account]   Monday, August 18, 2025 
 
slxdeveloper.com Community Forums  
   
The Forums on slxdeveloper.com are now retired. The forum archive will remain available for the time being. Thank you for your participation on slxdeveloper.com!
 Architect Forums - SalesLogix Scripting & Customization
Forum to discuss writing script in Architect plugins for SalesLogix & general SalesLogix customization topics (for Windows client only). View the code of conduct for posting guidelines.
Forums RSS Feed


 Back to Forum List | Back to SalesLogix Scripting & Customization | New ThreadView:  Search:  
 Author  Thread: Datagrid Adding Multiple Records
Ben
Posts: 26
 
Datagrid Adding Multiple RecordsYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 04 Feb 08 1:29 PM
This is my first time playing around with Datagrids, so please be gentle.

I have added a datagrid to an account level tab, and set the BIND ID as accountid. I created a new form, and set the form as the EditView. I also set the SQL on the datagrid to give me all records from a new table with the same accountid as the current account.

Now, what I don't understand is how to bind the fields on the EditView form to the record. I tried to script it all manually to add to the datagrid, which I have done successfully, but when the EditView form closes, another extra row is added. Can I 'turn off' that binding, and just let my script do the work? Or, if not, how do I go about binding fields on the form to the proper fields in the database?

Also, the records have a one-to-many relationship with the account, if that matter.

Thanks!
[Reply][Quote]
Mike Spragg
Posts: 1226
Top 10 forum poster: 1226 posts
 
Re: Datagrid Adding Multiple RecordsYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 04 Feb 08 2:14 PM
Hi Ben & Welcome - we're all gentle here

All you need to do is open your data grid and open the SQL property - this will show you the columns etc. On the first (maybe 2nd) tab there is a link box. Just drag your AccountID from the new table (should be in the list above) onto here and it will then automatically do everything else. However, remember it's the AccountID from *your* table - not the AccountID from Account that you need.
[Reply][Quote]
Ryan Farley
Posts: 2265
slxdeveloper.com Site Administrator
Top 10 forum poster: 2265 posts
 
Re: Datagrid Adding Multiple RecordsYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 04 Feb 08 3:17 PM
Hi Ben,

You don't need to manually script the inserting of your data on the edit view. That's the beauty of data binding. Are the fields on the edit view bound to the table? If so, all you need to do is add a "Close" or "OK" button on the form that sets a modal result of mrOK and the bound fields will be saved.

Does that make sense?
[Reply][Quote]
Ben
Posts: 26
 
Hey guys, thanks for the responses!Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 04 Feb 08 3:22 PM

Ryan, it totally makes sense. Thanks! But, no, they are not bound at this point. For some reason, it won't list the new table as an option when trying to bind them. I thought it was because I hadn't recreated the join, but once I did, it still didn't list it. Any ideas why the new table isn't showing up when trying to bind the field?

Thanks!

[Reply][Quote]
Ryan Farley
Posts: 2265
slxdeveloper.com Site Administrator
Top 10 forum poster: 2265 posts
 
Re: Hey guys, thanks for the responses!Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 04 Feb 08 3:25 PM
You'll want to make sure that the form type you selected for the new form is a data form, not an account or manage form. When you choose data form, you'll be able to select your new table as the base table for the form.
[Reply][Quote]
Ben
Posts: 26
 
Re: Hey guys, thanks for the responses!Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 05 Feb 08 9:21 AM
Ah! Pure genius, all of you.

That was the problem: wrong type of form.

Thanks!
[Reply][Quote]
 Page 1 of 1 
  You can subscribe to receive a daily forum digest in your user profile. View the site code of conduct for posting guidelines.

   Forum RSS Feed - Subscribe to the forum RSS feed to keep on top of the latest forum activity!
 

 
 slxdeveloper.com is brought to you courtesy of Ryan Farley & Customer FX Corporation.
 This site, and all contents herein, are Copyright © 2025 Customer FX Corporation. The information and opinions expressed here are not endorsed by Sage Software.

code of conduct | Subscribe to the slxdeveloper.com Latest Article RSS feed
   
 
page cache (param): 8/18/2025 5:25:22 PM