Archive for February, 2010

How do you learn? How does anyone learn and why is that important?

Posted by Jason Huber on February 26, 2010
Blog / No Comments

Do you know how you learn?

There is a very common idea that each person learns in a certain way. I usually would say students are visual learners, audible learners or tactile learners. So some learn by watching me write the items on the white board, some learn by hearing me say the items out loud many times and other learn by writing the items and or using the list in practice. This has been further described as a learning preference rather than a particular learning style for each person. If we realize and embrace this newer idea then perhaps we may enable ourselves to learn better and in other ways.

Remember that back in the 50′s when much of the research on learning was conducted we did not have computers or even TV in most homes. Books were expensive items and college was something a majority of people did not consider attending. There was no facebook or email. You had party lines in your neighborhood rather than a dedicated phone line to your home. Now we all have computers in our houses.

There are also a few styles of learning such as active learners, sensing learners and visual learners. In my opinion sensing learners have a greater grasp of the spacial word around them and they can learn by experiencing the ideas of another through story or TV. From reading a book or hearing a description of a process. Active learners have to give it a try. This can take time because you need to have the tool available that facilitate you working it out. And visual learners need to see it done. They can repeat the process if they can watch it being performed by someone else once. Perhaps they have a harder time when their situation does not match the control environment, but overall if you can demonstrate it they can learn to repeat the process.

How do we use this in training at Sage

Well for the visual learners we provide a nice video of each piece of the class in video format. This works well for a learner who needs to hear it too. They watch as a trainer walks them through the customization and explains the process. More advanced learners can skip through the video if they already know the work being performed. They can subscribe to the Developers Subscription or Admin Subscription and learn there too.


Visual learners also benefit from the books that are part of each class. They include any major parts of the interface that we are adjusting and code snippets being used. Many times a visual learner will be able to remember which page or pages a topic is on because they remember where it was in the book. You can see them flip back to it if you watch them closely.

Tactile learners or active learners are given the chance to try it out. In all of our classes the student is given an actual machine to try out the exercises. Visual learners will benefit from this step as well because it will reinforce the learning from the book and videos. Audible learners or those who learn by watching benefit less from this part of the class, but it cannot be dismissed. In some cases the trouble or frustration caused by performing the steps can be a deterrent to this type of student and that needs to be considered.

Is there more to learning?

Active learners of all sorts will be considering the topics in the class and considering those topics in other situations. If we show you how to create a lookup one way is there another way to create one? What about a better way or a time when our method will not work?

The MORE to learning is applying what we give you in class to your situations in the real world. We cannot give an education it must be obtained. It is not possible to obtain what we need as successful students (of SalesLogix) in only 3 days. It is just the start.

Why is my learning style important?

It is less important than you might think. Realizing that you may have a preference for one style over another is the key. If you prefer to watch a video and read the book then do that. If you can read the book and try it yourself on our machine do that. You need to evaluate your learning process against some concrete results. Try a lesson one way and then try to repeat the lessons that you learned (creating a lookup) on a clean environment. Were you successful? Perhaps you need to add some practice in or adjust your method.

It is important to know your learning style because the real cost of an education is time. It takes time to learn and doing it inefficiently costs a lot of time. Usually this is the difference between meeting a deadline and not.

The goal of learning

If you consider the goal of learning you may learn just enough to meet that goal. We each may have a different goal. If the goal is to learn enough to do our job as effectively and efficiently as possible then realizing our learning style is important.

ref: http://csta.villanova.edu/CITIDEL/bitstream/10117/196/6/ThomasLA.pdf

JavaScript Debugging

Posted by Jason Huber on February 23, 2010
Developer / No Comments


I regularly use FireBug in Firefox my for my JavaScript debugging. Back in the mozilla days I would just enter javascript: in the address bar and get the nice dialogue that shows to tell me the location of the error. We can all agree we have come a long way. Now that Firebug is also in Chrome we have another tool. I admit I do not bother with JS debugging in IE much, but I have pressed F12 a few times in the app to get up the dev tools.

So to put it short I could not do as good of a job as the guys over at alistapart.com. Check out what they have to say about debugging in JS “after the jump”:

“When used effectively, JavaScript debuggers help find and squash errors in your JavaScript code. To become an advanced JavaScript debugger, you’ll need to know about the debuggers available to you, the typical JavaScript debugging workflow, and code requirements for effective debugging. In this article, we’ll discuss advanced debugging techniques for diagnosing and treating bugs using a sample web application.”

http://www.alistapart.com/articles/advanced-debugging-with-javascript/

Tags: , , , , ,

Redirect after Save/New with MainView and Entity Page

Posted by Diane Kohnert on February 19, 2010
Blog / No Comments

Redirect with Save and Save/New
Using a Redirect after doing a save or save/new is pretty straight foward. The main difference to remember is whether your doing a redirect to a quickform MainView or doing a redirect to a quickform tied to an Entity Page.

For this example, I have a quickform called InsertRealEstate.ascx with an associated EntityPage called InsertRealEstate.aspx. The user has 2 save options: 1) Save which takes the user back to a RealEstate MainView with the RealEstateDetails.ascx quickform in the MainContent or 2) Save/New which takes the user back to the same InsertRealEstate.ascx quickform in the InsertRealEstate.aspx EntityPage.

Option 1: Redirect to MainView
For the first example, the save button calls a business rule that does a save. Then there is an ‘OnCompleteActionItem’ that actually does the Redirect. Here is a picture of what that would look like:

Lets take a look at the properties that are filled in for the redirect. The MainViewEntityName is set to RealEstate and the MainViewEntityMode is set to Detail. This will actually take us to the MainView for the RealEstate entity. In this case we are redirected to the RealEstate.aspx that contains the RealEstateDetail.ascx quickform in the MainContent. We also chose ‘Use Current Link in ID’ set to True as we want the Current ID to be included in the redirect. If you looked at the code behind that button you would see the code generated is something like this:
Response.Redirect(string.Format("RealEstate.aspx?entityId={0}", (this.BindingSource.Current as Sage.Platform.ComponentModel.IComponentReference).Id));
This actually redirects us to the RealEstate MainView and displays the record we just saved.

Option 2: Redirect to EntityPage
For the second example, has to do with the save/new button. The save/new button calls a business rule that does a save. This time we want to stay on the same page to add another record. We will still use the ‘OnCompleteActionItem’ to do the Redirect. Here is a picture of what that would look like:

In this case the properties used are the URL and the ‘Use Current Link in ID’ set to false. The URL is pointing to the InsertRealEstate.aspx Entity Page with a parameter added of modeid=insert
InsertRealEstate.aspx?modeid=insert
The ‘Use Current Link in ID’ is set to false because we don’t really need to see an ID if we are going right back to add another RealEstate record. The MainViewEntityName and MainViewEntityMode is not used in this case because we are not wanting to go to the MainView for the RealEstate Entity, instead we want to go to the EntityPage that we are currently on: InsertRealEstate.aspx.

If we take a look at the code generated for this we would see another Redirect without an ID in the URL
Response.Redirect(string.Format("InsertRealEstate.aspx?modeid=Insert"));

Hope this explains the working of the Redirect when used with a MainView and with an Entity Page.

Tags: , , ,

Master’s Series Mashup

Posted by Kristin Lisson on February 18, 2010
Blog, Developer / No Comments

We’re two Master’s Series deep! This week we finished our second series topic, Client-Side Coding Techniques, which followed our inaugural offering, SData v1.0 in December.

Did you miss a session? Fear not! You can attend a make-up session for Client-Side Coding Techniques or the revised SData 1.1 course in March. Visit http://www.sageu.com/saleslogix/masters/ for details and registration.

Sorry, I’m new here. What’s a M-M-M-Master’s Series?

Check out the Master’s Series Mashup for the two-minute skinny:




<br /> <FONT FACE="Verdana" SIZE="1" COLOR="#000000">You need to have Windows Media Player in order to view this performance. Download it from <A HREF="http://www.windowsmedia.com/" TARGET="_blank">http://www.windowsmedia.com/</A></FONT><br />

Tags:

Changing the Default Public Templates

Posted by Kristin Lisson on February 09, 2010
Administrator / No Comments

As a SalesLogix administrator, you can configure many default settings in the SalesLogix Client so they match your company’s processes or look-and-feel. Templates used for letters and mail merge are no different; in fact, you have probably very easily figured out how to create new, private templates with your company’s own logo. When it comes to modifying those default public templates, however, you may have felt like that area is a Secret Template Guru Club to which someone forget to invite you. This article provides you with some easy steps to isolate those plugins in the LAN Architect and make global changes. We invite you to not only enter the clubhouse, but to also become a full-blown member!

About Templates

Templates are predefined documents that contain reusable text combined with merge fields to automatically personalize a document for a selected contact or lead. Templates save you from having to recreate the same letter each time you want to send correspondence to your customers. SalesLogix contains base templates for letters, e-mail messages, and fax cover sheets. As the administrator, you can create additional templates for users, or they can create their own.

Template ManagerTo view the default templates:

  • LAN Client: From the main menu, click Write > Templates.
  • Web Client: Enable ActiveMail upon log on. Then from the main menu, click Write > Manage Templates.

Private vs. Public Templates

There are two types of templates available: Public and Private.

  • Public: These templates are what we refer to as the out-of-the-box or default templates. These templates are available for everyone to use and copy as private templates. Only the administrator can change or delete these templates…only if you know where to look!
  • Private: These templates are created by a SalesLogix user. Any templates you create when logged on to the SalesLogix Client—as the administrator or a SalesLogix user—will exist as private templates. Additionally, any public templates you copy will also be saved as private. Only the user who created the template will have access to the template. If you want to share the private template with another user, you can do so, but you should make a copy of the template first. Either way, whatever you do to a template within the Client application will always remain as a private template type.

Modify a Public Template

Ok, enough of the teaser already—tell me how to modify a public template!

  1. Log on to the SalesLogix Architect as admin.
  2. Click Cancel on the Open Project window.
  3. From the Manage menu, click Plugins.
  4. From the Manage Plugins window, change the Type option to show Templates, Mail Merge.
    Template Plugins
  5. Right-click the template you want to edit, and then click Open Plugin.
  6. Modify the template as needed&madash;add your company logo or change the font theme— and then click Save and Close.
    The template will automatically be changed for all SalesLogix users at this point. Most plugin customizations require you to release them before making them available to users, but there is no need to re-release for these default templates.

Ta-da! You now get access to the Secret Template Guru Club’s members-only password: Templatopia!

Tags: , , ,

Developer tools – must have’s

Posted by Jason Huber on February 03, 2010
Developer / No Comments

There are plenty of lists showing what tools every .NET developer should have and even a list from Hanselman himself, but what about a SalesLogix developer? I figured I would share some of the tools I use on a regular basis here and let you add yours in the comments:

  • Notepad ++ – just a better editor. Syntax highlighting and all that. An easy replacement for notepad
  • FireFox and Firebug Firefox is safer and all that but firebug is a tool that let’s you code client side 1000X faster. (available for chrome too) Press F12 to see it in FF or IE
  • GitExtensions for SalesLogix – allows you to easily use git with Application Architect.
  • GitHub – Allows you to get your git repo into the cloud. This means you can work in global groups etc.
  • Fiddler Tool – I use this one to see my HTTP traffic
  • .Net Reflector – I use this to peek into the SLX DLLs
  • Drop.io – share large files easily
  • Filezilla – killer ftp tool
  • 7-zip compression utility. Does zip too, but 7zip on the ultra setting is awesome
  • Pismo File Mount Audit Package – mount those installation ISOs easily within windows.
  • ScreenToaster – I use screen toaster to record my screen for demos, to help someone and to record bugs. I get others to use it to effectively share with me too. It is a browser based screen recorder.

So that is pretty much what we all knew already. Perhaps there is one or two tools on the list you do not already have/use. What about resources? Can we list those as well?

If you aren’t watching these blogs or websites – do! The authors take a lot of time to add content and it is for you. Just add it to your favorite reader. I use outlook believe it or not. It is always open and always there. Google Reader is a close second.

Tags: , ,

SData Client Library Changes v1.1

Posted by Jason Huber on February 01, 2010
Developer / 1 Comment

It looks like the development team has taken the steps necessary to officially release the SData Client Libraries to Partners. There are a couple demo apps included and one is a rewrite of the app we use in our SData Master’s Series class! Well they took that app and updated the Client Libraries and together reduced the code we need to write by more than 25%.

What changed?

Really the payload was put into a dictionary. A simple explanation of a dictionary in C# is a multidimensional array. Most of the time you have a key and a value. So in our case this becomes the field name (or entity property name if you must) and the value. There are a few other changes as well, but this is the biggest.

What does this do for me, the developer?

This means that in order to get a value from an SData feed you need to get the payload and then request the field by name. Seem familiar? It is sort of like getting a recordset and asking for a field. In most cases we treat a recordset in ADO like a multidimensional array. This should be an easy transition for most of us.

In my opinion this makes the Client Libraries much more useful. As the (genius) develop put it: “the user no longer needs to know any xml.” – WOW. No more of the nil=true mistakes or missing a namespace.

Code

Some simple code changes (as outlined by the developer in the rewritten app:

Before:

doccontact = new XmlDocument();
    doccontact.LoadXml(entry.GetSDataPayload().OuterXml);
    nav = doccontact.CreateNavigator();
    manager = new XmlNamespaceManager(doccontact.NameTable);
    manager.AddNamespace("sdata", "http://schemas.sage.com/sdata/2008/1");
    manager.AddNamespace("slx", "http://schemas.sage.com/dynamic/2007");
    var prop = nav.SelectSingleNode("//slx:Address", manager);
    dr[3] = prop.SelectSingleNode("@sdata:key", manager).Value;

After:

dr[3] = ((SDataPayload) entry.GetSDataPayload().Values["Address"]).Key;

So this is a reduction of 8 lines of code.

Another example from the developer:
Before:

    XPathNavigator tempContactPayload = tempContactEntry.GetSDataPayload();
    //create the XML document for the new
    var doc = new XmlDocument();
    doc.LoadXml(tempContactPayload.OuterXml);
    //setup the navigator and namespace alias
    XPathNavigator navContact = doc.DocumentElement.CreateNavigator();
    XmlNamespaceManager managerTemplate = new XmlNamespaceManager(tempContactPayload.NameTable);
    managerTemplate.AddNamespace("slx", "http://schemas.sage.com/dynamic/2007");
    managerTemplate.AddNamespace("sdata", "http://schemas.sage.com/sdata/2008/1");
    managerTemplate.AddNamespace("xsi", "http://www.w3.org/2001/XMLSchema-instance");
    navContact.MoveToFirst();
    navContact.SelectSingleNode("//slx:FirstName", managerTemplate).SetValue(txtFirstName.Text.ToString());
    //delete xsi:null from payload...
    var nil = navContact.SelectSingleNode("//slx:FirstName", managerTemplate).SelectSingleNode("@xsi:nil", managerTemplate);
    if (nil != null) nil.DeleteSelf();
    //update the payload
    tempContactEntry.SetSDataPayload(navContact);

After:

    var tempContactPayload = tempContactEntry.GetSDataPayload();
    tempContactPayload.Values["FirstName"] = txtFirstName.Text;

So you can see this is much cleaner, easier and thus faster to develop against.

How can you tell which version you are using?

Well if you have downloaded anything from training prior to the date of this post you have the “old” version. This will usually mean the .Values from the above code will fail. So you can easily tell from that OR the new dll should have a version of 1.1 .

We will be offering an updated version of the SData class using the new and improved code. If you have attended the previous SData class you know there is no additional cost for you to attend and we plan on providing a simplified “what’s changed” version in that class as well.

Tags: ,