Programming includes both the specifics of the language you’re using, like Visual Basic, .NET, Java and others, but also the best practices in user experience and interfaces and the management of projects, version control and development. Other programming topics are related to web and cloud development and system and hardware programming.

Share tech news, updates, or what's on your mind.

Sign up to Post

Hi EE,

How do redirect/configure the Powershell ISE or VSCode editors to run PowerShell scripts using PowerShell console (Powershell v6) terminal?

I have already tried the info in these posts:

And this works in VScode if I run the script from the command line.

But when I try to run the PS script with the intention of debugging it I get the following screen: see attached.

Basically what I need is when I hit the start debugging button F5 I need the terminal version to default to 'pwsh' (powershell v6)instead of PowerShell integrate

Below is my settings json file:

    "": "c:/Program Files/PowerShell/6/pwsh.exe"

"": [
        "shell": "C:\\Windows\\system32\\cmd.exe",
        "label": "cmd"
        "shell": "C:\\Windows\\system32\\WindowsPowerShell\\v1.0\\powershell.exe",
        "label": "PowerShell 5.1"
        "shell": "C:\\Program Files\\PowerShell\\6\\pwsh.exe",
        "label": "PowerShell 6.0"       
        "shell": "C:\\Program Files\\Git\\bin\\bash.exe",
        "label": "Git bash"


Open in new window

Any assistance is welcome.

Let me know if my query needs clarification.

Thank you.
Ensure Business Longevity with As-A-Service
Ensure Business Longevity with As-A-Service

Using the as-a-service approach for your business model allows you to grow your revenue stream with new practice areas, without forcing you to part ways with existing clients just because they don’t fit the mold of your new service offerings.

Using python to change number formats in Excel (Openpyxl)

The script is reading excel, to add an additional three zeros, which it does,
it also updates cell format to a custom value, the change does not reflect to the cell, as the cell does not identify itself as a number.
How do I update the cell to reflect it is an [int] format?

I've attached a copy of the xlsx file pre script change.  

from bs4 import BeautifulSoup
from openpyxl import Workbook
from openpyxl import load_workbook
from openpyxl.styles import Color, PatternFill, Font, Border
from openpyxl.styles import colors
from openpyxl.cell import Cell
from termcolor import colored
import colorama
from colorama import Fore, Style
import os

wb = Workbook()
xlfile = "Test.xlsx"
wb = load_workbook(xlfile)
dash = "-"

for xws in wb.sheetnames:
	worksheet = wb[xws]

	for rowOfCellObjects in worksheet['B3':'E5']:
		for cellObj in rowOfCellObjects:
			print(cellObj.coordinate, cellObj.value)
		print('--- END OF ROW BEFORE---')

for xws in wb.sheetnames:
	worksheet = wb[xws]
	for rowOfCellObjects in worksheet['B3':'E5']:
		for cellObj in rowOfCellObjects:
			cellValue = cellObj.value
			if cellValue != dash:
				x = cellValue
				print(Fore.RED + x)
				y = str(x) + ",000"
				print(Fore.WHITE + y)
				#z = (format(int(y),","))
				#print(Fore.GREEN + z)
				#cellObj = y
				#print(Fore.WHITE + cellObj)
				cellObj.value = y

Open in new window

I am looking at my shiny new GitHub account and I see the default setting for any new repository is to make it public. Is there a setting or preference I can change to make the default private?
How to use TreeView navigation  in correct approach. I'd like to use two vertical panel and make the left one as TreeView navigation panel and i'd like to show content on the right panel according to choosen node.

I searched some possible ways but i don't know which one is efficent and logic for programming approach.

1) Creating different forms without borders and when user select the node it will add that form to right panel. Like;

Dim f as Form
f = New frmNewForm
f.TopLevel = false


2) Adding panels with controls to MainForm's main panel(right panel) and make visible/invisible the panels according to selected node.

These are coming my mind at first. If you have experience about this topic could anyone help and guide me which method is suitable for it.

Note: I'll have apprx. like 15-20 navigation panel.

I'm a non-programmer (i.e., designer) using JQuery Mobile 1.2.1 (I know this is old, in the process of updating). When a visitor arrives at a particular static page via an outside link that includes a #hash at the end of the URL (i.e., "", #target being a section inside a collapsible), I need a collapsible on that page to expand, then I need the page to scroll smoothly to the target of the hash.

At the moment, this is a very specific use case, where I know the exact section and the target I want to scroll to, but it would be nice if this code could be reusable for any external link coming to a page where I would like to scroll to any target that's inside any collapsible. At this point, I'd settle for anything that works, as this is a somewhat urgent request.

I'm able to accomplish this sort of thing when just navigating to targets within a page via click, but when arriving from outside the page/site via a hash link URL, the results are very random and somewhat unpredictable. The collapsible opens, and then either the page scrolls to the target then immediately resets to view to the top of the page, or the scroll lands off target by varying margins. Kinda maddening.

This is where I've arrived most recently before throwing up my hands and running here.

$(window).bind("load", function() {
    	var hashName = window.location.hash;
//because I know the specific hash, I put it in an if statement to keep it from possibly interfering 

Open in new window

Need a module to merge PDF's
is any idea or some freeware that achive that, we can't purchase several PDF pro licences only for that propouse.
Pleas help me out you experts!
Please explain Gamma Compression algorithms. How to write Gamma Compression algorithms for typical video and image processing system?  Please provide some detailed examples.  How to gain sufficient understanding to be able to write Gamma Compression in 'C' or MATLAB?
I have performed mvn release:prepare release:perform.
And a tag got created. I am using git and phabricator
Now i had to make some minor changes to the code. But dont want to create another tag unnecessarily.
So can i make the earlier tag point to the new code ?
The tag is important because that is how the build system in our office works...
But each time i make some change for deployment i dont want to create a new tag. and somehow make the older tag point to new code

Please suggest how to do it. and any alternatives ?

As will soon become clear, I'm not a master of Git or even Gitkraken. As such, I just have a hotfix, a master and a feature branch. I make changes in hotfix, commit, push, and merge into master (which I then also push). So far I've endeavored not to get more complicated than this.

Even my one feature branch is a bit cowardly, in that that I still keep my feature work separate (in separate files/directories) from my working files, and consistently merge master into the feature branch so I don't lose all the site's hotfixes – all so that my crucial site files are kept whole and untouched regardless of branch. I consider this an intermediate practice as I continue to maintain the site while getting my head around Git. Since now I'm having this bizarre issue, I can see why I hadn't taken that leap yet. Apparently I'm indeed not ready to power-use Git or Gitkraken.

This morning, I did some work on hotfix, and merged it into master. No issue. Then I tried to switch to the feature branch (which I hadn't been in for weeks as it has been all about hot fixes lately), and all hell broke loose. Gitkraken throws the error: "Checkout failed. Could not remove [swf file - one that was there long before my last commit] Operation not permitted." What? Web searches with these key phrases turned up literally nothing... making me the first person to have this happen, I guess.

Then!... immediately, still in hotfix and having done nothing further, suddenly there are 27 file changes staged …
I am trying to write code that will determine the resolution of the screen the user is using in order to properly size charts.  I am having trouble getting anything to work. Can someone please help? I am using ASP.Net chart control and

Following is code that does not work.

Thanks for the help.

Dim CurScreenWidth As Integer = Screen.PrimaryScreen.Bounds.Width
        Dim CurScreenHeight As Integer = Screen.PrimaryScreen.Bounds.Height
        Dim DesignWidth As Integer = 1680        
Dim DesignHeight As Integer = 1050 
        Dim WidthRatio As Single
        Dim HeightRatio As Single

        WidthRatio = CurScreenWidth / DesignWidth
        HeightRatio = CurScreenHeight / DesignHeight

        Dim ChartWidth As Single = DesignWidth * WidthRatio * 0.96         
Dim ChartHeight As Single = DesignHeight * HeightRatio * 0.85

Open in new window

Acronis Global Cyber Summit 2019 in Miami
 Acronis Global Cyber Summit 2019 in Miami

The Acronis Global Cyber Summit 2019 will be held at the Fontainebleau Miami Beach Resort on October 13–16, 2019, and it promises to be the must-attend event for IT infrastructure managers, CIOs, service providers, value-added resellers, ISVs, and developers.

Some web apps update status messages when a process is running.
Other web apps require me to press F5 or refresh the browser using one of the icons at the top of the screen.

Question:   Can these two types of status updates or app messages be classified (i.e. apps programmed in ______ require you to press F5 to receive an updated status message, however, apps programmed in _____  refresh messages on their own and do not require you to press F5.
I have noticed sometimes whenever i do a git pull.
The editor will open up for merging with the default message :
Merge branch 'branch-name' of into 'branch_name'
And i unnecessarily end up creating a new commit.

I dont know why this is happening ?
Ideally when i do a git pull it should just pull out the changes and not merge something...
Moreover why this message is appearing in the commit ?

We are using a software which is time logging, so staff logs in there time when they start and logs off when they stop. Its called PC Clock.
Now when users starts the computer it opens fine but when they restart the computer or logs off it doesn't work for Windows 10 computers (Works fine for Windows 7 computers)
What can we do to resolve this issue?
New to Java.  Trying to re-create a layout see attached image.  I was trying to use the GridBagLayout.  My issue seems to be to place the buttons in the desired location.   With the JTextArea in place, I can't seem to determine how to place the desired buttons to the right of the JTextArea.

Here is some of my existing code:
        dropBtn = new JButton("Drop");
        eatBtn = new JButton("Eat");
        lookBtn = new JButton("Look");
        listBtn = new JButton("List");
        helpBtn = new JButton("Help");
        pickupBtn = new JButton("Pickup");
        westBtn = new JButton("West");
        eastBtn = new JButton("East");
        northBtn = new JButton("North");
        downBtn = new JButton("Down");
        setLayout (new GridBagLayout());
        GridBagConstraints position = new GridBagConstraints();
        // create results area to support twenty lines of text
        results = new JTextArea(20,40);
        JScrollPane scrollPane = new JScrollPane(results);
        results.setBorder(new EmptyBorder(20,20,20,20));
        // allow word wrap

        // supports auto scrolling within the JTextArea
        DefaultCaret caret = (DefaultCaret) results.getCaret();
        position.gridx = 0;
        position.gridy = 0;
Hello experts,

I am looking for the best way to built 3 procedures:

1-Display last used column letter in activesheet
2-Display last used row number in activesheet
3-Display initial Range and end range of activesheet example: A1:C4000

Thank you very much for your help.
i spent 6 hours yesterday trying to figure out sorting in python.

i get that:
for k in sorted(djTime.items(), key=lambda x(-x[1], x[0])):
should take every instance of k in djTime and perform something on something else.
i've understood the same of
for line in sorted(djTime):
should take a logfile previously broken into lines by the rstrip('\n') method and see the items as lines
i understand *line* or *k* in any circumstance can be any variable (i.e.) for JohnDoe in sorted(djTime):

i don't understand how or what python is looking for to differentiate between items either in a list or in a dictionary

i believe if you say:
for k, v in sorted(djTime.items())
...and this is a tuple, the k is representative of the key, and the v is representative of the value? but i'm not really clear

do you have to specify 2 variables/objects to sort a tuple? is a single non nested dictionary always a tuple? (i.e. for k, v in sorted(djTime)
do you have to use .items? what if i want to sort by key? can i sort like this:  for k, v in sorted(djItems.keys())  can i do it by values? : for k, v in sorted(djItems.values()

as for the remainder of the command up there :     x(-x[1], x[0])
i have no idea what the first x is, but the second seems to me to denote the position in the tuple? where counting begins with 0 so x[1] is the second item and x[0] is the first item? kinda backwards?? and the - negative in front of the main -x[1] mean sort from bottom to top

what i'm …
This is more of a non technical question probably. I am a Senior Software engineer working mainly on Java.
I want to grow and become a Lead but i am unable to rise to it.
I am confused what do i have to do to land there.
I want some people here to share there experience how they rose from a senior software engineer to a Lead.
Some people say you should own things.
The company i am in currently they just assign some tasks and i think if i just keep on solving them i will stay at a Senior Software Engineer level.
Its nothing interesting. I need to somehow pick up things myself and work on them so as to prove myself and get some interesting work.
But i dont understand how am i going to do that. Its easy to say and think that i am only responsible for my growth but for that i need to prove myself and do something interesting.
Moreover i also get confused between somethings
1) Like there is one regular type of work where your manager assigns you tasks and thats very boring
2) Other thing is you figure out something in the codebase refactor it or do something with it. But how am i gonna do that and whether these type of tasks will be valuable to the company or not ?

Something challenging and which grows me rather than doing routine work i need to figure out how to do it in office and work on it so that it keeps my interest and i grow as well.
Please provide some tips and insights into it.
Any books or videos also on this topic will help. I really want to do …
I am trying to help a friend with his Tradestation software that uses Easy language as the programming language.  Is there any resource where I can learn this programming online or self study or install on my pc which is a win 7 os.  thank u and regards
Hi Team,

Have been using C#, Visual Studio 2015, POM architecture. Problem is: sometimes tests passes and sometimes tests gets failed. So far what I tried is increased the explicit time but efforts so far in vain.

Also searched over the net and found that need to use webdriverwait which looks is missing as I am unable to use that. as the message says 'OpenQA.Selenium.Support.UI Namespace does not contain WebDriverWait class'.

Please help.
Become a Certified Penetration Testing Engineer
LVL 13
Become a Certified Penetration Testing Engineer

This CPTE Certified Penetration Testing Engineer course covers everything you need to know about becoming a Certified Penetration Testing Engineer. Career Path: Professional roles include Ethical Hackers, Security Consultants, System Administrators, and Chief Security Officers.

Have a vendor product CT FreightRater, an automated rating database used to calculate rates for loads we haul. We can enter hundreds of scenarios for rates like mileage, flat rate from point to point.
FreitRater recently did a changeover from running their WebService using XML, to using JSON. I have my JSON data conversion code ready, but need assistance setting up the front parameters that allow the HTTP URL, validation, etc.
In my RPGLE program, I use a product called RPG-XML Suite from Krengeltech. It supplies API's I can use to formulate my data into the JSON format, and that's working fine.
I can test through a program on the FreitRater Server called 'MultiRater'. This allows me to 'drop' in formed JSON statements to test against the rating database, and receive a response.
Unfortunately, FreitRater is unable to provide the specs for what these parameters are.
The only example I received from them to allow testing sending a RatingRequest example (C# .NET), is attached.

I'm also including the RXS_TransmitDS_t data structure used to 'send' to the FreitRater WebService in an attachment.

I need a 'translation' of sorts between the C# .NET example, to be able to  plug in those parameters to the RXS_TransmitDS_t data structure.


I am currently learning Java.

I would like to create a class that contains a constant variable (it should not be changed by anyone) that is structured in a similar way (I will use JSON to show an example):
	"key_1": "value_1",
	"key_2": "value_2",
	"object_1": {
		"object_1_key_1": "object_1_value_1",
		"object_1_key_2": "object_1_value_2",
		"object_1_key_2": "object_1_value_3",  

Open in new window

What would be the best Java data structure to obtain such result?

I thought a HashMap could've been a good start but then if I use:
private HashMap<String, String> myHash;

I am then forced to just use strings...

Can you please suggest a solution?

Thanks for your time and patience.
Excel -  Is there a way to filter for STRIKE THROUGH text??
I have Sheet A.csv and Sheet B.csv. Both have a column called 'Transaction ID'. I want to go through all rows in Sheet A and check the value in the Transaction ID column. If this value matches any value anywhere in the 'Transaction ID' column of Sheet B, I want the row deleted from Sheet A. And to carry on doing this for every row in Sheet A, so that in the end, none of the Transaction IDs in Sheet A will match those in Sheet B.

Do you know how to do this? Would if be a macro? Or better still, is there a way natively within Excel?

I have a folder with a bunch of jpg and jpeg files that I need to compress. Using a simple batch file called compressall.bat with the following code:
@echo off
for %%f IN (*.jpg) DO magick -quality 12 "%%f" "%%f"
for %%f IN (*.jpeg) DO magick -quality 12 "%%f" "%%f"

Open in new window

I'm able to go into a directory and manually run this to compress down my image files in a folder on windows system. The magick command is part of the opensource tool imagemagick.

I have 18.282 folders to parse through all with different names. I know there has to be a scripted way of doing this operation.
Hello experts,

I have the following xls file.
I am looking for a procedure or a efficient way to properly set up page view breaks in order to print the various pages.
The idea will to set up a procedure in order to:
1-Read from Initial column to last column and set up page break.
2-Have the same number of rows by page.
3-Properly adjust column & height width in order to get the most the page

I want to avoid to do this manually and I suppose it should be a way of doing this through a procedure.

Thank you in advance for your help.






Programming includes both the specifics of the language you’re using, like Visual Basic, .NET, Java and others, but also the best practices in user experience and interfaces and the management of projects, version control and development. Other programming topics are related to web and cloud development and system and hardware programming.