Questions tagged [getstring]

150 questions
0
votes
1 answer

Java getString method

So I have the questions in the top part, but I want to have all the questions at the top, and when I need to ask the questions, I can just pull them down using a variable defined as the question. Right now however, the code is asking the questions…
Jamie
  • 57
  • 1
  • 2
  • 10
0
votes
3 answers

How to get "name" attribute of html tag using php getStr?

I'm trying to find a way to get the content of this HTML attribute "name", using PHP getStr, I can't get it to work anyhow, I have already searched, but I couldn't find find something that may help me.
Ashley Ivy
  • 193
  • 3
  • 14
0
votes
1 answer

cursor.getString() doesn't work properly (ex: code postal = "01234" but return "1234" instead)

I'm working with Android - SQLite. I have code postal number stored as CHAR[5] in SQLite db. Cursor cursor = db.query( ... ) String code = cursor.getString(cursor.getColumnIndex("code")); CREATE TABLE codepostal ( code CHAR( 5 ) PRIMARY KEY NOT…
Anh-Tuan Mai
  • 1,129
  • 19
  • 36
0
votes
4 answers

How to access a string from string.xml, while we are in a class other than main class?

To access a string in the main class the getString() method works very well. but what if we have created another class and need access to the strings? I tried Resources.getSystem().getString(R.string.m1); but this didn't work and caused the app to…
Hadi Aghandeh
  • 765
  • 6
  • 24
0
votes
2 answers

JSONArray not returning correctly

I have this JSON data and am trying to process in in Java. { "status":"ok", "data":{ "user_count":3, "limit":20, "page_number":1, "users":[ { "id":330, "name":"jeff", …
woahguy
  • 261
  • 3
  • 13
0
votes
2 answers

Enum class in python

I would like to create an Enum class in python. I need also some get_str() method, something like: class Operation (object): START = 0 STOP = 1 (...) def get_str(self): operation_dispatcher = { Operation.START:…
Konrad
  • 630
  • 2
  • 11
  • 27
0
votes
1 answer

Python ncurses - how to trigger actions while user is typing?

I am reading user input text with getstr(). Instead of waiting for the user to press enter, I would like to read the input each time it is changed and re-render other parts of the screen based on the input. Is this possible with getstr()? How? If…
jdeo
  • 1
0
votes
1 answer

Android send SMS message with two getString()

I've got some problem with sending sms from Android app. In strings.xml I have text1 and text2 with some text. When I'm trying to send sms with only one string, e.g sms.sendTextMessage(number, null,message, null,null); where message i…
0
votes
3 answers

how sent integer parameter in intent

I want to send int parameter in intent like this: String textname = (String) dataItem.get("name"); Intent m = new Intent(list.this,main.class); m.putExtra("name",textname); m.putExtra("page",1); startActivity(m); and in main class I get that…
zahra
  • 35
  • 1
  • 10
0
votes
0 answers

Cocos2dx - TextField into string

How can i get the text from TextField into a string variable? I declared textfield and variable in .h file like so: NewScene.h cocos2d::ui::TextField* textField; std::string enteredData; then declared the textField in .cpp init() function, and…
0
votes
3 answers

org.json.JSONException: No value for success Exception

My Registration AsyncTask working fine and my data is saving on PHP MYSQL working good but I am facing a exception. public class SignupJson extends AsyncTask { //SignupJSONParser sjson = new SignupJSONParser(); …
ahmed aslam
  • 11
  • 1
  • 6
0
votes
3 answers

Selecting particular columns in ADO using getstring

When we use getstring to get data from a recordset (ADO) then it returns all the columns. If only certain columns are required, how do we modify the getstring statement?
tksy
  • 3,429
  • 17
  • 56
  • 61
0
votes
3 answers

What requirements are necessary in order to properly call getString(String key) function in a Wicket WebPage?

I have one Wicket (6.19) bundle including: HomePage.java HomePage.html HomePage.properties.xml In the .java file I have this code : public class HomePage extends BasePage { public HomePage() { add(new Label("message",…
0
votes
0 answers

Why am I getting errors while calling context.getResources().getString(R.string.string) in my class?

Why am I getting errors while calling context.getResources().getString(R.string.string) in my class? Using context.getResources().getString(R.string.january); just gives me android.content.res.Resources$NotFoundException: String resource ID…
The Dude
  • 1,088
  • 7
  • 16
  • 30
0
votes
4 answers

Help writing getstring function

Im having some trouble writing a getstring function, this is what I have so far. Regards, V const char* getstring() { char *buffer; int i = 255; buffer = (char *)malloc(i*sizeof(char)); *buffer = getchar(); while ( *buffer !=…
volting
  • 16,773
  • 7
  • 36
  • 54