Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Property Array

Posted on 1998-02-05
11
Medium Priority
?
205 Views
Last Modified: 2010-04-04
I have a rather unique problem. I want to define a published property for a
component that i am developing. This property is a property array. Check
out the following e.g.

property AProperty[ARow,ACol: Integer] : String read GetAProperty write
SetAProperty;

The property is pointing to a variable like -

FAProperty : array[0..100,0..2] of String;

Now the problem is that nowhere does Delphi say that this kind of property
can be defined only in the public section of the class definition. This i
have found out my banging my head for 2 continuous days and stumbling on
it. If u define it say for example in a published section of a class
definition then it will compile and build the library but when u are trying
to drop the component on a form, it will give u a access violation.

Now i need this property very badly in the published section because i want
to store data that is multi-dimentional. How do i do it ?. Can u help me
out ?. I need this very soon. Please do reply.

FOR JIM BOB

Yes I need a sample code on how to do this. It will be of great help. Thanks a lot.

Bijoy
0
Comment
Question by:bijoyn
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 5
11 Comments
 
LVL 5

Expert Comment

by:JimBob091197
ID: 1358389
Delphi Help strikes again...
You need to write your own property editor for published properties with arrays.  Do you require sample code?

JB
0
 

Author Comment

by:bijoyn
ID: 1358390
Edited text of question
0
 

Author Comment

by:bijoyn
ID: 1358391
FOR JIM BOB

Yes i would appreciate if u can give me a sample code on how to do this. Thanks.

Bijoy.
0
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

 
LVL 5

Expert Comment

by:JimBob091197
ID: 1358392
Hi

If you provide your e-mail address I will mail you a sample component,
JB
0
 

Author Comment

by:bijoyn
ID: 1358393
My Email Address is bijoy.nair@na.manpower.com.
Thanks Jim. I owe u one.
0
 
LVL 5

Expert Comment

by:JimBob091197
ID: 1358394
Hi

I have sent you a sample component.  Please let me know if you get it...

JB
0
 
LVL 5

Expert Comment

by:julio011597
ID: 1358395
Hello JimBob,

would you mind sending your sample to me, as well?

my mail address: julio@webzone.it

Thanks in advance, julio
0
 

Author Comment

by:bijoyn
ID: 1358396
Jim

Thats was cool. It did work for my property and many thanks to
u. Thanks a lot once again.

Bijoy
0
 
LVL 5

Expert Comment

by:JimBob091197
ID: 1358397
julio: I have sent the component to you.

bijoyn: If you are satisfied with the component, I will answer the question.

Regards,
JB
0
 

Author Comment

by:bijoyn
ID: 1358398
Jim,

Yes my component is working with the solution and the example u have sent to me. I am satisfied with  the solution.

Thanks

Bijoy.
0
 
LVL 5

Accepted Solution

by:
JimBob091197 earned 800 total points
ID: 1358399
I have provided a solution with a property editor.

JB
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Ready to improve network connectivity? Watch this webinar to learn how SD-WANs and a one-click instant connect tool can boost provisions, deployment, and management of your cloud connection.

Question has a verified solution.

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

A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…
Want to learn how to record your desktop screen without having to use an outside camera. Click on this video and learn how to use the cool google extension called "Screencastify"! Step 1: Open a new google tab Step 2: Go to the left hand upper corn…
Suggested Courses

688 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