CodeCharge Studio
search Register Login  

Visual PHP Web Development

Visually Create Internationalized Web Applications, Web Reports, Calendars, and more.
CodeCharge.com

YesSoftware Forums -> CodeCharge Studio -> General/Other

 Display Masks.

Print topic Send  topic

Author Message
Rocket

Posts: 45
Posted: 10/06/2010, 8:31 AM

On with some more dumb type questions. When displaying data (grid or form), I'd like to use display (format as???) masks. :-/

For example; phone number displayed as (xxx) yyy-zzzz, currency as: $xx,xxx.xxx, Dates, etc. I've been dropping into the coding arena and doing this for each column, but (of course) there has to be a better way.

Now I'm guessing this bad boy can do this, I'm also guessing that it can do so without a bunch of coding (which would be nasty). I saw somewhere something about mask field format, but can't rememeber where. And I can't recall if this is just used for input. The one thing that I would be concerned with is displaying the data in a grid in one format and nto allow users to edit data in a different format.

For example, display a phone number as per the above, but allow users to just enter xxxyyyzzz, then format later for display.

I hope this makes sense and if more information is needed, Id be happy to provide it.

Any assitance is muchly appreciated.

Rocket man...
View profile  Send private message
cvboucher

Posts: 191
Posted: 10/06/2010, 9:21 AM

Click on the control and set the Format property. There aren't any options if the datatype is Text, but there are a number of options for Integer, Single, Float, Date and Boolean data types. These can be set for both labels and text boxes.

Craig
View profile  Send private message
Rocket

Posts: 45
Posted: 10/06/2010, 9:48 AM

Quote cvboucher:
Click on the control and set the Format property. There aren't any options if the datatype is Text, but there are a number of options for Integer, Single, Float, Date and Boolean data types. These can be set for both labels and text boxes.

Craig

Thanks for the pointer, I actually saw those. I should have been a little more exact. If I had a text field in my table, I'm suspecting that I can't use a display format (such as date) to display it without coding. Is that a correct statement?

If so, how can I use funcitons that I have (for example to convert text to Proper Case) or in a date format? I think what I mean to ask is where in the directory structure would I place the script and how in CCS4 would I call it.

As an example, I have a script that converts text to Proper Case (called pCase) and takes 1 input parm and returns it properly formatted.

I hope this rambling makes sense.

Thanks again.

Rocket
View profile  Send private message
datadoit
Posted: 10/06/2010, 12:54 PM

Unlike many code generating IDE's out there, CodeCharge doesn't
constrain the developer to the framework. Meaning, you have full
control over switching to HTML view and doing as you would with or
without a development environment (ie: Notepad).

So, if you have some javascript code that you want to implement in your
form fields, then have at it. You can even close CCS and open the
appropriate HTML file in Notepad and pound away.

In your particular example, sounds like you want to call a javascript
function in some event for the form field, such as OnChange:

<INPUT name="{MyField}" onChange="pCase(this.value)">
Rocket

Posts: 45
Posted: 10/06/2010, 6:17 PM

Well there ya go. I knew it would be something amazingly simple. And yes, I've found CCS a lot more versatile than ASPrunner and ASPmaker (which we've used for years).

The shear flexibility (by it's nature) is a little intimidating and daunting, as they say "to the developer - goes the spoils" .

Actually I do have one other question. If one configures a lookup from a table in say the Edit Page, does one have to do the same thing in the Add Page or will CCS do this automagically?

I do thank you for the intel and pointers.

Cheers...
View profile  Send private message

Add new topic Subscribe to topic   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

PHP Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.