Search found 7 matches

by rynait
01 Dec 2010 12:48
Forum: DOS Batch Forum
Topic: function variable passing problem (whitespace or quotes)
Replies: 4
Views: 5561

Re: function variable passing problem (whitespace or quotes)

Hello the issue here is not in relation to the previous post, I want to be able to pass the variable (no return) to function that does not include quotes or end up chopped. [pre] Previous post was about returning back the variable from function. and i never change subject within the post, because ot...
by rynait
01 Dec 2010 01:45
Forum: DOS Batch Forum
Topic: function variable passing problem (whitespace or quotes)
Replies: 4
Views: 5561

Re: function variable passing problem (whitespace or quotes)

the table is mashed up... responding attempt with html quote function v1 v2 note notlocal Dwarf Fortress Race (v2 fail) returning Dwarf Fortress Race (v2 fail) islocal "Dwarf fortress"" (", chopoff, v2 "") islocal no "" Dwarf Fortress Race (v2 fail) islocal no...
by rynait
01 Dec 2010 01:41
Forum: DOS Batch Forum
Topic: function variable passing problem (whitespace or quotes)
Replies: 4
Views: 5561

function variable passing problem (whitespace or quotes)

I came across this whitespace breakup or unable to strip quotes problem in function variable passing. I was working on a script and spotted those weird problems. turns out everytime i fix this call, i find that the problem "moves" onto another call. so I created test.bat to analyze (track-...
by rynait
30 Nov 2010 04:43
Forum: DOS Batch Forum
Topic: need help passing a variable
Replies: 11
Views: 16330

Re: need help passing a variable

Hello, the test I did... %active% is reduced to one word declaration and %backup%, two words. (did three tests... with quote, without quotes, underline instead whitespace) all tests failed to swap the variables. a question, is enabledelayedexpansion supposed be in the function or in the beginning of...
by rynait
30 Nov 2010 04:37
Forum: DOS Batch Forum
Topic: need help passing a variable
Replies: 11
Views: 16330

Re: need help passing a variable

even tried your next suggestion (same results) did not swap the variables.

I put echos in several location as debugging. seems like the bug occurr when "endlocal& set..." in the :swapvars is not carried out.

am testing with non-whitespace and shorter string.

Roy
by rynait
30 Nov 2010 00:15
Forum: DOS Batch Forum
Topic: need help passing a variable
Replies: 11
Views: 16330

Re: need help passing a variable

tried your suggestions. It did not work. however a question how do i find out if .bat file is set with enabledelayedexpansion? only time setlocal is used is within the swapvars function (yes i even changed the call:swapvars, testing the suggested code.) does not return any error, just does not even ...
by rynait
29 Nov 2010 19:12
Forum: DOS Batch Forum
Topic: need help passing a variable
Replies: 11
Views: 16330

Re: need help passing a variable

got this function variable return failures. tried variations. however is pasting the .bat file (with unimportant bodies eliminated, to make it smaller. the problem lies with preserveswitch (colored dark blue). the idea is to swap the global variables, called by newback routine (later will be called ...