CodeCharge Studio
search Register Login  

Web Reports

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

YesSoftware Forums -> CodeCharge Studio -> PHP

 Cant add Textboxes to form, nor does Listbox work correct

Print topic Send  topic

Author Message
flin

Posts: 5
Posted: 01/26/2004, 10:33 AM

Hi, after working with CodeCharge Studio for a week now, I get the strangest results now.

Everything was fine until today, when I wanted to change the display in a ListBox. It showed the street of a building, which was quite stupid because it made sense to show either street and house number or only the identifier. I chose to use the identifier, but it never shows up (I have the same listbox in another form, where it works, which rather baffles me).

I create a listbox, its named ListBox1.
Data Source Type is Database Column.
It controls tgst_id , which is the identifier for the table.
As a connection i use the ODBC mysql driver, a connection i named MySQL_DB , which is working.
As Data Source Type i have Table/View
Data Source is tgst_gebaeudestamm, a table where i keep elemental data on buildings.
I want to show the ID, which is of course named tgst_id, too.
So i enter tgst_id as bound column and as text column, and it shows me: nothing.

After trying around with that for 2 hours, i decided to go with a textbox. That is when the real fun started. As soon as I add a textbox to my form, i get a
Fatal error: Call to a member function on a non-object in C:\Programme\Apache Group\Apache2\htdocs\tmic_micro_maint.php on line 392

Line depends on location of the textbox.
The line is
$this->TextBox1->Show();

I have to say that in the beginning i was very fond of Codecharge. After this day, however, I start to become more and more sick of it. This is pure Mickeysoft behaviour. Adding a textbox doesnt work. What a joke. Furthermore i am in the middle of a project with a tight schedule and suddenly CodeCharge starts to **** up badly, doing strange things that worked 100 times before.

I guess I will just start over with the form, and another night down the drain.
View profile  Send private message
flin

Posts: 5
Posted: 01/26/2004, 12:23 PM

Never Mind, i just made a new page, took less time than figuring out what was wrong.
View profile  Send private message
Robert Little
Posted: 01/31/2004, 12:19 PM

:( Hi,
did you check the "Data Type" in ListBox properties is set to "Integer" instead of "Text"?
moldinaga

Posts: 4
Posted: 09/21/2004, 7:32 PM

flin;

I went through similar trials, and even though you 'solved' this problem by making the page, I thought you might like to hear what was wrong for me.

I too very much enjoyed using codecharge...until that moment, when something very simple that should have caused no problems at all gave me that error.

Well, after poking around the code for a while, I figured out that while the error gives a line number that corresponds to the Show method (in your case:

$this->TextBox1->Show();


the real problem for me was that the form element (TextBox1 in your case) was not being included in the Initialize Method. Strangely though, it was showing up in all the other Methods in the code as it should. It was only missing from the Initialize Method.

So I added the necessary code to the Initialize method (cut and pasted some code from the other form elements and tailored it to my new element) and the problem was solved.

But now a new problem: do I want to be doing that kind of thing every time I add anything? No way.

Well, after feeling sad and saying mean things about codecharge to myself, I noticed that in the code view, the initialize method was white, and the other stuff was gray. Which meant that for some reason, the project thought that I had added 'custom code' to the initialize method (maybe I hit enter? I dunno). Since CC thought there was custom code in there, it would not regenerate that method when new elements were added.

So, I deleted the white code, switched to design view, switched back to code view and there it was in gray, and from then on, everything has worked like a dream.

hope this helps.

phil
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.

Internet Database

Visually create Web enabled database applications in minutes.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


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