please give me the code.
input file:
#box8 {
position:absolute;
}
#box8 .buttons {
text-align:left;
}
output file should be like this:
headers:#box8
#box8
Items:position:absolute;
text-align:left;
I have Table-valued parameters in SQL Server 2008 e.g.
CREATE TYPE UserType AS TABLE
(
UserID int,
UserName nvarchar(100),
UserPassword nvarchar(100)
)
Can i use this type somehow in my Sql CLR stored procedure? for example as input parameter ??
[SqlProcedure]
public static void SomeFunction(/* what type should be here ?? */)
{
}
Will be appreciate even for attention, let alone for any help !
Okay I'm looking for some input, I'm pretty sure this is not currently supported in .NET 3.5 but here goes.
I want to require a generic type passed into my class to have a constructor like this:
new(IDictionary<string,object>)
so the class would look like this
public MyClass<T> where T : new(IDictionary<string,object>)
{
T CreateObject(IDictionary<string,object> values)
{
return new T(values);
}
}
But the compiler doesn't support this, it doesn't really know what I'm asking.
Some of you might ask, why do you want to do this? Well I'm working on a pet project of an ORM so I get values from the DB and then create the object and load the values.
I thought it would be cleaner to allow the object just create itself with the values I give it. As far as I can tell I have two options:
1) Use reflection(which I'm trying to avoid) to grab the PropertyInfo[] array and then use that to load the values.
2) require T to support an interface like so:
public interface ILoadValues
{
void LoadValues(IDictionary values);
}
and then do this
public MyClass<T> where T:new(),ILoadValues
{
T CreateObject(IDictionary<string,object> values)
{
T obj = new T();
obj.LoadValues(values);
return obj;
}
}
The problem I have with the interface I guess is philosophical, I don't really want to expose a public method for people to load the values. Using the constructor the idea was that if I had an object like this
namespace DataSource.Data
{
public class User
{
protected internal User(IDictionary<string,object> values)
{
//Initialize
}
}
}
As long as the MyClass<T> was in the same assembly the constructor would be available. I personally think that the Type constraint in my opinion should ask (Do I have access to this constructor? I do, great!)
Anyways any input is welcome.
Am I doing something wrong here?
I have a text area on a view and am posting back the html contents. In VS 2008 and MVC 1.0 the following code successfully prevents input validation:
[HttpPost]
[ValidateInput(false)]
public ActionResult Index(int? id)
{
return View();
}
If I execute this code in VS 2010 / MVC 2.0 I always get this error:
A potentially dangerous Request.Form value was detected from the client (body="").
Any ideas?
I have a neural network trained with backpropagation algorithm. I also create data set (input and target) random. Now I want to plot a decision region where each region is marked with a red star or with a blue circle according to whether it belongs to class 1 or -1. I searched a lot but just find plotpc function that is for perceptron algorithm. What should I try now? Any link or answer really helps. Thanks
I understand that CI is mostly URL segment based, but I want to have a query string: blahblah.com/search.html?q=keyword
When I try $this-input-get( "q" ), it returns empty. Is there a route or something I need to configure?
I know that I can use fonts like arial "for free". But what if I want to use not a standard font ?
Is that something that a browser should support ?
Where I can check, for example, which fonts Firefox 3.6.3 supports ?
I would like, for example, to change the font of input text area.
How do I find if a string contains HTML data or not? The user provides input via rich:editor component and it's quite possible he could have used either a simple text or used HTML formatting.
This question can probably be broken up into multiple questions, but here goes...
In essence, I'd like to allow users to type in what they would like to do and provide a wizard-like interface to ask for information which is missing to complete a requested query. For example, let's say a user types: "What is the weather like in Springfield?"
We recognize the user is interested in weather, but it could be Springfield, Il or Springfield in another state. A follow-up question would be:
What Springfield did you want weather for?
1 - Springfield, Il
2 - Springfield, Wi
You can probably think of a million examples where a request is missing key data or its ambiguous. Make the assumption the gist of what the user wants can be understood, but there are missing pieces of data required to complete the request.
Perhaps you can take it as far back as asking what the user wants to do and "leading" them to a query.
This is not AI in the sense of taking any input and truly understanding it. I'm not referring to having some way to hold a conversation with a user. It's about inferring what a user wants, checking to see if there is an applicable service to be provided, identifying the inputs needed and overlaying that on top of what's missing from the request, then asking the user for the remaining information. That's it! :-)
How would you want to store the information about services? How would you go about determining what was missing from the input data?
My thoughts:
Use regex expressions to identify clear pieces of information. These will be matched to the parameters of a service. Figure out which parameters do not have matching data and look up the associated question for those parameters. Ask those questions and capture answers. Re-run the service passing in the newly captured data. These would be more free-form questions.
For multiple choice, identify the ambiguity and search for potential matches ranked in order of likelihood (add in user history/preferences to help decide). Provide the top 3 as choices.
Thoughts appreciated.
Cheers,
Henry
i am using this jquery ui combobox autocomplete control out of the box off the jquery ui website:
my issue is that i have multiple comboboxes on a page and i want them to have different widths for each one.
i can change the width for ALL of them by adding this css:
.ui-autocomplete-input
{
width:300px;
}
but i can't figure out a way to change the width on just one of them
I want to clear console screen every time the user make an input in C++.
I'm thinking of using system command. For Windows, it is "cls". For Linux, it is "clear". Is there a way check which system to use the appropriate command in c++?
Thanks.
I want to check if user input a positive integer number.
1 = true
+10 = true
.1 = false
-1 = false
10.5 = false
Just a positive number.
No characters.
No special character.
No dot.
No minus sign.
I tried is_int() function but it is returning false even on positive integers. Is there a string to int problem?
Thanks
I have jasper report which accepts Integer parameter .
I am using g:jasperreport tag to call the report . body of this tag has input html
which gets passed to report.
But's the report is not working. It is giving invalid format exception.
Pl. help
Thanks in advance.
Abe
The application layer (ColdFusion) needs to insert multiple rows onto SQL Server 2005.
I was thinking of using loop in app layer to construct multiple input statements and send to SQL Server over JDBC in a single connection.
My colleague however suggests to construct an XML and bulk insert the XML instead.
Which one is the better method?
Hi,
I'm trying to add some code in a presentation made with LaTex. I used beamer, added some frames without problems but once I add the listing, I can't compile the presentation anymore.
\begin{frame}{Code}
\begin{lstlisting}
Sample Code
\end{lstlisting}
\end{frame}
The error I pdflatex gave me is:
Package Listings Warning: Text dropped after begin of listing on input line 80.
Is there anything special to add to make it work ?
Thanks
I have an unmanaged DLL with a function that can run for a long time if the input parameter is a large value, sometimes that is desirable but not always.
How can I in c# call this function so that I can abort it when needed?
So far I have tried to put the call in a separate thread, but neither interrupt nor abort seem to stop the process, which runs at 100% CPU until the dll is done.
Is it possible to terminate the running dll code?
Hi,
Is it possible to generate word documents (*.doc) in java web application using Eclipse BIRT (Report Engine)? I want .rptdesign to be an input file in generating process. I could not find any example or tutorial.
What would you recommend as an alternative solution. As far as I know Jasper Reports allow only RTF format generation.
Thank you for your answer/explaination
ok im trying to upload this csv file onto my table in pgsql
but im getting this error
ERROR: invalid input syntax for integer: "mlname,mfname,slname,sfname,address,postalcode,membershiptype,hphone,email"
CONTEXT: COPY members2, line 1, column id: "mlname,mfname,slname,sfname,address,postalcode,membershiptype,hphone,email"
i really understand why im getting this error, both my table and my csv file have the same column names
I am trying to set up a search feature on my site that will only return exact matches to keyword entered by the user. So if the user searches "dog" I don't want an article titled "Doggy Style" to appear in the search results (just an example I don't really have an article by that name). This of course does exactly that:
SELECT * FROM articles WHERE article_title LIKE '%$searchQuery%'
$searchQuery here is a PHP variable taken from the user's input form. So is there any way to return only exact matches?
How could I programmatically install a font on the Mac platform (Snow Leopard)? What steps would I need to follow? I would like for the user to input a font file, then my software installs it.
I am implementing a distributed chat system, in this system we have the following options :
Make the client and server running at each node run as separate threads. The server acting as the receiver will be running as the daemon thread and the client taking the user input as a normal thread.
Fork two processes one for the client and one for the server.
I am not able to reason out with which one to proceed. Any insight would be great !
Goal: To implement a jQuery plugin for my rails app (or write one myself, if necessary) that creates a "box" around text after a delimiter is typed.
Example: With tagging on SO, the user begins typing a tag, then selects one from the drop-down list provided. The input field recognizes that a tag has been selected, puts a space and then is ready for the next tag. Similarly, I am attempting to use this plugin to put a box around the previously entered tag before moving to to accept the next tag/input.
The instructions in the README.txt seem simple enough, however I have been receiving a
$(".tagbox").tagbox is not a function
error when debugging my app with firebug.
Here is what I have in my application.js:
$(document).ready( function(){
$('.tagbox').tagbox({
separator: /\[,]/, // specifying comma separation for <code>tags</code>
});
});
And here is my _form.html.erb:
<% form_for @tag do |f| %>
<%= f.error_messages %>
<p>
<%= f.label :name %><br />
<%= text_field :tag, :name, { :method => :get, :class => "tagbox" } %>
</p>
<p><%= f.submit "Submit" %></p>
<% end %>
I have omitted some other code (namely the implementation of an autocomplete plugin) existing within my _form.html.erb and application.js for sake of readability. The inclusion or exclusion of this omitted code does not affect the performance of this plugin.
I have included all of the necessary files for the tagbox plugin (as well as application.js after all other included JS files) within the javascript_include_tag in my application.html.erb file.
I'm pretty much confused as to why I'd be getting this "not a function" error when jquery.tagbox.js clearly defines the function and is included in the head of my html page in question. I've been struggling with this plugin for longer than I'd like to admit, so any help would really be appreciated. And, of course, I'm open to any other plugins or from-scratch suggestions you may have in mind..
This tagbox plugin does not seem to have a wealth of documentation or any currently working examples.
Also to note, I'm trying to avoid using jrails.
Thanks for your time
I have a small webpage with a form, iframe-d in. When I put invalid input inside the form, the iframe covers up the navigation bar and I can't get the navigation bar back without closing and opening the page again.
Here is where I am (temporarily) hosting the webpage: dl.dropbox.com/u/1144456/rlp/v2/demo.html
the css stylesheet: dl.dropbox.com/u/1144456/rlp/v2/contact-us.htm
To recreate this problem, click the last tab and just click submit.
I'd like to make a script which sreach in google and shows the 1st relevant image.
I mean, if you type to the input field: car
if you search to word "car" via google and it suggest the 1st image for me.
What do you think, are there any method to do this?
Hey,
I would like to write a code involving automatic selection of a best composite model using ETS as well as autoregressive models. What is the criteria I should base my selection on?
Also if I'm using the auto.arima function for deducing number of AR terms and corresponding coefficients from the forecast package in R, does my input series necessarily have to be stationary? or the value for d would be automatically selected thus returning a non-stationary model?
Thanks,
Phani