Search Results

Search found 11238 results on 450 pages for 'miserable variable'.

Page 41/450 | < Previous Page | 37 38 39 40 41 42 43 44 45 46 47 48  | Next Page >

  • Creating form object for variable kind of form.

    - by Bunny Rabbit
    i want to create a form for users to submit questions in django ..so far the models i have created are class Question(models.Model): statement=models.CharField(max_length=100) class Choice(models.Model): statement=models.CharField(max_length=100) value=models.IntegerField() question=models.ForeignKey(Question) Now i want to write a Form class for creating a above form but the problem is the number of choices are variable,a user can decide how many choices a question must have .How do i do that in django?

    Read the article

  • Inserting text in a file from a variable

    - by user754905
    I have a file that looks something like this: ABC DEF GHI I have a shell variable that looks something like this: var="MRD" What I want to do, is to make my file look like this: ABC MRD DEF GHI I was trying to do this: sed -i -e 's/ABC/&$var/g' text.txt but it only inserts $var instead of the value. I also tried this: sed -i -e 's/ABC/&"$var"/g' text.txt but that didn't work either. Any thoughts? Thanks!

    Read the article

  • Change the Session Variable Output

    - by user567230
    Hello I am using Dreamweaver CS5 with Coldfusion 9 to build a dynamic website. I have a MS Access Database that stores login information which includes ID, FullName, FirstName, LastName, Username, Pawword, AcessLevels. My question is this: I currently have session variable to track the Username when it is entered into the login page. However I would like to use that Username to pull the User's FullName to display throughout the web pages and use for querying data. How do I change the session variable to read that when they are not entering their FullName on the login page but only Username and password. I have listed my login information code below if there is any additional information needed please let me know. This is the path for which the FullName values reside DataSource "Access" Table "Logininfo" Field "FullName" I want the FullName to be unique based on the Username submitted from the Login page. I apologize in advance for any rookie mistake I may have made I am new to this but learning fast! Ha. <cfif IsDefined("FORM.username")> <cfset MM_redirectLoginSuccess="members_page.cfm"> <cfset MM_redirectLoginFailed="sorry.cfm"> <cfquery name="MM_rsUser" datasource="Access"> SELECT FullName, Username,Password,AccessLevels FROM Logininfo WHERE Username=<cfqueryparam value="#FORM.username#" cfsqltype="cf_sql_clob" maxlength="50"> AND Password=<cfqueryparam value="#FORM.password#" cfsqltype="cf_sql_clob" maxlength="50"> </cfquery> <cfif MM_rsUser.RecordCount NEQ 0> <cftry> <cflock scope="Session" timeout="30" type="Exclusive"> <cfset Session.MM_Username=FORM.username> <cfset Session.MM_UserAuthorization=MM_rsUser.AccessLevels[1]> </cflock> <cfif IsDefined("URL.accessdenied") AND false> <cfset MM_redirectLoginSuccess=URL.accessdenied> </cfif> <cflocation url="#MM_redirectLoginSuccess#" addtoken="no"> <cfcatch type="Lock"> <!--- code for handling timeout of cflock ---> </cfcatch> </cftry> </cfif> <cflocation url="#MM_redirectLoginFailed#" addtoken="no"> <cfelse> <cfset MM_LoginAction=CGI.SCRIPT_NAME> <cfif CGI.QUERY_STRING NEQ ""> <cfset MM_LoginAction=MM_LoginAction & "?" & XMLFormat(CGI.QUERY_STRING)> </cfif> </cfif>

    Read the article

  • Voicexml how to store input into a global variable

    - by Tyzak
    Hello, I'm creating a voicexml appliacation. I want to store an user input into a global variable. I wondered, the input should be stored in the fieldvar. shouldn't it? After I tried it with this, i tried to store it in an global variable: <assign name="myvar" expr="'myinput'"/> but somehow it didn't work. I used value expr="var" as expr. <?xml version="1.0" encoding="UTF-8"?> <vxml xmlns="http://www.w3.org/2001/vxml" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.w3.org/2001/vxml http://www.w3.org/TR/voicexml20/vxml.xsd" version="2.0"> <var name="myProdukt" /> <form id="test"> <field name="var"> <prompt bargein="true" bargeintype="hotword" >Sagen Sie ein Produkt</prompt> <grammar root="main" version="1.0" xml:lang="de-DE"> <rule id="main" scope="public"> <one-of> <item> p1 </item> <item> p2 </item> <item> p3 </item> <item> p4 </item> </one-of> </rule> </grammar> <filled> <assign name="myProdukt" expr="<value expr="var"/>"/> </filled> </field> </form> <<!--[...] Here i want to use the input.--> </vxml> thanks in advance

    Read the article

  • Why is my platform variable defined as 'BNB'?

    - by Scott Langham
    Hi, Something, maybe the windows sdk or visual studio installer, has defined the Platform environment variable and given it the value BNB. What does BNB mean, and why is Platform set to BNB? Thanks. I've seen this, but it doesn't answer my question: http://social.msdn.microsoft.com/Forums/en-US/msbuild/thread/1d229d75-aa89-42bf-809b-ef98f42072bb

    Read the article

  • Android Add Icon to homescreen to set member variable in broadcast receiver

    - by JonF
    I would like to add some sort of icon that a user can press in order to flip a variable in a broadcast receiver my app uses. Basically I just can a icon that they can press which will flip the value of a boolean in the broadcast receiver, and change the icon to indicate something happened. I think I need to do something with a widget? Could anyone point me in the direction of some tutorial I could check out?

    Read the article

  • Scoping in embedded groovy scripts

    - by Aaron Digulla
    In my app, I use Groovy as a scripting language. To make things easier for my customers, I have a global scope where I define helper classes and constants. Currently, I need to run the script (which builds the global scope) every time a user script is executed: context = setupGroovy(); runScript( context, "global.groovy" ); // Can I avoid doing this step every time? runScript( context, "user.groovy" ); Is there a way to setup this global scope once and just tell the embedded script interpreter: "Look here if you can't find a variable"? That way, I could run the global script once. Note: Security is not an issue here but if you know a way to make sure the user can't modify the global scope, that's an additional plus.

    Read the article

  • How to pass variable from jsf managed bean to jsp page

    - by cyberziko
    How can I pass a variable from JSF managed bean to JSP page. PS: I'm in portal context (liferay). I tried this: in Managed Bean: HttpServletRequest request = (HttpServletRequest) FacesContext.getCurrentInstance().getExternalContext().getRequest(); request.setAttribute("var", "someTxt"); in JSP: <% String var = (String)request.getAttribute("var"); %> I don't get any result.

    Read the article

  • php for loop varable names

    - by Stefan
    i got a code of 100-200 rules for making a table. but the whole time is happening the same. i got a variable $xm3, then i make a column . next row, i got $xm2 and make column. next row, i got $xm1 and make column. so my variables are going to $xm3, $xm2, $xm1, $xm0, $xp1, $xp2, $xp3. is there a way to make a forloop so i can fill $xm and after that a value from the for loop?

    Read the article

  • how do i set up a grails environment variable

    - by TripWired
    I'm uploading images in a grails app I'm developing and I want to be able to have an environment variable the determines where these images are. So if I'm working locally it can just pull from /home/MyName/images but once it's in production it will pull from http://images.site.com. How would I do that? I'm assuming i can set up my config.groovy with the variables i'm just not sure how i switch between them or use them in code.

    Read the article

  • passing variable from vbscript to batch file

    - by sushant
    i am using vbscript to call a batch file. my script looks like: dim shell set shell=createobject("wscript.shell") shell.run "a.bat" set shell=nothing my batch file is simple and looks like: D: cd D:\d winzip32.exe -min -a D:\a i want to pass a variable from a script to the batch file. lets say the destination folder. how do i do that? any help is very much appreciated.

    Read the article

  • How to get path from a variable

    - by yoshco
    Following http://stackoverflow.com/questions/659647/how-to-get-folder-path-from-file-path-with-cmd I want to strip the path (without the filename) from a variable. following the logic of the methods discussed above I would like to use batch bellow, which doesn't work. any takers? possible? set cpp="C:\temp\lib.dll" echo %cpp% "C:\temp\lib.dll" echo %~dpcpp "C:\temp\" > doesn't work

    Read the article

  • Xcode: view references for a variable?

    - by David.Chu.ca
    I am new to Xcode. I am not sure if there is a way to view a variable's references just like "Find all references" in Visual Studio by right click on a var? For example, in my .h file, I would like to know or view all the references for property isSet: @interface MyInterface { ... BOOL isSet; // view all references to this var? ... }

    Read the article

  • undefined local variable or method `user', using CarrierWave for profile images

    - by Amar H-V
    I've been following Ryan Bates' Railscasts tutorial on CarrierWave, which you can find here Everything works fine, except for when I go to view my profile, it gives me this error: undefined local variable or method `user' I don't know why it is telling me this, as I am using Devise for my authentication, and that is the name of my model. Below are some of the files which may be useful: https://gist.github.com/amarh21/7439421 I am using Rails 4.0.1 and ruby 2.0.0

    Read the article

< Previous Page | 37 38 39 40 41 42 43 44 45 46 47 48  | Next Page >