Solved

Web Service Parameter Naming Convention

Posted on 2010-08-25
2
475 Views
Last Modified: 2013-11-19
I'm developing a webservice with several public methods. As an old VB programmer, I would normally use data type prefixes for my method parameters. For example, I might have method defined as (VB.NET):

Public Function GetSomething(ByVal nThingID As Integer) As String
    Return "something"
End Function

But since this will be a public web method and since the wsdl will define the data types, I'm wondering if my parameter should really just be ThingID (or ThingId). Are there guidelines? Or even some opinionated suggestions?

Thanks in advance.
0
Comment
Question by:ZekeLA
2 Comments
 
LVL 52

Accepted Solution

by:
Carl Tawn earned 250 total points
ID: 33526755
The norm would tend to ditch the old hungarian notation and opt for camel-casing instead (i.e. lower-case first letter for first word, upper-case first letter for subsequent words)

Here's Microsoft's recommendations: http://msdn.microsoft.com/en-us/library/ms229045.aspx
0
 
LVL 1

Author Closing Comment

by:ZekeLA
ID: 33526958
Thanks. I had only found the .net 2 conventions which wasn't as comprehensive.
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

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

Today, the web development industry is booming, and many people consider it to be their vocation. The question you may be asking yourself is – how do I become a web developer?
When crafting your “Why Us” page, there are a plethora of pitfalls to avoid. Follow these five tips, and you’ll be well on your way to creating an effective page.
The viewer will learn how to dynamically set the form action using jQuery.
HTML5 has deprecated a few of the older ways of showing media as well as offering up a new way to create games and animations. Audio, video, and canvas are just a few of the adjustments made between XHTML and HTML5. As we learned in our last micr…

821 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