Questions tagged [declare]

Use this tag for questions related to declare, which is usually meant for declaring variables, statements, etc.

736 questions
0
votes
1 answer

AspectJ declare parents on complex hierarchy

There is a possibility in AspectJ to modify the class hierarchy using declare statements : declare parents : TypePattern extends Type; From http://eclipse.org/aspectj/doc/released/adk15notebook/annotations-decp.html Basically it allow you to…
ebtokyo
  • 2,369
  • 4
  • 23
  • 33
0
votes
1 answer

Declaration of a custom function in another custom function

My 1st function: function db_connect_error_mail ($txt) { mail(admin_email,mail_subject01,$txt);} //1st three variables come from constants at config.php and 2nd function: function connectdb() { $dbc = mysqli_connect (db_host, db_user,…
Andre Chenier
  • 1,166
  • 2
  • 18
  • 37
0
votes
2 answers

SQL Server Select statement using dynamic variables

Ok so in the below statement I am trying to take the first pi.planinfoid selected as the first field and make it a dynamic variable in the place of the 1736 you see in the two select statements being used as additional fields. I also need it to…
ThatGuy
  • 303
  • 2
  • 14
0
votes
2 answers

What is the difference between not initializing a pointer, and having it be initialized to null?

I'm building a simple generic engine for my true start in the making of games, and I am trying to be somehow organized and decent in the making of my engine, meaning I don't want it to be something I throw to the side once I make what I'm planning…
parreirat
  • 715
  • 3
  • 9
  • 22
0
votes
1 answer

how to define global variable in VB.NET?

how to declare global variable in VB.NET (Web Forms "ASPX") and use this variable in all pages ? how is Method Initialize and Cancel initialized in web page ? Thank you
0
votes
2 answers

define function and pass struct values

I'm new to C and I had a couple questions about getting struct values into a function and the correct way to declare the function. in my common.h I've defined extern struct ddrautocal; int get_eeprom_vals(uchar); // is this the correct declare the…
txcotrader
  • 585
  • 1
  • 6
  • 21
0
votes
3 answers

VBA in Excel: "Can't find project or library" error when executing in 2007

Using VB for Excel in Excel 2003, I have no problems executing code with some non-declared variables: numberOfBooks = 0 However, if I try to execute the same code in Excel 2007, I get a "Can't find project or library" error message. I looked at…
user56380
  • 93
  • 4
  • 9
0
votes
1 answer

mysql procedure is won't let me declare variable

My goal for this procedure is to use the day of the week to determine the the adjusted price for a service. For instance, on the weekends, the price is increased by 10%. On Monday and Friday, the price is the same. And Tues through Thurs is…
user1682055
  • 93
  • 2
  • 3
  • 9
0
votes
0 answers

After you declare a variable of type Datetime, the result as the query is successful

After you declare a variable of type Datetime, the result as the query is successful. But also, I get the following error in end-stage Tiger2 Logo. "incorrect syntax near the keyword 'declare' Native error:42000(156)" The code is as follows. DECLARE…
0
votes
2 answers

Was not declared in this scope with Friendly Function

I am not sure why this is happening, but it seems like it is throwing a "was not declared in this scope" error, falsely. I say this because it works on my Windows computer (MSVC compiler), but it will not work on my Mac (GCC). I am using Qt Creator…
hetelek
  • 3,776
  • 5
  • 35
  • 56
0
votes
1 answer

(c++) Declaring a class member in a class

I am trying to create a CBuffer member in every CClient class like this : #ifndef CCLI_INC #define CCLI_INC #include "CBuffer.h" #include "main.h" class CClient { private: CBuffer *m_buffer; public: CClient(); …
deniz
  • 2,427
  • 4
  • 27
  • 38
0
votes
1 answer

Declaring objects from one xib to another in Xcode?

I have a project that has a switch from an xib separate from the main ViewController. I am trying to make it so that when you switch the UISwitch to OFF a button in the ViewController is hidden. I have tried to declare the AppDelegate in the xib's…
0
votes
2 answers

(SQL) How can I add values into a table based on the IDs of another table?

I need to be able to add a set of values into a table every time a new user is added into my system. When the user is added, I want to look into my 'Tags' table, and insert a new entry into the 'Tag_Score' table for each of the IDs in the 'Tags'…
-1
votes
1 answer

How to use a variable in a dictionary before declaring it in Python

So basically I am doing a brute-forcing script to guess a User's password, and I need to iterate through passwords and then use each password in the loop. So basically something like this: for password in passwords_list: …
-1
votes
1 answer

SQL: How to rename the header using parameter variable?

How to rename the header of column 'Q1_2022 to parameter @filteredDate. Below is the working query but don't know how to rename the header '03-31-2022' using @filteredDate. Please suggest. declare @filteredDate Date = '03-31-2022' select…
John83
  • 97
  • 1
  • 8