Solved

QT and KDE prob

Posted on 2003-11-03
4
293 Views
Last Modified: 2010-04-22
This will be very hard to explain but i will try anyway

i have a project called test .....it has test.cpp test.h & update.cpp update.h ....i created a QT dialog that displays on startup, this works fine.....i have added QlineEdit box and a pushButton. In test.cpp when i press the pushButton i can succesfully add text to the lineEdit1 ..using lineEdit1->setText ("wow it worked"); ......but i want a class form update.cpp to be able to add the text to lineEdit1 but it fails with update.cpp:35: error: `lineEdit1' undeclared (first use this function).

the easiest way is to download the project from here and it should all make sense than ;-)
http://www.nutterx.com/download/

it was made with Kdevelop 2.1

Thanks

0
Comment
Question by:nutterx
4 Comments
 
LVL 3

Accepted Solution

by:
guynumber5764 earned 340 total points
ID: 9676711
The declaration of lineEdit1 (as a QLineEdit *)  and it's new/delete seem to have gotten lost in the shuffle.  It'll have to be public if you want update to see it and, even then it'll have to be explicitely scoped (::).
0
 

Expert Comment

by:probine
ID: 9911897
I think you could use pointers. So the update class will have a pointer to the QT edit box.
0

Featured Post

Courses: Start Training Online With Pros, Today

Brush up on the basics or master the advanced techniques required to earn essential industry certifications, with Courses. Enroll in a course and start learning today. Training topics range from Android App Dev to the Xen Virtualization Platform.

Question has a verified solution.

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

Suggested Solutions

Have you ever been frustrated by having to click seven times in order to retrieve a small bit of information from the web, always the same seven clicks, scrolling down and down until you reach your target? When you know the benefits of the command l…
The purpose of this article is to demonstrate how we can upgrade Python from version 2.7.6 to Python 2.7.10 on the Linux Mint operating system. I am using an Oracle Virtual Box where I have installed Linux Mint operating system version 17.2. Once yo…
This Micro Tutorial will teach you how to censor certain areas of your screen. The example in this video will show a little boy's face being blurred. This will be demonstrated using Adobe Premiere Pro CS6.
This Micro Tutorial will give you a basic overview how to record your screen with Microsoft Expression Encoder. This program is still free and open for the public to download. This will be demonstrated using Microsoft Expression Encoder 4.

815 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

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now