🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.database
Article #362

Re: jdbTable how to set caption ANSWER

#362
From: cts ctskinnerATyahoo.com
Date: Mon, 13 Nov 2006 03:54
24 lines
1804 bytes
you cant set caption with just a DataSet
you have to set up the columns
with this sort of code (After SetQuery)

    column1.setCaption("Project ID");
    column1.setColumnName("PROJECTID");
    column1.setDataType(com.borland.dx.dataset.Variant.STRING);
    column1.setPrecision(10);
    column1.setRowId(true);
    column1.setTableName("PROJECTS");
    column1.setServerColumnName("PROJECTID");
    column1.setSqlType(1);
    column2.setCaption("Project Description");
    column2.setColumnName("PROJECTDESC");
    column2.setDataType(com.borland.dx.dataset.Variant.STRING);
    column2.setPrecision(100);
    column2.setTableName("PROJECTS");
    column2.setServerColumnName("PROJECTDESC");
    column2.setSqlType(12);
    projects.setColumns(new Column[] {column1, column2});

note you CAN do this in the IDE, do DESIGN in DataModule
click on the Datamodule until columns appear, they have a caption property.
Technical Details
Message-ID: <4557fa85$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news2.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.freenet.de!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <45541e5c$1@newsgroups.borland.com> <4554f0cf$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 1073da,1c425cd2c8803f27
X-Google-Attributes: gid1073da,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "cts" ctskinnerATyahoo.com
Sender: "cts" ctskinnerATyahoo.com
Reply-To: "cts" ctskinnerATyahoo.com
Subject: Re: jdbTable   how to set caption ANSWER
Newsgroups: borland.public.jbuilder.database
X-User-Info: 220.101.175.81     
References: <45541e5c$1@newsgroups.borland.com> <4554f0cf$1@newsgroups.borland.com>
NNTP-Posting-Host: 207.105.83.66
Message-ID: <4557fa85$1@newsgroups.borland.com>
Date: 12 Nov 2006 20:54:29 -0700
X-Trace: newsgroups.borland.com 1163393669 207.105.83.66 (12 Nov 2006 20:54:29 -0700)
Lines: 25
Path: arc1-ca.pugleaf.net!g2news2.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.freenet.de!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail