Questions tagged [code]

A tag that includes questions about programming in general.

183 questions
19
votes
5 answers

Reasons not to assume device MAC address is unique

In a scenario where you control the provisioning of the hardware and can determine that all devices with the same hardware model do indeed have unique MAC addresses for their networking interfaces, are there any downsides to writing code that uses…
Matt Phillips
  • 313
  • 2
  • 10
16
votes
5 answers

Is there any useful style of MS Word for code?

I need to use MS Word to make some documentation for Python code. Line number, or boxing around the code, or anything would be better than just use normal format. Is there any good/useful style/method for code documentation purposes?
prosseek
  • 5,794
  • 21
  • 59
  • 78
10
votes
1 answer

What scripting/programming languages are default on Mac OSX?

I was wondering what programming or scripting languages come pre-installed on OSX? Particularly programs that can be run from the command line. I'm planning on parsing some CSS, and outputting an html page. I've done it in python before, but I would…
JKirchartz
  • 350
  • 4
  • 14
10
votes
5 answers

Adding programming code into LaTex / LyX

Maybe I'm just being thick, but I can't find any sensible way to simply paste in my (python) code into latex without losing all the indent information (kinda important for python). Anyone got any bright ideas? I'm not worried about syntax…
Andrew Bolster
  • 1,388
  • 3
  • 15
  • 31
9
votes
1 answer

Why did this WhatsApp message freeze my phone?

Warning☠ If you touch this box, [ ‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎‏‎…
DGC
  • 101
  • 1
  • 3
8
votes
2 answers

Go to definition of a C function in a different file in Notepad++

While editing a C project on Notepad++ 5.6.7 (Unicode) with the SourceCookifier plugin, I can press Ctrl+Shift+Enter to go to the definition of a function which the cursor is on, but only if it is in the same file. How can I go to its definition if…
Gnubie
  • 2,857
  • 1
  • 29
  • 29
6
votes
1 answer

Correct indentation for selected code with BBEdit

Can I correct the indention of selected code (not my whole page) with BBEdit? So if I had this:
It colud become this:
Evanss
  • 1,188
  • 12
  • 33
  • 51
6
votes
2 answers

What is the shortcut to select everything between curly braces in Notepad++?

Is there any shortcut in Notepad++ to select all (highlight) codes between the curly braces (start & end)? E.g. Code between if-else, nethod definition, while, for loop etc.
Jenson M John
  • 193
  • 2
  • 7
6
votes
1 answer

Code signing issues

I have purchased a certificate from godaddy, which is now in .pfx format. I tried to convert it into .cer using Internet Explorer and Firefox. I tried to to sign midlet using converted .cer, but I get following error message: The KeyStore does not…
jmj
  • 419
  • 4
  • 19
4
votes
1 answer

How do I create a Code Snippet in MS Teams using a Keyboard Shortcut

In MS Teams, it is common to need to share code snippets quickly. Is there a keyboard shortcut that displays the code snippet editor?
dmcgill50
  • 1,100
  • 3
  • 12
  • 26
4
votes
1 answer

doxygen - what is working directory?

I've been working on doxygen these days, and I still have no idea about what is 'working directory.' Until now, I just made an empty folder at my D drive, and set it as my working directory. Everytime, doxygen did work quite well, so... maybe this…
hightower
  • 83
  • 1
  • 2
  • 4
4
votes
1 answer

How to replace character "-" by "%_%" in a batch file?

set var=this-is-a-test ECHO I would like to convert the value of this variable to "this%_%is%_%a%_%test" I tried with: SET VAR=%VAR:-=%_%% But doesn't work :( Please help
David
  • 41
  • 1
  • 1
  • 2
3
votes
2 answers

Syntax highlighting for emails

I'm once in a while sending raw code to customers. Is there a tool which adds (inline) styles to code, so that it is easier to read for my customers? A tool which works for gmail and other web-based (html) email clients would be great, but I would…
3
votes
1 answer

How do I remove a certain HTML code from a certain website?

There are some websites which refresh themselves in a very short period. I want to disable this behavior. The code that causes this problem is almost always following line: I learned that some browser…
hkBattousai
  • 3,101
  • 14
  • 44
  • 60
3
votes
1 answer

Format code in Bluefish?

I asked a similar question on webmasters.stackexchange.com and was directed here. How do I format code in Bluefish HTML editor? There's auto-indenting, that's easy enough to find. Is there a button I can click after selecting all the text? Because…
Tianxiang Xiong
  • 167
  • 2
  • 2
  • 5
1
2 3
12 13