Browse By Tags

  • Blog Post: Building a Simple Quick Search Page

    Entities such as Case and Solution use a reference field as an alternative key. This is the 'ticket' number (case_referenceid, soln_referenceid) that is used as a public and convienent way of identifying each record. In the default demo system the fields case_referenceid and soln_referenceid...
  • Blog Post: Using CRM security in ASP pages

    Access to buttons can be controlled by the 4 & 5 parameter of the CRM.Button() method. The entity referenced in the 4th param has to be an entity normally covered by security. (This can also be a custom top level entity) The 5th parameter can be INSERT VIEW EDIT DELETE var strNewCompanySecurityButton...
  • Blog Post: Setting screen properties within a multiblock ASP page using the COM API

    This COM API trick for ASP based Application Extensions shows how you can create a screen with 2 (or more) blocks where one of the blocks remains in view mode regardless of the value of CRM.Mode. It is a very simple approach and all you have to do is get hold of the block that you wish to be read only...
  • Blog Post: Updated Partial Rebuild of the Company QuickLook Screen using the ASP API

    This is a version of the Company Quicklook screen rebuilt using the classic ASP API back in 2008. There are buttons to call New Task and New Communication buttons. The button code references the source file and the jump destination. [code language="javascript"] var fileContext = "&F...
  • Blog Post: Creating an ASP Search Page that Displays Data from an external Database using an ODBC driver e.g. Sage 100 ERP, formerly known as MAS 90

    This article discusses the challenges that can be faced when building a Search page that queries an external database table through an ODBC driver. I have used for this example a connection to a Sage ERP MAS 90 table. I have assumed that you will have read the following articles Connecting to...
  • Blog Post: Sage CRM EntryTypes used in the COM ASP API

    I have covered manually building screens, that is without using existing Screen or List meta data definitions in earlier posts. These contain example code that uses the following basic struture of code to build the fields. var customTextEntryBlock = CRM.GetBlock("Entry"); with (customTextEntryBlock...
  • Blog Post: ASP.NET Pages and the Self Service API

    I have been asked about using Sage CRM Self Service API with ASP.NET. Imagine that you may have a customer that is using ASP.NET as the underlying technology of their corporate website. You may now have implemented Sage CRM for them and they now want to bring some of the data from their internal systems...
  • Blog Post: Using a Create Script to produce an automatically incrementing number.

    This example code is provided by a colleague in Switzerland. It provides an alternative way of creating an automatically incrementing field value. The result of the code is to create an incrementing number that includes the current "year" as a prefix and then "-" plus a number that...
  • Blog Post: Using the COM CRM.CreateQueryObj() to call a Stored Procedure.

    Below is some code that illustrates how a Stored Procedure maybe invoked in the QueryObject. var strSQL = "DECLARE @@ret int"; strSQL += " EXEC @@ret=eware_get_identity_id 'notes'"; strSQL += " INSERT notes"; strSQL += " (note_noteid,note_foreigntableid,note_foreignid...
  • Blog Post: Listing System Actions

    System Actions are not formally part of the official API and there is no list of them in the documentation although there are plenty of articles that make use of them. The article "Calling CRM Actions" is a good introduction to how the inbuilt System Actions can be referenced in custom pages...
  • Blog Post: A discussion about the Notes table and TableIDs

    In several areas of the system you will see references to Table ID. This is especially true if you are programming directly using the Record or Query Objects. The notes table is quite straightforward. You can add a notes table onto just about any entity, for example company (already there) or communication...
  • Blog Post: Building a Search Select Advanced Field in ASP

    I have covered the EntryTypes used in CRM in an earlier article, " Sage CRM EntryTypes used in the COM ASP API ". Below is a simple example showing how to create a Search Select Advanced in an ASP page. var myBlock = CRM.GetBlock("opportunitydetailbox"); var personidBlock = CRM...
  • Blog Post: Displaying Multiple List Blocks using the ASP COM API

    We have seen in other posts that it is perfectly possible to create ASP pages that contain multiple blocks. These have been search pages or entry pages that have drawn their blocks from either the same or different entities. What we have not discussed so far is the display of multiple list blocks...
  • Blog Post: The Sage CRM .NET API

    The diagram below shows the general architecture of Sage CRM. Here you can see very clearly that the .NET API is an alternative and NOT a replacement for the COM API which is currently used to build application extensions with ASP pages. Both the .NET API and the COM ASP API use the Meta...
  • Blog Post: Creating and Controlling an Insert Page in Self Service

    Below is a very simple example of a self service page that allows a case belonging to an authenticated visitor to be edited. The ASP code is found below. The code is comment and discussed below. <%@CodePage=65001 Language=JavaScript %> <!-- #include file ="ewaress.js"...
  • Blog Post: Accessing the SQL of a Filter or Search Page using the COM ASP API

    We may have a need to access the SQL clause of a search page. How can we know the SQL that is issued from a search page? Below is the code for a simple search page. [code language="javascript"] var searchBlock = CRM.GetBlock("opportunitysearchbox"); var gridBlock = CRM.GetBlock...
  • Blog Post: More thoughts on adding Action buttons to Find Screens

    SyntaxHighlighter.config.clipboardSwf = '/dp.SyntaxHighlighter/Scripts/clipboard.swf'; SyntaxHighlighter.all(); I wrote an article previously that showed how the action buttons on the system search screens set a hidden value in the form. This is the "TargetAction" field. For example...
  • Blog Post: Creating an ASP Summary Page (ReadOnly) that Displays Data from an external Database using an ODBC driver e.g. Sage 100 ERP, formerly known as MAS 90

    This article provides example code for building a Summary page that displays data from an external database table through an ODBC driver. I have used for this example a connection to a Sage ERP MAS 90 table. I have assumed that you will have read the following articles Connecting to an External...
  • Blog Post: Calling a Sage CRM COM object from a .NET project.

    I wrote an article just a little while ago that discussed how a System Administrator could easily reset a users password. See: Resetting Passwords Within the article was example code that demonstrated how an External COM logon could use a QueryObject to pass an SQL update statement into Sage CRM....
  • Blog Post: Using Joins in Web Services

    Imagine you need to retrieve information from CRM via the webservices interface; this query should combine data from multiple tables. In the COM API (ASP pages, self service, table level scripts etc) you could use the QueryObject to build the exact SQL you need. var mySQL = "SELECT Person.*,...
  • Blog Post: Controlling List Size in ASP Pages

    How can we override the User grid size preference for a custom list on ASP pages? You may have seen that there is a List block property called RowsPerScreen ListBlock.RowsPerScreen = 5; On the face of it, this should allow us to change the list size to what ever we need. But according to Developers...
  • Blog Post: Add/Subtract Days to a Date and pass to a Record Object

    This article has been updated.(again 14th April 2009) Dates can be a bit of a challenge. This article explains three points: how to convert a record’s date field value into a JavaScript Date object. how to add/subtract days to a JavaScript Date object. how to pass a JavaScript...
  • Blog Post: Checking Versions in Sage CRM

    How can we tell what version has been installed? The patch and version of the software is announced on the Logon Screen. Again within the product you can check the version by going to My CRM> Preferences and clicking the About CRM button. The version can be checked programmatically. This becomes very...
  • Blog Post: Building selection lists in ASP pages without reference to Meta Data

    From time to time you will need to build pages that can not directly be based on a Meta data definition of a screen. For example if you need to construct a page that allows cloning of an entity or perhaps interaction with an external system. The CRM objects allow to you to easily build screens and entries...
  • Blog Post: How can I build a multiblock edit screen?

    I was recently asked about how to handle the problem of having multiple screen blocks on the same page than when you attempt to move the page to edit mode you get a nasty locks message. The problem occurs because both blocks are attempting to place an entry in the locks table to reserve editing rights...