Android Question Class - activity something else - guidance needed

tsteward

Well-Known Member
Licensed User
Longtime User
Anyone following anything I have posted will know i'm not a programmer but I get there somehow by hacking and reusing code from the brilliant people here and making up some of my own.

Anyway I think I need to create a Class but may be wrong.
In my app on an activity I have created some panels and buttons to interact with SMMRitcheitor lib here and it works great my users are able to leave feedback some of the buttons I created allows them to add data from my database it works well

Now I have need to use this on serveral other activities and re-writting that code while possible seems silly.

I require the ability to call an activity to diplay my smmricheditor and other thing, allow the users to edit it and when finished return the result.

Something like my
string = openFeedbackEditor(contents as string)

so I can send data to be displayed and get contents back when finished
I don't want someone to do it all for me but guide me please

hope that makes sense
 

tsteward

Well-Known Member
Licensed User
Longtime User
Upvote 0

josejad

Expert
Licensed User
Longtime User
Just try and you will see is not complicated. I was afraid to do it, but when you start, you will see is not so hard.
Just create a class, and start moving the subs and declarations of your smmricheditor to that class.
Then all you have to do is declarate an object in your activity of that class, and call the methods.

You will find a couple of problems in the process, but you will be able of solving them with searching in the forum about classes.

Really, try it and you will find is easier than you think.

Take a look to this lesson:

 
Upvote 0
Top